Title: [opsview-base] [18] sync build scripts with opsview-perl
Revision
18
Author
aburzynski
Date
2012-07-30 17:01:46 +0100 (Mon, 30 Jul 2012)

Log Message

sync build scripts with opsview-perl

Modified Paths


Modified: trunk/Makefile
===================================================================
--- trunk/Makefile	2012-07-30 14:38:44 UTC (rev 17)
+++ trunk/Makefile	2012-07-30 16:01:46 UTC (rev 18)
@@ -230,7 +230,8 @@
 
 debpkg:
 	cp debian/changelog.in debian/changelog
-	VERSION=`cat version` && cd debian && build/mkdeb $$VERSION-1 ..
+	dch --newversion="${BUILD}-${RELEASE}`lsb_release -cs`1" "Auto generated"
+	dpkg-buildpackage -I.svn -i.svn -rfakeroot -uc -b
 
 # Choose /tmp, but name specific to branch
 # If choose within staging, lots of recursion occurs

Modified: trunk/debian/rules
===================================================================
--- trunk/debian/rules	2012-07-30 14:38:44 UTC (rev 17)
+++ trunk/debian/rules	2012-07-30 16:01:46 UTC (rev 18)
@@ -9,10 +9,6 @@
 # Uncomment this to turn on verbose mode.
 #export DH_VERBOSE=1
 
-BUILDDIR := debian/tmp
-DESTDIR=$(CURDIR)/$(BUILDDIR)
-
-
 CFLAGS = -Wall -g
 
 ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
@@ -35,7 +31,7 @@
 	dh_testdir
 
 	# Add here commands to compile the package.
-	$(MAKE) DESTDIR=$(DESTDIR)
+	$(MAKE) DESTDIR=$(CURDIR)/debian/opsview-base all
 	#docbook-to-man debian/opsview-base.sgml > opsview-base.1
 
 	touch $@
@@ -57,7 +53,7 @@
 	dh_installdirs
 
 	# Add here commands to install the package into debian/opsview-base.
-	$(MAKE) install DESTDIR=$(DESTDIR)
+	$(MAKE) DESTDIR=$(CURDIR)/debian/opsview-base install
 
 
 # Build architecture-independent files here.

Modified: trunk/opsview-base.spec.in
===================================================================
--- trunk/opsview-base.spec.in	2012-07-30 14:38:44 UTC (rev 17)
+++ trunk/opsview-base.spec.in	2012-07-30 16:01:46 UTC (rev 18)
@@ -69,15 +69,20 @@
 # This is not so risky, because debian/rules sets DESTDIR at build
 # time too, so other software is not likely to be affected
 %build
-make DESTDIR=$RPM_BUILD_ROOT
+rm -rf %{buildroot}
+mkdir -p %{buildroot}
 
+make DESTDIR=%{buildroot} clean
+make DESTDIR=%{buildroot} all
+
+
 %install
-make install DESTDIR=$RPM_BUILD_ROOT
-mkdir -p $RPM_BUILD_ROOT/etc/init.d/
-cp support_files/opsview-agent $RPM_BUILD_ROOT/etc/init.d/opsview-agent
+make DESTDIR=%{buildroot} install
+mkdir -p %{buildroot}/etc/init.d/
+cp support_files/opsview-agent %{buildroot}/etc/init.d/opsview-agent
 
 %clean
-rm -fr $RPM_BUILD_ROOT
+rm -fr %{buildroot}
 
 %files
 %defattr(-,nagios,nagios)

_______________________________________________
Opsview-checkins mailing list
[email protected]
http://lists.opsview.org/lists/listinfo/opsview-checkins

Reply via email to