all: newns
newns: newns.c
- $(CC) $(CFLAGS) $^ -o $@
+ $(CC) $(CFLAGS) $(LDFLAGS) $^ -o $@
clean:
rm -f newns
+os-prober (1.58) UNRELEASED; urgency=low
+
+ * Fix cross-building and use dpkg-buildflags.
+
+ -- Colin Watson <cjwatson@debian.org> Wed, 09 Jan 2013 12:44:26 +0000
+
os-prober (1.57) unstable; urgency=low
[ Christian Perrier ]
Priority: optional
Maintainer: Debian Install System Team <debian-boot@lists.debian.org>
Uploaders: Colin Watson <cjwatson@debian.org>, Joey Hess <joeyh@debian.org>, Christian Perrier <bubulle@debian.org>
-Build-Depends: debhelper (>= 7.0.50)
+Build-Depends: debhelper (>= 7.0.50), dpkg-dev (>= 1.15.7)
Standards-Version: 3.9.3
Vcs-Browser: http://git.debian.org/?p=d-i/os-prober.git
Vcs-Git: git://git.debian.org/d-i/os-prober.git
ARCH=x86
endif
+DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
+DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
+
+ifeq ($(DEB_BUILD_GNU_TYPE),$(DEB_HOST_GNU_TYPE))
+CC := gcc
+else
+CC := $(DEB_HOST_GNU_TYPE)-gcc
+endif
+
+export DEB_CFLAGS_MAINT_APPEND := -Os -Wall
+
+CFLAGS := $(shell dpkg-buildflags --get CPPFLAGS; dpkg-buildflags --get CFLAGS)
+LDFLAGS := $(shell dpkg-buildflags --get LDFLAGS)
+
+override_dh_auto_build:
+ $(MAKE) CC=$(CC) CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)"
+
override_dh_install:
dh_install
for probes in os-probes os-probes/mounted os-probes/init \