source: Makefile @ 246b98b

Last change on this file since 246b98b was a949b43, checked in by dequis <dx@…>, at 2018-03-11T19:33:55Z

Remove old skype plugin. Use the skypeweb purple plugin instead.

RIP

This plugin relied on the skype linux client, which doesn't work
anymore. During login it just does exit(0) for mysterious reasons.
I guess that's the server trying to say that it's not supported.

This is officially dead now after a few years of kinda-almost-working.

  • Property mode set to 100644
File size: 5.6 KB
RevLine 
[b7d3cc34]1###########################
2## Makefile for BitlBee  ##
3##                       ##
4## Copyright 2002 Lintux ##
5###########################
6
7### DEFINITIONS
8
9-include Makefile.settings
10
11# Program variables
[8e6ecfe]12objects = bitlbee.o dcc.o help.o ipc.o irc.o irc_im.o irc_cap.o irc_channel.o irc_commands.o irc_send.o irc_user.o irc_util.o nick.o $(OTR_BI) query.o root_commands.o set.o storage.o $(STORAGE_OBJS) auth.o $(AUTH_OBJS) unix.o conf.o log.o
[ebe2c5e]13headers = $(wildcard $(_SRCDIR_)*.h $(_SRCDIR_)lib/*.h $(_SRCDIR_)protocols/*.h)
[84b045d]14subdirs = lib protocols
[b7d3cc34]15
[e252d8c]16OUTFILE = bitlbee
[d1d6776]17
[b7d3cc34]18# Expansion of variables
19subdirobjs = $(foreach dir,$(subdirs),$(dir)/$(dir).o)
20
[a949b43]21all: $(OUTFILE) $(OTR_PI) doc systemd
[b7d3cc34]22
[4b53c65]23doc:
[a85a8ab]24ifdef DOC
[4b53c65]25        $(MAKE) -C doc
[a85a8ab]26endif
[4b53c65]27
[cdb92c5]28uninstall: uninstall-bin uninstall-doc
[b7d3cc34]29        @echo -e '\nmake uninstall does not remove files in '$(DESTDIR)$(ETCDIR)', you can use make uninstall-etc to do that.\n'
30
[c564e25]31install: install-bin install-doc install-plugins
[3e6cdb6]32        @echo
33        @echo Installed successfully
34        @echo
[b7d3cc34]35        @if ! [ -d $(DESTDIR)$(CONFIG) ]; then echo -e '\nThe configuration directory $(DESTDIR)$(CONFIG) does not exist yet, don'\''t forget to create it!'; fi
36        @if ! [ -e $(DESTDIR)$(ETCDIR)/bitlbee.conf ]; then echo -e '\nNo files are installed in '$(DESTDIR)$(ETCDIR)' by make install. Run make install-etc to do that.'; fi
[c564e25]37ifdef SYSTEMDSYSTEMUNITDIR
38        @echo If you want to start BitlBee using systemd, try \"make install-systemd\".
39endif
[3e6cdb6]40        @echo To be able to compile third party plugins, run \"make install-dev\"
[b7d3cc34]41        @echo
42
[3e6cdb6]43.PHONY:   install   install-bin   install-etc   install-doc install-plugins install-systemd install-dev \
44        uninstall uninstall-bin uninstall-etc uninstall-doc uninstall-etc \
[4b53c65]45        all clean distclean tar $(subdirs) doc
[b7d3cc34]46
47Makefile.settings:
48        @echo
49        @echo Run ./configure to create Makefile.settings, then rerun make
50        @echo
51
52clean: $(subdirs)
[c14959d]53        rm -f *.o $(OUTFILE) core utils/bitlbeed init/bitlbee*.service
[66b9e86e]54        $(MAKE) -C tests clean
[b7d3cc34]55
56distclean: clean $(subdirs)
[b0a89cc]57        rm -rf .depend
[b3c467b]58        rm -f Makefile.settings config.h bitlbee.pc
[34c0e90]59        find . -name 'DEADJOE' -o -name '*.orig' -o -name '*.rej' -o -name '*~' -exec rm -f {} \;
[b0a89cc]60        @# May still be present in dirs of disabled protocols.
[b41d5d2]61        -find . -name .depend -exec rm -rf {} \;
[dcf0f3e]62        $(MAKE) -C tests distclean
[b7d3cc34]63
[66b9e86e]64check: all
[c2fa827]65        $(MAKE) -C tests
66
[66b9e86e]67gcov: check
68        gcov *.c
69
[348c11b]70lcov: check
71        lcov --directory . --capture --output-file bitlbee.info
72        genhtml -o coverage bitlbee.info
73
[b7d3cc34]74install-doc:
[a85a8ab]75ifdef DOC
[b7d3cc34]76        $(MAKE) -C doc install
[a85a8ab]77endif
[b7d3cc34]78
79uninstall-doc:
[a85a8ab]80ifdef DOC
[b7d3cc34]81        $(MAKE) -C doc uninstall
[a85a8ab]82endif
[b7d3cc34]83
84install-bin:
[57da960]85        mkdir -p $(DESTDIR)$(SBINDIR)
[ba3506e]86        $(INSTALL) -m 0755 $(OUTFILE) $(DESTDIR)$(SBINDIR)/$(OUTFILE)
[54b2a36]87ifdef IMPLIB
88        # import library for cygwin
[e199620]89        mkdir -p $(DESTDIR)$(LIBDIR)
[54b2a36]90        $(INSTALL) -m 0644 $(IMPLIB) $(DESTDIR)$(LIBDIR)/$(IMPLIB)
91endif
[b7d3cc34]92
93uninstall-bin:
[57da960]94        rm -f $(DESTDIR)$(SBINDIR)/$(OUTFILE)
[54b2a36]95ifdef IMPLIB
96        rm -f $(DESTDIR)$(LIBDIR)/$(IMPLIB)
97endif
[b7d3cc34]98
[cdb92c5]99install-dev:
[e506d6c]100        mkdir -p $(DESTDIR)$(INCLUDEDIR)
[ba3506e]101        $(INSTALL) -m 0644 config.h $(DESTDIR)$(INCLUDEDIR)
[ebe2c5e]102        for i in $(headers); do $(INSTALL) -m 0644 $$i $(DESTDIR)$(INCLUDEDIR); done
[e506d6c]103        mkdir -p $(DESTDIR)$(PCDIR)
[ba3506e]104        $(INSTALL) -m 0644 bitlbee.pc $(DESTDIR)$(PCDIR)
[e506d6c]105
[cdb92c5]106uninstall-dev:
107        rm -f $(foreach hdr,$(headers),$(DESTDIR)$(INCLUDEDIR)/$(hdr))
108        -rmdir $(DESTDIR)$(INCLUDEDIR)
[e506d6c]109        rm -f $(DESTDIR)$(PCDIR)/bitlbee.pc
110
[b7d3cc34]111install-etc:
112        mkdir -p $(DESTDIR)$(ETCDIR)
[ba3506e]113        $(INSTALL) -m 0644 $(_SRCDIR_)motd.txt $(DESTDIR)$(ETCDIR)/motd.txt
114        $(INSTALL) -m 0644 $(_SRCDIR_)bitlbee.conf $(DESTDIR)$(ETCDIR)/bitlbee.conf
[b7d3cc34]115
116uninstall-etc:
117        rm -f $(DESTDIR)$(ETCDIR)/motd.txt
118        rm -f $(DESTDIR)$(ETCDIR)/bitlbee.conf
119        -rmdir $(DESTDIR)$(ETCDIR)
120
[a949b43]121install-plugins: install-plugin-otr
[57da960]122
123install-plugin-otr:
[858ea01]124ifdef OTR_PI
125        mkdir -p $(DESTDIR)$(PLUGINDIR)
[ba3506e]126        $(INSTALL) -m 0755 otr.so $(DESTDIR)$(PLUGINDIR)
[858ea01]127endif
[57da960]128
[417002e]129systemd:
130ifdef SYSTEMDSYSTEMUNITDIR
[0edb57f]131        mkdir -p init
132        sed 's|@sbindir@|$(SBINDIR)|' $(_SRCDIR_)init/bitlbee.service.in > init/bitlbee.service
133        sed 's|@sbindir@|$(SBINDIR)|' $(_SRCDIR_)init/bitlbee@.service.in > init/bitlbee@.service
[417002e]134endif
135
[a6c59bb]136install-systemd: systemd
[417002e]137ifdef SYSTEMDSYSTEMUNITDIR
138        mkdir -p $(DESTDIR)$(SYSTEMDSYSTEMUNITDIR)
[ba3506e]139        $(INSTALL) -m 0644 init/bitlbee.service $(DESTDIR)$(SYSTEMDSYSTEMUNITDIR)
140        $(INSTALL) -m 0644 init/bitlbee@.service $(DESTDIR)$(SYSTEMDSYSTEMUNITDIR)
[0edb57f]141        $(INSTALL) -m 0644 $(_SRCDIR_)init/bitlbee.socket $(DESTDIR)$(SYSTEMDSYSTEMUNITDIR)
[417002e]142else
[ebe2c5e]143        @echo SYSTEMDSYSTEMUNITDIR not set, not installing systemd unit files.
[417002e]144endif
145
[b7d3cc34]146tar:
147        fakeroot debian/rules clean || make distclean
148        x=$$(basename $$(pwd)); \
149        cd ..; \
[61d21e5b]150        tar czf $$x.tar.gz --exclude=debian --exclude=.git* --exclude=.depend $$x
[b7d3cc34]151
152$(subdirs):
[65d0dfd]153        $(MAKE) -C $@ $(MAKECMDGOALS)
[b7d3cc34]154
[7fa5c19]155$(OTR_PI): %.so: $(_SRCDIR_)%.c
[858ea01]156        @echo '*' Building plugin $@
[65d0dfd]157        $(VERBOSE) $(CC) $(CFLAGS) -fPIC -shared $(LDFLAGS) $< -o $@ $(OTRFLAGS)
[858ea01]158
[7fa5c19]159$(objects): %.o: $(_SRCDIR_)%.c
[b7d3cc34]160        @echo '*' Compiling $<
[65d0dfd]161        $(VERBOSE) $(CC) -c $(CFLAGS) $(CFLAGS_BITLBEE) $< -o $@
[b7d3cc34]162
163$(objects): Makefile Makefile.settings config.h
164
165$(OUTFILE): $(objects) $(subdirs)
166        @echo '*' Linking $(OUTFILE)
[65d0dfd]167        $(VERBOSE) $(CC) $(objects) $(subdirobjs) -o $(OUTFILE) $(LDFLAGS_BITLBEE) $(LDFLAGS) $(EFLAGS)
[2a1c27f]168ifneq ($(firstword $(STRIP)), \#)
[b7d3cc34]169        @echo '*' Stripping $(OUTFILE)
[65d0dfd]170        $(VERBOSE) -$(STRIP) $(OUTFILE)
[b7d3cc34]171endif
172
173ctags: 
174        ctags `find . -name "*.c"` `find . -name "*.h"`
[4fca1db]175
176# Using this as a bogus Make target to test if a GNU-compatible version of
177# make is available.
178helloworld:
179        @echo Hello World
[b0a89cc]180
[4b53c65]181# Check if we can load the helpfile. (This fails if some article is >1KB.)
182# If print returns a NULL pointer, the file is unusable.
183testhelp: doc
184        gdb --eval-command='b main' --eval-command='r' \
185            --eval-command='print help_init(&global->helpfile, "doc/user-guide/help.txt")' \
186            $(OUTFILE) < /dev/null
187
[b0a89cc]188-include .depend/*.d
[a0c6fc5]189# DO NOT DELETE
Note: See TracBrowser for help on using the repository browser.