source: Makefile.am @ 37f27bc

release-1.4release-1.5release-1.6release-1.7release-1.8release-1.9
Last change on this file since 37f27bc was 37f27bc, checked in by Nelson Elhage <nelhage@mit.edu>, 9 years ago
Switch the build system to using automake. Use automake for the build system, which lets us clean a bunch of cruft out of Makefile.in.
  • Property mode set to 100644
File size: 1.9 KB
Line 
1bin_PROGRAMS = barnowl.bin
2
3barnowl_bin_SOURCES = $(BASE_SRCS) \
4     owl.h owl_perl.h config.h test.h \
5     owl.c \
6     libzcrypt.a \
7     $(GEN_C) $(GEN_H)
8
9barnowl_bin_LDADD = libfaim/libfaim.a libzcrypt.a
10
11noinst_LIBRARIES = libzcrypt.a
12
13libzcrypt_a_SOURCES = zcrypt.c
14libzcrypt_a_CFLAGS  = -w
15
16CPPFLAGS = -I$(top_srcdir)/ \
17           -I$(top_srcdir)/libfaim/
18
19BASE_SRCS=list.c message.c mainwin.c popwin.c zephyr.c messagelist.c \
20     commands.c global.c text.c fmtext.c editwin.c util.c logging.c \
21     perlconfig.c keys.c functions.c zwrite.c viewwin.c help.c filter.c \
22     regex.c history.c view.c dict.c variable.c filterelement.c pair.c \
23     keypress.c keymap.c keybinding.c cmd.c context.c \
24     aim.c buddy.c buddylist.c style.c errqueue.c \
25     zbuddylist.c popexec.c obarray.c select.c wcwidth.c \
26     glib_compat.c
27
28GEN_C = varstubs.c perlglue.c
29GEN_H = owl_prototypes.h
30
31BUILT_SOURCES = $(GEN_C) $(GEN_H)
32
33proto: owl_prototypes.h
34
35perlglue.c: perlglue.xs
36        perl $(XSUBPPDIR)/xsubpp $(XSUBPPFLAGS) -prototypes perlglue.xs > perlglue.c
37
38varstubs.c: variable.c stubgen.pl
39        perl stubgen.pl > varstubs.c
40
41# Only move owl_prototypes.h into place if the new one is different
42owl_prototypes.h: codelist.pl varstubs.c $(BASE_SRCS)
43        perl codelist.pl > owl_prototypes.h.new
44        @cmp -s owl_prototypes.h.new $@ || { \
45         test -f $@ && echo 'Interfaces changed!'; \
46         echo mv -f owl_prototypes.h.new $@; \
47              mv -f owl_prototypes.h.new $@; }
48
49# For emacs flymake-mode
50check-syntax: proto
51        $(CC) $(CFLAGS) -Wall -Wextra -pedantic -fsyntax-only $(CHK_SOURCES)
52
53install-data-local:
54        $(mkinstalldirs) ${DESTDIR}${pkgdatadir}/lib
55        (cd perl/lib && tar -cf - . ) | (cd ${DESTDIR}${pkgdatadir}/lib && tar -xf - )
56
57do_transform = $(shell echo '$(1)' | sed '$(transform)')
58install-exec-hook:
59        mv -f $(DESTDIR)$(bindir)/$(call do_transform,barnowl.bin) \
60              $(DESTDIR)$(bindir)/$(call do_transform,barnowl)
61
62SUBDIRS = libfaim/ perl/modules/
Note: See TracBrowser for help on using the repository browser.