Skip to content
Newer
Older
100755 174 lines (157 sloc) 6.11 KB
b31a690 @jonjensen Move DEV_4_7_0 development branch to repository trunk.
jonjensen authored Jul 18, 2001
1 #!/usr/bin/make -f
2 #
3399e80 @racke pragma dml=strict appended to catalog_before.cfg in Debian
racke authored Sep 4, 2009
3 # Copyright 2000,2001,2002,2003,2005,2006,2007,2008,2009 by Stefan Hornburg (Racke) <racke@linuxia.de>
b31a690 @jonjensen Move DEV_4_7_0 development branch to repository trunk.
jonjensen authored Jul 18, 2001
4 #
5 # This program is free software; you can redistribute it and/or modify
6 # it under the terms of the GNU General Public License as published by
7 # the Free Software Foundation; either version 2 of the License, or
8 # (at your option) any later version.
9 #
10 # This program is distributed in the hope that it will be useful,
11 # but WITHOUT ANY WARRANTY; without even the implied warranty of
12 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 # GNU General Public License for more details.
14 #
15 # You should have received a copy of the GNU General Public
16 # License along with this program; if not, write to the Free
07f71a7 @pajamian New Free Software Foundation Address in headers of various files
pajamian authored Mar 30, 2007
17 # Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,
18 # MA 02110-1301 USA.
b31a690 @jonjensen Move DEV_4_7_0 development branch to repository trunk.
jonjensen authored Jul 18, 2001
19
20 # Uncomment this to turn on verbose mode.
21 #export DH_VERBOSE=1
22
23 ifndef PERL
24 PERL = /usr/bin/perl
25 endif
26 TMP = $(shell pwd)/debian/tmp
27
3aec260 @racke store Interchange version in a global variable, so can conditionalize
racke authored Mar 29, 2002
28 IC_VERSION := $(shell dpkg-parsechangelog | perl -ne 'print $$1 if /^Version: (.*?)-(.*)$$/')
1a56ee0 @racke MAJOR_VERSION variable added for convenience
racke authored Aug 15, 2002
29 IC_MAJOR_VERSION := $(shell dpkg-parsechangelog | perl -ne 'print $$1 if /^Version: (\d+\.\d+)(.*?)-(.*)$$/')
b31a690 @jonjensen Move DEV_4_7_0 development branch to repository trunk.
jonjensen authored Jul 18, 2001
30
31 build: build-stamp
32 build-stamp:
33 dh_testdir
34
35 # Compile main stuff
9a01f20 @racke use new method to build this package with threaded Perl
racke authored Mar 3, 2005
36 env $(PERL) Makefile.PL force=1 \
b31a690 @jonjensen Move DEV_4_7_0 development branch to repository trunk.
jonjensen authored Jul 18, 2001
37 INTERCHANGE_USER=interchange \
38 PREFIX=/usr/lib/interchange
39 $(MAKE)
0ded2fc @racke fix section in interchangeconfig/te manual pages
racke authored Mar 26, 2008
40 pod2man --section=1p debian/interchangeconfig > blib/man1/interchangeconfig.1p
41 pod2man --section=1p eg/te > blib/man1/te.1p
b31a690 @jonjensen Move DEV_4_7_0 development branch to repository trunk.
jonjensen authored Jul 18, 2001
42
43 touch build-stamp
44
45 clean:
46 dh_testdir
47 dh_testroot
6464460 @racke merged changes 2.29 vs 2.29.2.1
racke authored May 15, 2006
48 debconf-updatepo
b31a690 @jonjensen Move DEV_4_7_0 development branch to repository trunk.
jonjensen authored Jul 18, 2001
49 rm -f build-stamp install-stamp
50
51 # Add here commands to clean up after the build process.
4e42250 @racke don't ignore errors on make clean
racke authored Mar 25, 2008
52 [ ! -f Makefile ] || $(MAKE) clean
b31a690 @jonjensen Move DEV_4_7_0 development branch to repository trunk.
jonjensen authored Jul 18, 2001
53
54 dh_clean
55
56 install: build
57 dh_testdir
58 dh_testroot
59 dh_clean -k
60 dh_installdirs
61
62 # Add here commands to install the package into debian/tmp.
84fc232 @racke no black magic needed anymore to build with threaded Perl
racke authored Mar 25, 2008
63 env $(MAKE) install PREFIX=$(TMP)/usr INSTALLARCHLIB=$(TMP)/usr/lib/interchange INSTALLPRIVLIB=$(TMP)/usr/lib/interchange INSTALLMAN1DIR=$(TMP)/usr/share/man/man1 INSTALLMAN3DIR=$(TMP)/usr/share/man/man3 INSTALLSCRIPT=$(TMP)/usr/lib/interchange/bin NOCPANINSTALL=1 INTERCHANGE_USER=interchange
90d0a3d @racke merged changes 2.4.2.7 vs 2.4.2.8
racke authored Dec 6, 2002
64
b31a690 @jonjensen Move DEV_4_7_0 development branch to repository trunk.
jonjensen authored Jul 18, 2001
65 # Sample configuration file not needed (code in interchange.PL
66 # to determine configuration file location will stop to work too)
67 rm $(TMP)/usr/lib/interchange/interchange.cfg.dist
68 # Create symbolic link for the configuration files. Makes
69 # more sense than script hacking.
70 ln -s /etc/interchange/interchange.cfg $(TMP)/usr/lib/interchange
fd60cce @racke update_locales job added
racke authored Feb 13, 2003
71 mkdir -p $(TMP)/etc/interchange
72 mv $(TMP)/usr/lib/interchange/etc/jobs $(TMP)/etc/interchange/jobs
a0b37e7 @racke recommit of changes put into the old branch
racke authored Jul 24, 2001
73 rm -r $(TMP)/usr/lib/interchange/etc
74 ln -s /etc/interchange $(TMP)/usr/lib/interchange/etc
b31a690 @jonjensen Move DEV_4_7_0 development branch to repository trunk.
jonjensen authored Jul 18, 2001
75 # Setup wrapper and config script
b6c5e6c @racke need TAB to keep make happy
racke authored Jul 25, 2001
76 mkdir -p $(TMP)/usr/sbin
b31a690 @jonjensen Move DEV_4_7_0 development branch to repository trunk.
jonjensen authored Jul 18, 2001
77 cp debian/interchange.wrapper $(TMP)/usr/sbin/interchange
78 cp debian/interchangeconfig $(TMP)/usr/sbin/interchangeconfig
79 mkdir -p $(TMP)/usr/bin
80 cp debian/makecat.wrapper $(TMP)/usr/bin/makecat
be54c4d @racke Added te editor for tab-delimited files (Closes: #132757)
racke authored Apr 20, 2004
81 cp eg/te $(TMP)/usr/bin
b31a690 @jonjensen Move DEV_4_7_0 development branch to repository trunk.
jonjensen authored Jul 18, 2001
82 chmod +x $(TMP)/usr/sbin/interchange $(TMP)/usr/sbin/interchangeconfig \
be54c4d @racke Added te editor for tab-delimited files (Closes: #132757)
racke authored Apr 20, 2004
83 $(TMP)/usr/bin/makecat $(TMP)/usr/bin/te
b31a690 @jonjensen Move DEV_4_7_0 development branch to repository trunk.
jonjensen authored Jul 18, 2001
84 # Setup configuration directory
85 mkdir -p $(TMP)/etc/interchange/
86 cp debian/interchange.cfg debian/catalogs.cfg debian/makecat.cfg \
a29d105 * Created a new CountrySubdomains directive. A predefined block
Kevin Walsh authored Sep 2, 2007
87 dist/robots.cfg dist/subdomains.cfg $(TMP)/etc/interchange
b31a690 @jonjensen Move DEV_4_7_0 development branch to repository trunk.
jonjensen authored Jul 18, 2001
88 # build Interchange control program(s)
89 mkdir -p $(TMP)/usr/lib/cgi-bin/ic
90 $(PERL) scripts/compile_link \
d9b41d4 @racke create link programs with --nostrip option to support nostrip build
racke authored Aug 11, 2007
91 --nostrip \
b31a690 @jonjensen Move DEV_4_7_0 development branch to repository trunk.
jonjensen authored Jul 18, 2001
92 --socket=/var/run/interchange/interchange.sock \
93 --port=7786 \
94 --host=127.0.0.1 \
95 --source=dist/src \
96 --build=$(TMP)/usr/lib/cgi-bin/ic
97 cd $(TMP)/usr/lib/cgi-bin/ic; rm compile.pl config* mod_perl_tlink.pl mvctl.c syscfg* testcgi tlink.* vlink.* cpan_local_install
98 # Add link sources
99 mkdir -p $(TMP)/usr/lib/interchange/src
100 for file in dist/src/*; do if test -f $$file; then cp $$file $(TMP)/usr/lib/interchange/src; fi; done
101 # UI images and stuff
c601584 @racke moved CSS and image files for UI from /var/www/interchange-5 to
racke authored Oct 29, 2009
102 mkdir -p $(TMP)/usr/share/interchange-ui
103 for dir in $(TMP)/usr/lib/interchange/share/interchange-5/*; do mv $$dir $(TMP)/usr/share/interchange-ui; done
ef9e0a8 @racke adjusted to new location of UI share files
racke authored Jan 28, 2003
104 rm -r $(TMP)/usr/lib/interchange/share/interchange-5
c601584 @racke moved CSS and image files for UI from /var/www/interchange-5 to
racke authored Oct 29, 2009
105 # Apache configuration file snippet for interchange-ui package
106 mkdir -p $(TMP)/etc/apache2/conf.d
107 install -m 0644 debian/interchange-ui.conf $(TMP)/etc/apache2/conf.d
8d04813 @racke Remove empty crontab manual page after the build.
racke authored Jan 23, 2012
108 # remove empty man pages
109 rm $(TMP)/usr/share/man/man1/crontab.1p
b31a690 @jonjensen Move DEV_4_7_0 development branch to repository trunk.
jonjensen authored Jul 18, 2001
110 # remove unneeded stuff
111 rm $(TMP)/usr/lib/interchange/error.log
719fa48 @racke protect against scripts ending up in /usr/lib/interchange
racke authored Apr 15, 2003
112 rm $(TMP)/usr/lib/interchange/*.pl
b31a690 @jonjensen Move DEV_4_7_0 development branch to repository trunk.
jonjensen authored Jul 18, 2001
113 rm $(TMP)/usr/lib/interchange/_session_storable
114 rm $(TMP)/usr/lib/interchange/_uid
4b80d9c @racke don't throw an error if removal of the file
racke authored Oct 9, 2003
115 rm -rf $(TMP)/usr/lib/interchange/auto/Interchange
b31a690 @jonjensen Move DEV_4_7_0 development branch to repository trunk.
jonjensen authored Jul 18, 2001
116 # install logrotate configuration file
117 install -m 0755 -d $(TMP)/etc/logrotate.d/
118 install -m 0644 debian/interchange.logrotate $(TMP)/etc/logrotate.d/interchange
059e10b @racke initial effort to replacing foundation with standard catalog in Debia…
racke authored Aug 3, 2004
119 # install global usertags for standard demo
120 mkdir -p $(TMP)/usr/lib/interchange/usertag/standard
0aa8f4c @racke drop execute bit from tags in /usr/lib/interchange/usertag/standard
racke authored Oct 27, 2009
121 install -m 0644 dist/standard/config/*.tag $(TMP)/usr/lib/interchange/usertag/standard
3399e80 @racke pragma dml=strict appended to catalog_before.cfg in Debian
racke authored Sep 4, 2009
122 # mimic global pragma for data updates
123 cat debian/catalog_before.cfg >> $(TMP)/usr/lib/interchange/catalog_before.cfg
059e10b @racke initial effort to replacing foundation with standard catalog in Debia…
racke authored Aug 3, 2004
124
3aec260 @racke store Interchange version in a global variable, so can conditionalize
racke authored Mar 29, 2002
125 # make VERSION file
1a56ee0 @racke MAJOR_VERSION variable added for convenience
racke authored Aug 15, 2002
126 echo 'Variable MAJOR_VERSION $(IC_MAJOR_VERSION)' > $(TMP)/usr/lib/interchange/VERSION
127 echo 'Variable VERSION $(IC_VERSION)' >> $(TMP)/usr/lib/interchange/VERSION
b31a690 @jonjensen Move DEV_4_7_0 development branch to repository trunk.
jonjensen authored Jul 18, 2001
128 touch install-stamp
129
130 # Build architecture-independent files here.
131 binary-indep: build install
e130d4c @racke merged changes 2.4.2.8 vs 2.4.2.9
racke authored Jan 22, 2003
132 dh_testdir
133 dh_testroot
134 dh_installdebconf -i
135 dh_installdocs -i -A README.debian
136 # no init.d script
137 # no cron scripts
138 dh_installchangelogs -i
957b335 @racke switched from dh_movefiles to dh_install
racke authored Aug 6, 2007
139 dh_install -i --sourcedir=debian/tmp
e130d4c @racke merged changes 2.4.2.8 vs 2.4.2.9
racke authored Jan 22, 2003
140 dh_compress -i
141 dh_fixperms -i
142 dh_installdeb -i
143 dh_shlibdeps -i
144 dh_perl -i usr/lib/interchange
f38ab17 @racke merged changes 2.29.2.2 vs 2.29.2.4
racke authored Jun 17, 2007
145 dh_gencontrol -i
e130d4c @racke merged changes 2.4.2.8 vs 2.4.2.9
racke authored Jan 22, 2003
146 dh_md5sums -i
147 dh_builddeb -i
b31a690 @jonjensen Move DEV_4_7_0 development branch to repository trunk.
jonjensen authored Jul 18, 2001
148
149 # Build architecture-dependent files here.
150 binary-arch: build install
151 dh_testdir
152 dh_testroot
e130d4c @racke merged changes 2.4.2.8 vs 2.4.2.9
racke authored Jan 22, 2003
153 dh_installdebconf -a
154 dh_installdocs -a -A README.debian
b31a690 @jonjensen Move DEV_4_7_0 development branch to repository trunk.
jonjensen authored Jul 18, 2001
155 # install init.d script
e130d4c @racke merged changes 2.4.2.8 vs 2.4.2.9
racke authored Jan 22, 2003
156 dh_installinit -a -- defaults 21 19
b31a690 @jonjensen Move DEV_4_7_0 development branch to repository trunk.
jonjensen authored Jul 18, 2001
157 # install cron script
e130d4c @racke merged changes 2.4.2.8 vs 2.4.2.9
racke authored Jan 22, 2003
158 dh_installcron -a
159 dh_installchangelogs -a
957b335 @racke switched from dh_movefiles to dh_install
racke authored Aug 6, 2007
160 dh_install -a -p interchange --sourcedir=debian/tmp --exclude=UI --exclude=standard
e130d4c @racke merged changes 2.4.2.8 vs 2.4.2.9
racke authored Jan 22, 2003
161 dh_strip -a
162 dh_compress -a
163 dh_fixperms -a
b31a690 @jonjensen Move DEV_4_7_0 development branch to repository trunk.
jonjensen authored Jul 18, 2001
164 # You may want to make some executables suid here.
e130d4c @racke merged changes 2.4.2.8 vs 2.4.2.9
racke authored Jan 22, 2003
165 dh_installdeb -a
166 dh_shlibdeps -a
167 dh_perl -a usr/lib/interchange
f38ab17 @racke merged changes 2.29.2.2 vs 2.29.2.4
racke authored Jun 17, 2007
168 dh_gencontrol -a
e130d4c @racke merged changes 2.4.2.8 vs 2.4.2.9
racke authored Jan 22, 2003
169 dh_md5sums -a
170 dh_builddeb -a
b31a690 @jonjensen Move DEV_4_7_0 development branch to repository trunk.
jonjensen authored Jul 18, 2001
171
172 binary: binary-indep binary-arch
173 .PHONY: build clean binary-indep binary-arch binary install
Something went wrong with that request. Please try again.