File: Makefile.in

package info (click to toggle)
owl 2.2.2-4
  • links: PTS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 2,208 kB
  • ctags: 3,600
  • sloc: ansic: 36,373; perl: 242; makefile: 93; sh: 43
file content (105 lines) | stat: -rw-r--r-- 2,877 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
# $Id: Makefile.in,v 1.22 2009/03/28 21:00:35 kretch Exp $

srcdir = @srcdir@
VPATH = @srcdir@
prefix = $(DESTDIR)@prefix@
exec_prefix = @exec_prefix@
datadir = @datadir@
bindir = @bindir@
mandir = @mandir@

CC=@CC@
LIBS=@LIBS@ -L./libfaim -lfaim
CFLAGS=@CFLAGS@ -I. -I./libfaim -DDATADIR=\"${datadir}\"
LDFLAGS=@LDFLAGS@
XSUBPPDIR=@XSUBPPDIR@
INSTALL=@INSTALL@
INSTALL_PROGRAM=@INSTALL_PROGRAM@
INSTALL_DATA=@INSTALL_DATA@

BASE_SRCS=list.c message.c mainwin.c popwin.c zephyr.c messagelist.c \
     commands.c global.c text.c fmtext.c editwin.c util.c logging.c \
     perlconfig.c keys.c functions.c zwrite.c viewwin.c help.c filter.c \
     regex.c history.c view.c dict.c variable.c filterelement.c pair.c \
     keypress.c keymap.c keybinding.c cmd.c context.c zcrypt.c \
     aim.c buddy.c buddylist.c timer.c style.c stylefunc.c errqueue.c \
     zbuddylist.c popexec.c select.c
OWL_SRC = owl.c
TESTER_SRC = tester.c

BASE_OBJS = $(BASE_SRCS:.c=.o)

GEN_C = varstubs.c perlglue.c perlwrap.c
GEN_H = owl_prototypes.h 
GEN_O = $(GEN_C:.c=.o)

OBJS = $(BASE_OBJS) $(GEN_O)

AUTOGEN=$(GEN_C) $(GEN_H)
#AUTOGEN=$(GEN_C)


owl: $(AUTOGEN) $(OBJS) owl.o libfaim
	./athstatic $(CC) -o owl owl.o $(OBJS) $(LDFLAGS) $(LIBS)

tester: $(AUTOGEN) $(OBJS) tester.o
	./athstatic $(CC) -o tester tester.o $(OBJS) $(LDFLAGS) $(LIBS)

test: tester
	./tester reg

clean: libfaimclean
	$(RM) owl tester *.o $(AUTOGEN) owl_prototypes.h.new

distclean: clean libfaimdistclean
	$(RM) config.cache config.log config.status Makefile config.h TAGS *~ core

proto: owl_prototypes.h

perlglue.c: perlglue.xs
	perl $(XSUBPPDIR)/xsubpp -typemap $(XSUBPPDIR)/typemap -prototypes perlglue.xs > perlglue.c

varstubs.c: variable.c stubgen.pl
	perl stubgen.pl > varstubs.c

perlwrap.c: perlwrap.pm encapsulate.pl
	perl encapsulate.pl perlwrap.pm owl_perlwrap_codebuff > perlwrap.c

# Only move owl_prototypes.h into place if the new one is different
owl_prototypes.h: codelist.pl varstubs.c $(BASE_SRCS)
	perl codelist.pl > owl_prototypes.h.new
	@cmp -s owl_prototypes.h.new $@ || { \
	 test -f $@ && echo 'Interfaces changed!'; \
	 echo mv -f owl_prototypes.h.new $@; \
	      mv -f owl_prototypes.h.new $@; }
#owl_prototypes.h:

.PHONY: tags clean distclean proto test

tags: TAGS

TAGS: $(BASE_SRCS) $(OWL_SRC) $(TESTER_SRC) $(GEN_C) owl.h $(GEN_H)
	etags $(BASE_SRCS) $(OWL_SRC) $(TESTER_SRC) $(GEN_C) owl.h $(GEN_H)

$(BASE_OBJS) varstubs.h:: owl.h config.h owl_prototypes.h
#$(BASE_OBJS) varstubs.h:: owl.h config.h

libfaim: libfaim/libfaim.a

libfaim/libfaim.a:
	(cd libfaim; $(MAKE))

libfaimclean:
	(cd libfaim; $(MAKE) clean)

libfaimdistclean:
	(cd libfaim; $(MAKE) distclean)

all: owl

install: all installdirs
	${INSTALL_PROGRAM} owl ${bindir}/owl
	${INSTALL_DATA} doc/owl.1 ${mandir}/man1/owl.1

installdirs: mkinstalldirs
	${srcdir}/mkinstalldirs ${bindir} ${mandir}/man1 ${datadir}/owl