gunnar: server/make-helper kolab.mk,1.4,1.5

cvs at kolab.org cvs at kolab.org
Tue Feb 9 15:14:57 CET 2010


Author: gunnar

Update of /kolabrepository/server/make-helper
In directory doto:/tmp/cvs-serv8244/make-helper

Modified Files:
	kolab.mk 
Log Message:
Added a marker file that allows to indicate that we are in a test environment. It contains a few variables that define basic parameters of the environment. Added a install-server target to the central Makefile. It installs a server from binary packages.

Index: kolab.mk
===================================================================
RCS file: /kolabrepository/server/make-helper/kolab.mk,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- kolab.mk	18 Jan 2010 22:56:33 -0000	1.4
+++ kolab.mk	9 Feb 2010 14:14:55 -0000	1.5
@@ -1,7 +1,18 @@
+# Check if we are in a test environment
+TEST_ENVIRONMENT=$(shell test -e test_environment && echo YES)
+ifeq "x$(TEST_ENVIRONMENT)" "xYES"
+    BINARY_SOURCE_DIR=$(shell source test_environment && echo $$BINARY_SOURCE_DIR)
+endif
+
 # Initial sanity check for the OpenPKG tool
 OPENPKG=$(shell which openpkg && echo YES)
 ifeq "x$(OPENPKG)" "x"
-  $(error Did not find the "openpkg" tool. Make sure your environment settings are sane. On a standard kolab system you might need to run "eval `/kolab/etc/rc --eval all env`")
+  ifeq "x$(TEST_ENVIRONMENT)" "x"
+    $(error Did not find the "openpkg" tool. Make sure your environment settings are sane. On a standard kolab system you might need to run "eval `/kolab/etc/rc --eval all env`")
+  else
+    KOLABDIR=$(shell source test_environment && echo $$KOLABDIR)
+    OPENPKG=$(KOLABDIR)/bin/openpkg
+  endif
 endif
 
 # Set KOLABDIR to the base directory of the OpenPKG/Kolab installation if it is unset
@@ -37,7 +48,10 @@
 OPENPKGURI ?= http://files.kolab.org/server/development-2.2/openpkg-orig-srpms/
 
 # Determine the suffix for binary packages on this system if it is unset
-PLATTAG ?= $(shell $(RPM) -q --qf="%{ARCH}-%{OS}" openpkg)-$(KOLABDIR:/%=%)
+PLATFORM ?= $(shell $(RPM) -q --qf="%{ARCH}-%{OS}" openpkg)
+
+# Determine the suffix for binary packages on this system if it is unset
+PLATTAG ?= $(PLATFORM)-$(KOLABDIR:/%=%)
 
 # Determine the staging area for collecting new source rpms if it is unset
 STAGING ?= ../stage





More information about the commits mailing list