summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSimo Sorce <ssorce@redhat.com>2008-08-08 09:35:05 -0400
committerSimo Sorce <ssorce@redhat.com>2008-08-11 18:31:05 -0400
commit9648da8f5f5e4292451f1ba796c4fd027585fdce (patch)
treeabcc4b616dd33a9b770dd1266a1c2d700f671e70
parent0368d4329ae54d97b6fb5da60580beefa29d07bc (diff)
downloadfreeipa-9648da8f5f5e4292451f1ba796c4fd027585fdce.tar.gz
freeipa-9648da8f5f5e4292451f1ba796c4fd027585fdce.tar.xz
freeipa-9648da8f5f5e4292451f1ba796c4fd027585fdce.zip
Fix versioning for configure.ac and ipa-python/setup.py
Fix make maintainer-clean Also make RPM naming consistent by using a temp RELEASE file. This one helps when testing builds using rpms. Just 'echo X > RELEASE' to build a new rpms (X, X+1, X+2 ...) Version 1.1.0 was released some times ago, bump up to 1.1.1
-rw-r--r--Makefile57
-rw-r--r--VERSION2
-rw-r--r--ipa-admintools/Makefile5
-rwxr-xr-xipa-admintools/ipa-admintools.spec.in4
-rw-r--r--ipa-client/Makefile.am1
-rw-r--r--ipa-client/configure.ac3
-rw-r--r--ipa-client/ipa-client.spec.in4
-rw-r--r--ipa-client/version.m4.in1
-rw-r--r--ipa-python/Makefile3
-rwxr-xr-xipa-python/ipa-python.spec.in4
-rw-r--r--ipa-python/setup.py.in2
-rw-r--r--ipa-radius-admintools/Makefile5
-rw-r--r--ipa-radius-admintools/ipa-radius-admintools.spec.in4
-rw-r--r--ipa-radius-server/Makefile5
-rwxr-xr-xipa-radius-server/ipa-radius-server.spec.in4
-rw-r--r--ipa-server/Makefile.am1
-rw-r--r--ipa-server/configure.ac3
-rw-r--r--ipa-server/ipa-server.spec.in4
-rw-r--r--ipa-server/selinux/Makefile6
-rw-r--r--ipa-server/selinux/ipa-server-selinux.spec.in4
-rw-r--r--ipa-server/version.m4.in1
21 files changed, 78 insertions, 45 deletions
diff --git a/Makefile b/Makefile
index f66e42816..f4d42148b 100644
--- a/Makefile
+++ b/Makefile
@@ -50,19 +50,21 @@ RADIUS_ADMINTOOLS_TARBALL=$(RADIUS_ADMINTOOLS_TARBALL_PREFIX).tgz
SERV_SELINUX_TARBALL_PREFIX=$(PRJ_PREFIX)-server-selinux-$(IPA_VERSION)
SERV_SELINUX_TARBALL=$(SERV_SELINUX_TARBALL_PREFIX).tgz
+IPA_RPM_RELEASE=$(shell cat RELEASE)
+
LIBDIR ?= /usr/lib
-all: version-update bootstrap-autogen
+all: bootstrap-autogen
@for subdir in $(SUBDIRS); do \
(cd $$subdir && $(MAKE) $@) || exit 1; \
done
-bootstrap-autogen:
+bootstrap-autogen: version-update
@echo "Building IPA $(IPA_VERSION)"
cd ipa-server; if [ ! -e Makefile ]; then ./autogen.sh --prefix=/usr --sysconfdir=/etc --localstatedir=/var --libdir=$(LIBDIR); fi
cd ipa-client; if [ ! -e Makefile ]; then ./autogen.sh --prefix=/usr --sysconfdir=/etc --localstatedir=/var --libdir=$(LIBDIR); fi
-autogen:
+autogen: version-update
@echo "Building IPA $(IPA_VERSION)"
cd ipa-server; ./autogen.sh --prefix=/usr --sysconfdir=/etc --localstatedir=/var --libdir=$(LIBDIR)
cd ipa-client; ./autogen.sh --prefix=/usr --sysconfdir=/etc --localstatedir=/var --libdir=$(LIBDIR)
@@ -81,30 +83,41 @@ test:
(cd $$subdir && $(MAKE) $@) || exit 1; \
done
-version-update:
- sed s/VERSION/$(IPA_VERSION)/ ipa-server/ipa-server.spec.in \
- > ipa-server/ipa-server.spec
+release-update:
+ if [ ! -e RELEASE ]; then echo 0 > RELEASE; fi
+
+version-update: release-update
+ sed -e s/__VERSION__/$(IPA_VERSION)/ -e s/__RELEASE__/$(IPA_RPM_RELEASE)/ \
+ ipa-server/ipa-server.spec.in > ipa-server/ipa-server.spec
+ sed -e s/__VERSION__/$(IPA_VERSION)/ ipa-server/version.m4.in \
+ > ipa-server/version.m4
- sed s/VERSION/$(IPA_VERSION)/ ipa-admintools/ipa-admintools.spec.in \
- > ipa-admintools/ipa-admintools.spec
+ sed -e s/__VERSION__/$(IPA_VERSION)/ -e s/__RELEASE__/$(IPA_RPM_RELEASE)/ \
+ ipa-admintools/ipa-admintools.spec.in > ipa-admintools/ipa-admintools.spec
- sed s/VERSION/$(IPA_VERSION)/ ipa-python/ipa-python.spec.in \
- > ipa-python/ipa-python.spec
+ sed -e s/__VERSION__/$(IPA_VERSION)/ -e s/__RELEASE__/$(IPA_RPM_RELEASE)/ \
+ ipa-python/ipa-python.spec.in > ipa-python/ipa-python.spec
- sed s/VERSION/$(IPA_VERSION)/ ipa-client/ipa-client.spec.in \
- > ipa-client/ipa-client.spec
+ sed -e s/__VERSION__/$(IPA_VERSION)/ -e s/__RELEASE__/$(IPA_RPM_RELEASE)/ \
+ ipa-client/ipa-client.spec.in > ipa-client/ipa-client.spec
+ sed -e s/__VERSION__/$(IPA_VERSION)/ ipa-client/version.m4.in \
+ > ipa-client/version.m4
- sed s/VERSION/$(IPA_VERSION)/ ipa-radius-server/ipa-radius-server.spec.in \
+ sed -e s/__VERSION__/$(IPA_VERSION)/ -e s/__RELEASE__/$(IPA_RPM_RELEASE)/ \
+ ipa-radius-server/ipa-radius-server.spec.in \
> ipa-radius-server/ipa-radius-server.spec
- sed s/VERSION/$(IPA_VERSION)/ ipa-radius-admintools/ipa-radius-admintools.spec.in \
+ sed -e s/__VERSION__/$(IPA_VERSION)/ -e s/__RELEASE__/$(IPA_RPM_RELEASE)/ \
+ ipa-radius-admintools/ipa-radius-admintools.spec.in \
> ipa-radius-admintools/ipa-radius-admintools.spec
- sed s/VERSION/$(IPA_VERSION)/ ipa-server/selinux/ipa-server-selinux.spec.in \
+ sed -e s/__VERSION__/$(IPA_VERSION)/ -e s/__RELEASE__/$(IPA_RPM_RELEASE)/ \
+ ipa-server/selinux/ipa-server-selinux.spec.in \
> ipa-server/selinux/ipa-server-selinux.spec
- sed s/VERSION/$(IPA_VERSION)/ ipa-python/setup.py.in \
+
+ sed -e s/__VERSION__/$(IPA_VERSION)/ ipa-python/setup.py.in \
> ipa-python/setup.py
- sed s/__VERSION__/$(IPA_VERSION)/ ipa-python/version.py.in \
+ sed -e s/__VERSION__/$(IPA_VERSION)/ ipa-python/version.py.in \
> ipa-python/version.py
perl -pi -e "s:__NUM_VERSION__:$(IPA_VERSION_MAJOR)$(IPA_VERSION_MINOR)$(IPA_VERSION_RELEASE):" ipa-python/version.py
@@ -226,16 +239,16 @@ repodata:
dist: version-update archive tarballs archive-cleanup rpms repodata
-local-dist: autogen clean version-update local-archive tarballs archive-cleanup rpms
+local-dist: autogen clean local-archive tarballs archive-cleanup rpms
-clean:
+clean: version-update
@for subdir in $(SUBDIRS); do \
(cd $$subdir && $(MAKE) $@) || exit 1; \
done
rm -f *~
-distclean:
+distclean: version-update
@for subdir in $(SUBDIRS); do \
(cd $$subdir && $(MAKE) $@) || exit 1; \
done
@@ -243,6 +256,10 @@ distclean:
maintainer-clean: clean
rm -fr rpmbuild dist
+ cd ipa-server/selinux && $(MAKE) maintainer-clean
cd ipa-server && $(MAKE) maintainer-clean
cd ipa-client && $(MAKE) maintainer-clean
cd ipa-python && $(MAKE) maintainer-clean
+ cd ipa-admintools && $(MAKE) maintainer-clean
+ cd ipa-radius-admintools && $(MAKE) maintainer-clean
+ cd ipa-radius-server && $(MAKE) maintainer-clean
diff --git a/VERSION b/VERSION
index c065337c0..4cbdf7146 100644
--- a/VERSION
+++ b/VERSION
@@ -20,7 +20,7 @@
########################################################
IPA_VERSION_MAJOR=1
IPA_VERSION_MINOR=1
-IPA_VERSION_RELEASE=0
+IPA_VERSION_RELEASE=1
########################################################
# For 'pre' releases the version will be #
diff --git a/ipa-admintools/Makefile b/ipa-admintools/Makefile
index 77cc38d54..4a76cc8b1 100644
--- a/ipa-admintools/Makefile
+++ b/ipa-admintools/Makefile
@@ -35,8 +35,11 @@ install-man:
install -m 644
clean:
- rm -f *~ *.pyc ipa-admintools.spec
+ rm -f *~ *.pyc
distclean: clean
+ rm -f ipa-admintools.spec
+
+maintainer-clean: distclean
test:
diff --git a/ipa-admintools/ipa-admintools.spec.in b/ipa-admintools/ipa-admintools.spec.in
index 4c1ea3576..ea03923ae 100755
--- a/ipa-admintools/ipa-admintools.spec.in
+++ b/ipa-admintools/ipa-admintools.spec.in
@@ -1,6 +1,6 @@
Name: ipa-admintools
-Version: VERSION
-Release: 2%{?dist}
+Version: __VERSION__
+Release: __RELEASE__%{?dist}
Summary: IPA admin tools
Group: System Environment/Base
diff --git a/ipa-client/Makefile.am b/ipa-client/Makefile.am
index b93e6f35b..796a923fa 100644
--- a/ipa-client/Makefile.am
+++ b/ipa-client/Makefile.am
@@ -74,6 +74,7 @@ MAINTAINERCLEANFILES = \
Makefile.in \
config.h.* \
aclocal.m4 \
+ version.m4 \
ipa-client.spec \
py-compile \
$(NULL)
diff --git a/ipa-client/configure.ac b/ipa-client/configure.ac
index c9dbdfae3..b639e1d14 100644
--- a/ipa-client/configure.ac
+++ b/ipa-client/configure.ac
@@ -1,6 +1,7 @@
AC_PREREQ(2.59)
+m4_include(version.m4)
AC_INIT([ipa-client],
- [0.6.0],
+ IPA_VERSION,
[https://hosted.fedoraproject.org/projects/freeipa/newticket])
AC_CONFIG_SRCDIR([ipaclient/__init__.py])
diff --git a/ipa-client/ipa-client.spec.in b/ipa-client/ipa-client.spec.in
index f228b863f..686259ad2 100644
--- a/ipa-client/ipa-client.spec.in
+++ b/ipa-client/ipa-client.spec.in
@@ -1,6 +1,6 @@
Name: ipa-client
-Version: VERSION
-Release: 1%{?dist}
+Version: __VERSION__
+Release: __RELEASE__%{?dist}
Summary: IPA client
Group: System Environment/Base
diff --git a/ipa-client/version.m4.in b/ipa-client/version.m4.in
new file mode 100644
index 000000000..5ddc8cea3
--- /dev/null
+++ b/ipa-client/version.m4.in
@@ -0,0 +1 @@
+define([IPA_VERSION], [__VERSION__])
diff --git a/ipa-python/Makefile b/ipa-python/Makefile
index 131604578..4ac027e14 100644
--- a/ipa-python/Makefile
+++ b/ipa-python/Makefile
@@ -13,9 +13,10 @@ install:
fi
clean:
- rm -f *~ *.pyc setup.py ipa-python.spec version.py
+ rm -f *~ *.pyc
distclean: clean
+ rm -f setup.py ipa-python.spec version.py
maintainer-clean: distclean
rm -rf build
diff --git a/ipa-python/ipa-python.spec.in b/ipa-python/ipa-python.spec.in
index 774464951..a41a413e6 100755
--- a/ipa-python/ipa-python.spec.in
+++ b/ipa-python/ipa-python.spec.in
@@ -1,6 +1,6 @@
Name: ipa-python
-Version: VERSION
-Release: 1%{?dist}
+Version: __VERSION__
+Release: __RELEASE__%{?dist}
Summary: IPA authentication server
Group: System Environment/Base
diff --git a/ipa-python/setup.py.in b/ipa-python/setup.py.in
index a48b8e690..19940f38f 100644
--- a/ipa-python/setup.py.in
+++ b/ipa-python/setup.py.in
@@ -52,7 +52,7 @@ def setup_package():
try:
setup(
name = "ipa",
- version = "0.6.0",
+ version = "__VERSION__",
license = "GPL",
author = "Karl MacMillan, et.al.",
author_email = "kmacmill@redhat.com",
diff --git a/ipa-radius-admintools/Makefile b/ipa-radius-admintools/Makefile
index 61aa35f50..0bb7824db 100644
--- a/ipa-radius-admintools/Makefile
+++ b/ipa-radius-admintools/Makefile
@@ -14,8 +14,11 @@ install:
install -m 755 ipa-findradiusprofile $(SBINDIR)
clean:
- rm -f *~ *.pyc ipa-radius-admintools.spec
+ rm -f *~ *.pyc
distclean: clean
+ rm -f ipa-radius-admintools.spec
+
+maintainer-clean: distclean
test:
diff --git a/ipa-radius-admintools/ipa-radius-admintools.spec.in b/ipa-radius-admintools/ipa-radius-admintools.spec.in
index b7889777a..f0066aca9 100644
--- a/ipa-radius-admintools/ipa-radius-admintools.spec.in
+++ b/ipa-radius-admintools/ipa-radius-admintools.spec.in
@@ -1,6 +1,6 @@
Name: ipa-radius-admintools
-Version: VERSION
-Release: 1%{?dist}
+Version: __VERSION__
+Release: __RELEASE__%{?dist}
Summary: IPA authentication server - radius admin tools
Group: System Environment/Base
diff --git a/ipa-radius-server/Makefile b/ipa-radius-server/Makefile
index 795f2f2b2..85617b9b0 100644
--- a/ipa-radius-server/Makefile
+++ b/ipa-radius-server/Makefile
@@ -13,8 +13,11 @@ install:
install -m 755 ipa-radius-install $(SBINDIR)
clean:
- rm -fr *.pyc *~ ipa-radius-server.spec
+ rm -fr *.pyc *~
distclean: clean
+ rm -fr ipa-radius-server.spec
+
+maintainer-clean: distclean
test:
diff --git a/ipa-radius-server/ipa-radius-server.spec.in b/ipa-radius-server/ipa-radius-server.spec.in
index 2ed0fe070..b29dfc780 100755
--- a/ipa-radius-server/ipa-radius-server.spec.in
+++ b/ipa-radius-server/ipa-radius-server.spec.in
@@ -1,6 +1,6 @@
Name: ipa-radius-server
-Version: VERSION
-Release: 1%{?dist}
+Version: __VERSION__
+Release: __RELEASE__%{?dist}
Summary: IPA authentication server - radius plugin
Group: System Environment/Base
diff --git a/ipa-server/Makefile.am b/ipa-server/Makefile.am
index a0e8bdad9..6fb854d3e 100644
--- a/ipa-server/Makefile.am
+++ b/ipa-server/Makefile.am
@@ -62,6 +62,7 @@ MAINTAINERCLEANFILES = \
Makefile.in \
config.h.* \
aclocal.m4 \
+ version.m4 \
ipa-server.spec \
py-compile \
$(NULL)
diff --git a/ipa-server/configure.ac b/ipa-server/configure.ac
index 341c07094..7260559c8 100644
--- a/ipa-server/configure.ac
+++ b/ipa-server/configure.ac
@@ -1,6 +1,7 @@
AC_PREREQ(2.59)
+m4_include(version.m4)
AC_INIT([ipa-server],
- [0.6.0],
+ IPA_VERSION,
[https://hosted.fedoraproject.org/projects/freeipa/newticket])
AC_CONFIG_SRCDIR([ipaserver/ipaldap.py])
diff --git a/ipa-server/ipa-server.spec.in b/ipa-server/ipa-server.spec.in
index e5bb5b9db..4a7840529 100644
--- a/ipa-server/ipa-server.spec.in
+++ b/ipa-server/ipa-server.spec.in
@@ -1,6 +1,6 @@
Name: ipa-server
-Version: VERSION
-Release: 3%{?dist}
+Version: __VERSION__
+Release: __RELEASE__%{?dist}
Summary: IPA authentication server
Group: System Environment/Base
diff --git a/ipa-server/selinux/Makefile b/ipa-server/selinux/Makefile
index 3d42a4c7f..a662d2fd4 100644
--- a/ipa-server/selinux/Makefile
+++ b/ipa-server/selinux/Makefile
@@ -13,11 +13,11 @@ clean:
@for subdir in $(SUBDIRS); do \
(cd $$subdir && $(MAKE) -f $(POLICY_MAKEFILE) $@) || exit 1; \
done
- rm -f ipa-server-selinux.spec
-
-maintainer-clean: clean
distclean: clean
+ rm -f ipa-server-selinux.spec
+
+maintainer-clean: distclean
install: all
install -d $(POLICY_DIR)
diff --git a/ipa-server/selinux/ipa-server-selinux.spec.in b/ipa-server/selinux/ipa-server-selinux.spec.in
index 9fe450a34..3387553ab 100644
--- a/ipa-server/selinux/ipa-server-selinux.spec.in
+++ b/ipa-server/selinux/ipa-server-selinux.spec.in
@@ -1,8 +1,8 @@
%define POLICYCOREUTILSVER 1.33.12-1
Name: ipa-server-selinux
-Version: VERSION
-Release: 1%{?dist}
+Version: __VERSION__
+Release: __RELEASE__%{?dist}
Summary: IPA server SELinux policies
Group: System Environment/Base
diff --git a/ipa-server/version.m4.in b/ipa-server/version.m4.in
new file mode 100644
index 000000000..5ddc8cea3
--- /dev/null
+++ b/ipa-server/version.m4.in
@@ -0,0 +1 @@
+define([IPA_VERSION], [__VERSION__])