chiark / gitweb /
*** empty log message ***
[sympathy.git] / Makefile.am
1 #
2 #
3 # Makefile.am:
4 #
5 # Copyright (c) 2008 James McKenzie <james@fishsoup.dhs.org>,
6 # All rights reserved.
7 #
8 # $Id$
9 #
10 # $Log$
11 # Revision 1.2  2008/02/24 00:42:52  james
12 # *** empty log message ***
13 #
14 # Revision 1.1  2008/02/03 16:20:23  james
15 # *** empty log message ***
16 #
17 #
18 #
19 #
20 SUBDIRS=src apps test 
21
22 bin_SCRIPTS = libsympathy-config
23
24 libsympathy-config.src:libsympathy-config.src.in
25 libsympathy-config:libsympathy-config.src version.sed
26         @SED@ -f version.sed < libsympathy-config.src > libsympathy-config || rm -f libsympathy-config
27         chmod +x $@
28         
29
30 VFD=${srcdir}
31 VF=${shell cat ${VFD}/version-files}
32 VFS=${VF:%=${VFD}/%}
33 VCHK=${shell cat ${VFS} | @MD5SUM@ | @AWK@ '{print $$1 }' }
34 VNUM=${shell @GREP@ ${VCHK} ${VFD}/version-md5sums | @AWK@ '{ print $$2 }'  }
35 VDEF=${shell echo `cat ${VFD}/version-major`.`cat ${VFD}/version-minor`.`cat ${VFD}/version-micro` }
36
37 version.sed: $(VFD)/version-files $(VFD)/version-major \
38         $(VFD)/version-minor $(VFD)/version-micro \
39         $(VFD)/version-md5sums ${VFS} Makefile
40         if [ .${VNUM} = . ]; then \
41                 echo "s/%VERSION%/${VDEF}-E/g" > version.sed; \
42         else \
43                 echo "s/%VERSION%/${VNUM}/g" > version.sed; \
44         fi
45
46 protos:
47         (cd src && ${MAKE} protos)
48
49 tidy:
50         cvs commit -m ""
51         (cd src && ${MAKE} tidy)
52         (cd apps && ${MAKE} tidy)
53
54