source: trunk/debathena/debathena/libnss-nonlocal/debian/rules @ 24756

Revision 24756, 3.1 KB checked in by andersk, 14 years ago (diff)
In libnss-nonlocal: * Remove the workaround for buggy CDBS $(CC) splitting (fixed upstream). * Fix cross-compiling on karmic and lucid.
  • Property svn:executable set to *
Line 
1#!/usr/bin/make -f
2
3DEB_AUTO_UPDATE_AUTOCONF = 2.50
4DEB_AUTO_UPDATE_AUTOHEADER = 2.50
5DEB_AUTO_UPDATE_AUTOMAKE = 1.9
6DEB_AUTO_UPDATE_ACLOCAL = 1.9
7DEB_AUTO_UPDATE_LIBTOOL = pre
8
9include /usr/share/cdbs/1/rules/debhelper.mk
10include /usr/share/cdbs/1/class/autotools.mk
11
12DEB_DESTDIR = $(CURDIR)/debian/tmp/
13DEB_DH_INSTALL_SOURCEDIR = $(DEB_DESTDIR)
14DEB_CONFIGURE_PREFIX = /
15
16IS_UBUNTU := $(if $(filter Ubuntu,$(shell lsb_release -is)),y)
17LIBC6_VERSION := $(shell dpkg-query --showformat='$${Version}' --show libc6)
18libc6_ge = $(shell dpkg --compare-versions '$(LIBC6_VERSION)' ge '$(1)' && echo y)
19
20ifeq ($(call libc6_ge,2.8+20080809),y)
21    DEB_DH_SHLIBDEPS_ARGS = -- -xglibc-private
22endif
23
24debian/stamp-autotools-files: DEB_AUTO_UPDATE_AUTOMAKE += --foreign --add-missing
25
26debian/stamp-autotools-files: aclocal.m4
27aclocal.m4:
28        touch $@
29
30DEB_BUILDDIR = $(or $(DEB_BUILDDIR_$(cdbs_curpkg)),debian/build)
31
32REAL_DEB_HOST_GNU_TYPE := $(DEB_HOST_GNU_TYPE)
33
34DEB_BUILDDIR_lib32nss-nonlocal = debian/build_32
35cleanbuilddir/lib32nss-nonlocal:: clean/lib32nss-nonlocal
36configure/lib32nss-nonlocal:: cdbs_crossbuild =
37# i386_configure_target in eglibc/debian/sysdeps/amd64.mk
38ifeq ($(or $(IS_UBUNTU),$(call libc6_ge,2.8+20080809)),y)
39configure/lib32nss-nonlocal:: DEB_BUILD_GNU_TYPE = i686-linux
40else
41configure/lib32nss-nonlocal:: DEB_BUILD_GNU_TYPE = i486-linux
42endif
43# i386_CC in eglibc/debian/sysdeps/amd64.mk
44configure/lib32nss-nonlocal:: CC += -m32
45# i386_slibdir in eglibc/debian/sysdeps/amd64.mk
46ifeq ($(or $(IS_UBUNTU),$(call libc6_ge,2.9-14~)),y)
47configure/lib32nss-nonlocal:: DEB_CONFIGURE_EXTRA_FLAGS += --libdir="\$${prefix}/lib32"
48binary-install/lib32nss-nonlocal:: DEB_DH_INSTALL_ARGS = 'lib32/*'
49else
50configure/lib32nss-nonlocal:: DEB_CONFIGURE_PREFIX = /emul/ia32-linux
51binary-install/lib32nss-nonlocal:: DEB_DH_INSTALL_ARGS = 'emul/ia32-linux/lib/*'
52endif
53
54DEB_BUILDDIR_lib64nss-nonlocal = debian/build_64
55cleanbuilddir/lib64nss-nonlocal:: clean/lib64nss-nonlocal
56configure/lib64nss-nonlocal:: cdbs_crossbuild =
57# amd64_configure_target in eglibc/debian/sysdeps/i386.mk
58configure/lib64nss-nonlocal:: DEB_BUILD_GNU_TYPE = x86_64-linux
59# amd64_CC in eglibc/debian/sysdeps/i386.mk
60configure/lib64nss-nonlocal:: CC += -m64 -D__x86_64__
61# amd64_slibdir in eglibc/debian/sysdeps/i386.mk
62configure/lib64nss-nonlocal:: DEB_CONFIGURE_EXTRA_FLAGS += --libdir="\$${prefix}/lib64"
63
64# Fix for CDBS ≥ 0.4.59ubuntu4, < 0.4.83ubuntu1 (karmic and lucid).
65configure/lib32nss-nonlocal configure/lib64nss-nonlocal:: DEB_CONFIGURE_SCRIPT_ENV += CC="$(CC)"
66
67configure/lib32nss-nonlocal configure/lib64nss-nonlocal::
68        $(DEB_CONFIGURE_INVOKE) $(cdbs_configure_flags) $(DEB_CONFIGURE_EXTRA_FLAGS) $(DEB_CONFIGURE_USER_FLAGS)
69
70build/lib32nss-nonlocal build/lib64nss-nonlocal::
71        +$(DEB_MAKE_INVOKE) $(DEB_MAKE_BUILD_TARGET)
72
73install/lib32nss-nonlocal install/lib64nss-nonlocal::
74        +$(DEB_MAKE_INVOKE) $(DEB_MAKE_INSTALL_TARGET)
75
76clean/lib32nss-nonlocal clean/lib64nss-nonlocal::
77        +-$(DEB_MAKE_INVOKE) -k $(DEB_MAKE_CLEAN_TARGET)
78
79clean::
80        rm -f aclocal.m4 config.guess config.sub install-sh ltmain.sh \
81            configure config.h.in missing depcomp Makefile.in
Note: See TracBrowser for help on using the repository browser.