File: rules

package info (click to toggle)
netatalk 2.0.3-4%2Betch2
  • links: PTS
  • area: main
  • in suites: etch
  • size: 9,012 kB
  • ctags: 6,109
  • sloc: ansic: 67,633; sh: 8,424; perl: 1,187; makefile: 1,001
file content (53 lines) | stat: -rwxr-xr-x 2,204 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
#!/usr/bin/make -f

include /usr/share/cdbs/1/rules/debhelper.mk
include /usr/share/cdbs/1/class/autotools.mk
include /usr/share/cdbs/1/rules/simple-patchsys.mk

DEB_UPDATE_RCD_PARAMS := defaults 50

DEB_CONFIGURE_EXTRA_FLAGS := \
	--with-shadow --enable-fhs					\
	--with-tcp-wrappers --with-mangling				\
	--enable-timelord --enable-overwrite				\
	--with-pkgconfdir=/etc/netatalk					\
	--with-nls-dir=/usr/share/netatalk/nls				\
	--disable-logger --enable-srvloc				\
	--enable-pgp-uam --enable-krb4-uam --enable-krbV-uam

##FIXME: Other changes are needed, like enabling DHX plugin
ifneq (,$(findstring ssl,$(DEB_BUILD_OPTIONS)))
DEB_CONFIGURE_EXTRA_FLAGS += --with-ssl-dir \
	--with-cracklib=/var/cache/cracklib/cracklib_dict
DEB_DH_GENCONTROL_ARGS := -- -Vssl:Recommends=", cracklib-runtime, libpam-cracklib"
else
DEB_CONFIGURE_EXTRA_FLAGS += --without-ssl-dir
endif

binary-post-install/netatalk::
	mv debian/netatalk/etc/netatalk/netatalk.conf debian/netatalk/etc/default/netatalk
ifneq (,$(findstring ssl,$(DEB_BUILD_OPTIONS)))
	install -m 644 debian/netatalk.pam-ssl debian/netatalk/etc/pam.d/netatalk
	perl -i -pe 's/^#AFPD_UAMLIST=.*/#AFPD_UAMLIST="-U uams_dhx.so,uams_clrtxt.so,uams_randnum.so"/' debian/netatalk/etc/default/netatalk
	perl -i -pe 's/^AFPD_UAMLIST=.*/AFPD_UAMLIST="-U uams_dhx.so,uams_clrtxt.so,uams_randnum.so"/' debian/netatalk/etc/init.d/netatalk
else
	install -m 644 debian/netatalk.pam debian/netatalk/etc/pam.d/netatalk
endif

	# Rename manpages because of namespace conflicts
	mv debian/netatalk/usr/share/man/man1/uniconv.1 debian/netatalk/usr/share/man/man1/netatalk-uniconv.1
	mv debian/netatalk/usr/share/man/man1/afile.1 debian/netatalk/usr/share/man/man1/apple_file.1
	mv debian/netatalk/usr/share/man/man1/achfile.1 debian/netatalk/usr/share/man/man1/apple_chfile.1

	# Remove unnecessary files
	rm debian/netatalk/usr/bin/netatalk-config
	rm debian/netatalk/usr/bin/timeout
	rm debian/netatalk/usr/lib/libatalk.*
	rm debian/netatalk/usr/share/man/man1/timeout.1
	rm debian/netatalk/usr/share/man/man1/afppasswd.1
	rm -r debian/netatalk/usr/include
	rm -r debian/netatalk/usr/share/aclocal
	rm -r debian/netatalk/var

	# Store build information
	dh_buildinfo