diff options
author | Emmanuel Bourg <ebourg@apache.org> | 2015-10-08 10:14:19 +0200 |
---|---|---|
committer | Emmanuel Bourg <ebourg@apache.org> | 2015-10-08 10:14:19 +0200 |
commit | bd338a6f705ec1f1b899ea22c297d453ad74b77a (patch) | |
tree | b7316442d14feaa3e0b16b4042b769a2073addd8 | |
parent | 2a3b4b914942dec7928b2be62384992afc02abb6 (diff) | |
download | java-common-bd338a6f705ec1f1b899ea22c297d453ad74b77a.tar.gz |
Factorized the default values for the openjdk architectures
-rwxr-xr-x | debian/rules | 56 |
1 files changed, 19 insertions, 37 deletions
diff --git a/debian/rules b/debian/rules index 36ff4bd..42f4ee3 100755 --- a/debian/rules +++ b/debian/rules @@ -3,65 +3,47 @@ # Uncomment this to turn on verbose mode. #export DH_VERBOSE=1 -, = , S = $(EMPTY) $(EMPTY) -mk_cslist = $(subst $(S),$(,)$(S),$(foreach v,$(1),$(v)-$(2))) jrel = $(shell dpkg-parsechangelog | grep -E ^Version: | sed "s/Version: 0.//") DEB_HOST_ARCH ?= $(shell dpkg-architecture --query DEB_HOST_ARCH) DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture --query DEB_HOST_MULTIARCH) -p_jre = gcj-jre -p_jhl = gcj-jre-headless -p_jdk = gcj-jdk -jdk_build_dep = -v_jre = -v_jdk = $(v_jre) -provides = java java2 java5 -dversion = 2:1.5-$(jrel) -jvmdir = java-gcj - -p_doc = openjdk-7-doc - include debian/java_defaults.mk +p_jre = openjdk-$(java_default_version)-jre +p_jhl = openjdk-$(java_default_version)-jre-headless +p_jdk = openjdk-$(java_default_version)-jdk +p_doc = openjdk-$(java_default_version)-doc +dversion = 2:1.$(java_default_version)-$(jrel) +jvmdir = java-1.$(java_default_version).0-openjdk$(if $(DEB_HOST_MULTIARCH),-$(DEB_HOST_ARCH)) + ifneq (,$(filter $(DEB_HOST_ARCH),$(java9_architectures))) - p_jre = openjdk-9-jre - p_jhl = openjdk-9-jre-headless - p_jdk = openjdk-9-jdk jdk_build_dep = openjdk-8-jdk v_jre = $(S)(>= 9~b74-1) v_jdk = $(v_jre) - provides = java java2 java5 java6 java7 java8 java9 - dversion = 2:1.9-$(jrel) - jvmdir = java-1.9.0-openjdk$(if $(DEB_HOST_MULTIARCH),-$(DEB_HOST_ARCH)) - p_doc = openjdk-9-doc else ifneq (,$(filter $(DEB_HOST_ARCH),$(java8_architectures))) - p_jre = openjdk-8-jre - p_jhl = openjdk-8-jre-headless - p_jdk = openjdk-8-jdk jdk_build_dep = openjdk-7-jdk v_jre = $(S)(>= 8~b132-1) v_jdk = $(v_jre) - provides = java java2 java5 java6 java7 java8 - dversion = 2:1.8-$(jrel) - jvmdir = java-1.8.0-openjdk$(if $(DEB_HOST_MULTIARCH),-$(DEB_HOST_ARCH)) - p_doc = openjdk-8-doc else ifneq (,$(filter $(DEB_HOST_ARCH),$(java7_architectures))) - p_jre = openjdk-7-jre - p_jhl = openjdk-7-jre-headless - p_jdk = openjdk-7-jdk jdk_build_dep = gcj-jdk v_jre = $(S)(>= 7~u3-2.1.1) v_jdk = $(v_jre) - provides = java java2 java5 java6 java7 - dversion = 2:1.7-$(jrel) - jvmdir = java-1.7.0-openjdk$(if $(DEB_HOST_MULTIARCH),-$(DEB_HOST_ARCH)) +else + p_jre = gcj-jre + p_jhl = gcj-jre-headless + p_jdk = gcj-jdk + jdk_build_dep = + v_jre = + v_jdk = $(v_jre) + jvmdir = java-gcj + p_doc = openjdk-7-doc endif -jre_provides = $(call mk_cslist,$(provides),runtime) -jhl_provides = $(call mk_cslist,$(provides),runtime-headless) -jdk_provides = $(call mk_cslist,$(provides),sdk) +jre_provides = java-runtime, java2-runtime, $(shell seq --format java%.f-runtime --separator ', ' 5 $(java_default_version)) +jhl_provides = java-runtime-headless, java2-runtime-headless, $(shell seq --format java%.f-runtime-headless --separator ', ' 5 $(java_default_version)) +jdk_provides = java-sdk, java2-sdk, $(shell seq --format java%.f-sdk --separator ', ' 5 $(java_default_version)) %: |