[med-svn] [nut-nutrition] 02/03: Switched to short d/rules
Iain Learmonth
irl-guest at moszumanska.debian.org
Sat Jun 7 20:39:06 UTC 2014
This is an automated email from the git hooks/post-receive script.
irl-guest pushed a commit to branch master
in repository nut-nutrition.
commit 95e9a6a579991e6bdf3faec3a9c0ec89dc7ba488
Author: Iain R. Learmonth <irl at fsfe.org>
Date: Sat Jun 7 21:32:45 2014 +0100
Switched to short d/rules
---
debian/dirs | 4 ---
debian/install | 1 +
debian/patches/fix_paths.patch | 31 +++++++++++++++++--
debian/patches/import_ldflags.patch | 2 +-
debian/rules | 59 ++-----------------------------------
5 files changed, 32 insertions(+), 65 deletions(-)
diff --git a/debian/dirs b/debian/dirs
deleted file mode 100644
index 6083d26..0000000
--- a/debian/dirs
+++ /dev/null
@@ -1,4 +0,0 @@
-/usr/bin
-/usr/share/nut-nutrition
-/usr/share/pixmaps
-/usr/share/man/man1
diff --git a/debian/install b/debian/install
new file mode 100644
index 0000000..3bd4498
--- /dev/null
+++ b/debian/install
@@ -0,0 +1 @@
+debian/nut-nutrition.xpm usr/share/pixmaps
diff --git a/debian/patches/fix_paths.patch b/debian/patches/fix_paths.patch
index d9988c8..6b4e69c 100644
--- a/debian/patches/fix_paths.patch
+++ b/debian/patches/fix_paths.patch
@@ -4,11 +4,36 @@ Description: Fix the installation paths in the Makefile
--- nut-nutrition.orig/Makefile
+++ nut-nutrition/Makefile
-@@ -1,5 +1,5 @@
+@@ -1,11 +1,11 @@
-prefix = /usr/local
-libdir = $(prefix)/lib/nut
-+prefix = /usr
++prefix = debian/nut-nutrition/usr
+libdir = $(prefix)/share/nut-nutrition
bindir = $(prefix)/bin
- mandir = $(prefix)/man/man1
+-mandir = $(prefix)/man/man1
++mandir = $(prefix)/share/man/man1
+ NUTDIR := \".nutdb\"
+ FOODDIR := \"$(libdir)\"
+-EXECUTABLE := nut
++EXECUTABLE := nut-nutrition
+ LIBS := -lm
+
+ FLTK_CONFIG := $(shell fltk-config --version 2>/dev/null)
+@@ -57,11 +57,12 @@
+
+ install: all
+ -mkdir -p -m 755 $(bindir) $(libdir) $(mandir)
+- -cp nut $(FLTK_NUT) $(bindir)
+- -cd $(bindir); strip nut Nut
++ -cp nut-nutrition $(bindir)
++ -cp $(FLTK_NUT) $(bindir)
++ -cd $(bindir); strip nut-nutrition Nut
+ -rm -f $(libdir)/sr*.nut 2>/dev/null
+ -cp raw.data/* $(libdir)
+- -cp nut.1 $(mandir)
+- -chmod a+r $(libdir)/* $(mandir)/nut.1
++ -cp nut.1 $(mandir)/nut-nutrition.1
++ -chmod a+r $(libdir)/* $(mandir)/nut-nutrition.1
+
+ # DO NOT DELETE
diff --git a/debian/patches/import_ldflags.patch b/debian/patches/import_ldflags.patch
index 2fa05c5..1f8c75d 100644
--- a/debian/patches/import_ldflags.patch
+++ b/debian/patches/import_ldflags.patch
@@ -5,7 +5,7 @@ Description: Added hardening flags to build process
--- nut-nutrition.orig/Makefile
+++ nut-nutrition/Makefile
@@ -8,6 +8,11 @@
- EXECUTABLE := nut
+ EXECUTABLE := nut-nutrition
LIBS := -lm
+CPPFLAGS:=$(shell dpkg-buildflags --get CPPFLAGS)
diff --git a/debian/rules b/debian/rules
index 46721ea..70c35ea 100755
--- a/debian/rules
+++ b/debian/rules
@@ -3,61 +3,6 @@
DESTDIR=$(CURDIR)/debian/nut-nutrition
-build: build-arch build-indep
+%:
+ dh $@
-build-arch: build-stamp
-
-build-indep: build-stamp
-
-build-stamp:
- dh_testdir
-
- $(MAKE)
-
- touch build-stamp
-
-clean:
- dh_testdir
- dh_testroot
- rm -f build-stamp configure-stamp
-
- $(MAKE) -k clean
-
- dh_clean
-
-install: build
- dh_testdir
- dh_testroot
- dh_prep
- dh_installdirs
-
- install -m644 raw.data/* $(DESTDIR)/usr/share/nut-nutrition/
- install -m644 debian/nut.xpm $(DESTDIR)/usr/share/pixmaps/nut-nutrition.xpm
- install -m644 nut.1 $(DESTDIR)/usr/share/man/man1/nut-nutrition.1
- install nut $(DESTDIR)/usr/bin/nut-nutrition
-
-# Build architecture-independent files here.
-binary-indep: build install
-# We have nothing to do by default.
-
-# Build architecture-dependent files here.
-binary-arch: build install
- dh_testdir
- dh_testroot
- dh_installchangelogs
- dh_installdocs
- dh_installexamples
- dh_installmenu
- dh_installman
- dh_link
- dh_strip
- dh_compress
- dh_fixperms
- dh_installdeb
- dh_shlibdeps
- dh_gencontrol
- dh_md5sums
- dh_builddeb
-
-binary: binary-indep binary-arch
-.PHONY: build clean binary-indep binary-arch binary install
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-med/nut-nutrition.git
More information about the debian-med-commit
mailing list