#!/usr/bin/make -f # Uncomment this to turn on verbose mode. #export DH_VERBOSE=1 # This has to be exported to make some magic below work. export DH_OPTIONS # These are used for cross-compiling and for saving the configure script # from having to guess our platform (since we know it already) include /usr/share/dpkg/architecture.mk DEB_BUILD_MAINT_OPTIONS = hardening=+all DPKG_EXPORT_BUILDFLAGS = 1 include /usr/share/dpkg/buildflags.mk config.status: cp /usr/share/misc/config.sub /usr/share/misc/config.guess . dh_testdir dh_autoreconf # Add here commands to configure the package. CFLAGS="$(CFLAGS)" CPPFLAGS="$(CPPFLAGS)" LDFLAGS="$(LDFLAGS)" ./configure --host=$(DEB_HOST_GNU_TYPE) \ --build=$(DEB_BUILD_GNU_TYPE) \ --prefix=/usr \ --libdir=/usr/lib/$(DEB_HOST_MULTIARCH) \ --with-openssl \ --mandir=\$${prefix}/share/man \ --infodir=\$${prefix}/share/info \ --with-python=no \ --disable-rpath build: build-arch build-indep build-arch: build-stamp build-indep: build-stamp build-stamp: config.status # Add here commands to compile the arch part of the package. $(MAKE) touch build-arch-stamp clean: dh_testdir dh_testroot rm -f build-arch-stamp #CONFIGURE-STAMP# # Add here commands to clean up after the build process. [ ! -f Makefile ] || $(MAKE) distclean # generated file not removed by upstream Makefile rm -f swig/python/openipmigui/Makefile rm -f config.sub config.guess dh_autoreconf_clean dh_clean install: install-arch install-arch: dh_testdir dh_testroot dh_prep dh_installdirs -a # Add here commands to install the arch part of the package into # debian/tmp. mkdir -p $(CURDIR)/debian/tmp/usr/bin $(MAKE) install DESTDIR=$(CURDIR)/debian/tmp # remove useless rpath from libOpenIPMIposix (which is built with # -R/usr/lib, whereas only -rpath=/usr/lib is disabled by # --disable-rpath) chrpath -d debian/tmp/usr/lib/*/libOpenIPMIposix.so.*.* dh_movefiles dh_install -a # Must not depend on anything. This is to be called by binary-indep: # in another 'make' thread. binary-common: dh_testdir dh_testroot dh_installchangelogs ChangeLog dh_installdocs dh_installexamples dh_installinit -p openipmi --name openipmi --no-start -- defaults 21 20 mv ipmi.sysconf openipmi dh_install openipmi etc/default dh_installman dh_link dh_strip dh_compress dh_fixperms dh_makeshlibs dh_installdeb dh_shlibdeps dh_gencontrol dh_md5sums dh_builddeb # Build architecture dependant packages using the common target. binary-arch: build-arch install-arch $(MAKE) -f debian/rules DH_OPTIONS=-a binary-common binary: binary-arch .PHONY: build clean binary-arch binary install install-arch