From 7696c0afa22fd9d63047a9af2b634cb0e5897d23 Mon Sep 17 00:00:00 2001 From: Stephane Glondu Date: Fri, 20 Feb 2009 13:13:06 +0100 Subject: Use Debian changelog to determine COQ_VERSION --- debian/rules | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/debian/rules b/debian/rules index 04a75b29..8b587ea6 100755 --- a/debian/rules +++ b/debian/rules @@ -27,10 +27,8 @@ PACKAGES := $(shell awk '/Package:/{print $$2}' debian/control) OFILES := $(patsubst %.in,%,$(wildcard debian/*.in)) -# Beware: -1 is part of upstream version -COQVERSION := 8.2-1 - -COQ_ABI := $(COQVERSION)+$(OCAML_ABI) +COQ_VERSION := $(shell head -n1 debian/changelog | awk -F'[+() ]' '{print $$3}') +COQ_ABI := $(COQ_VERSION)+$(OCAML_ABI) CONFIGUREOPTS := --arch Linux --prefix /usr --mandir /usr/share/man \ --emacslib /usr/share/emacs/site-lisp/coq --reals all --fsets all \ -- cgit v1.2.3 From 72851683d176c05e44c56fea593c73e4691d3450 Mon Sep 17 00:00:00 2001 From: Stephane Glondu Date: Fri, 20 Feb 2009 13:17:59 +0100 Subject: Use ocamlinit.mk --- debian/rules | 21 ++------------------- 1 file changed, 2 insertions(+), 19 deletions(-) diff --git a/debian/rules b/debian/rules index 8b587ea6..6d55d2c5 100755 --- a/debian/rules +++ b/debian/rules @@ -16,7 +16,7 @@ export VERBOSE=1 # We want to use dpatch include /usr/share/dpatch/dpatch.make -include /usr/share/ocaml/ocamlvars.mk +include /usr/share/ocaml/ocamlinit.mk HTMLDOC := doc/stdlib/html/index.html @@ -25,8 +25,6 @@ ADDPREF := COQINSTALLPREFIX=$(COQPREF) PACKAGES := $(shell awk '/Package:/{print $$2}' debian/control) -OFILES := $(patsubst %.in,%,$(wildcard debian/*.in)) - COQ_VERSION := $(shell head -n1 debian/changelog | awk -F'[+() ]' '{print $$3}') COQ_ABI := $(COQ_VERSION)+$(OCAML_ABI) @@ -35,20 +33,6 @@ CONFIGUREOPTS := --arch Linux --prefix /usr --mandir /usr/share/man \ --browser "/usr/bin/x-www-browser %s &" \ --with-doc no --coqrunbyteflags "-dllib -lcoqrun" -OCAMLINITSED := -e 's%@OCamlDllDir@%$(OCAML_DLL_DIR)%g' -e '/^\#/d' - -ifneq ($(OCAML_OPT_ARCH),) - # CONFIGUREOPTS += -opt - OCAMLINITSED += -e 's/^OPT: //' -else - OCAMLINITSED += -e '/^OPT: /d' -endif - -ocamlinit: ocamlinit-stamp -ocamlinit-stamp: - for f in $(OFILES); do sed $(OCAMLINITSED) $$f.in > $$f; done - touch $@ - configure: configure-stamp configure-stamp: patch-stamp ocamlinit-stamp dh build --before dh_auto_configure @@ -90,9 +74,8 @@ install-stamp: build-stamp done touch $@ -clean: unpatch +clean: unpatch ocamlinit-clean dh $@ - rm -f $(OFILES) binary-indep: install-stamp dh $@ -- cgit v1.2.3 From 0a402bcc74943503556478c1e2dc924f27d2a3d3 Mon Sep 17 00:00:00 2001 From: Stephane Glondu Date: Fri, 20 Feb 2009 13:22:06 +0100 Subject: Generate coqvars.mk from debian/rules and drop /usr/lib/coq/abi --- debian/coqvars.mk | 12 ------------ debian/coqvars.mk.in | 12 ++++++++++++ debian/rules | 5 ++++- 3 files changed, 16 insertions(+), 13 deletions(-) delete mode 100644 debian/coqvars.mk create mode 100644 debian/coqvars.mk.in diff --git a/debian/coqvars.mk b/debian/coqvars.mk deleted file mode 100644 index 3cf8fe08..00000000 --- a/debian/coqvars.mk +++ /dev/null @@ -1,12 +0,0 @@ -# Current coq version -COQ_VERSION ?= $(shell /usr/bin/coqc --version | grep version | sed 's/^.*version \(.*\) ([^)]*)$/\1/') - -# Current coq ABI -COQ_ABI ?= $(shell cat /usr/lib/coq/abi) - -# Standard library path -COQ_STDLIB_DIR ?= $(shell /usr/bin/coqc -where) - -# Directory for contributions -# External libraries should go there -COQ_USERCONTRIB_DIR ?= $(COQ_STDLIB_DIR)/user-contrib diff --git a/debian/coqvars.mk.in b/debian/coqvars.mk.in new file mode 100644 index 00000000..efbbd248 --- /dev/null +++ b/debian/coqvars.mk.in @@ -0,0 +1,12 @@ +# Current coq version +COQ_VERSION ?= @CoqVersion@ + +# Current coq ABI +COQ_ABI ?= @CoqABI@ + +# Standard library path +COQ_STDLIB_DIR ?= $(shell /usr/bin/coqc -where) + +# Directory for contributions +# External libraries should go there +COQ_USERCONTRIB_DIR ?= $(COQ_STDLIB_DIR)/user-contrib diff --git a/debian/rules b/debian/rules index 6d55d2c5..2943187e 100755 --- a/debian/rules +++ b/debian/rules @@ -33,6 +33,10 @@ CONFIGUREOPTS := --arch Linux --prefix /usr --mandir /usr/share/man \ --browser "/usr/bin/x-www-browser %s &" \ --with-doc no --coqrunbyteflags "-dllib -lcoqrun" +OCAMLINIT_SED += \ + -e 's%@CoqVersion@%$(COQ_VERSION)%' \ + -e 's%@CoqABI@%$(COQ_ABI)%' + configure: configure-stamp configure-stamp: patch-stamp ocamlinit-stamp dh build --before dh_auto_configure @@ -65,7 +69,6 @@ install-stamp: build-stamp cp debian/coq.xpm debian/coqide/usr/share/pixmaps/coqide.xpm cp debian/coqide.desktop debian/coqide/usr/share/applications cp -r doc/stdlib/html debian/coq-theories/usr/share/doc/coq-theories/ - echo "$(COQ_ABI)" > debian/coq/usr/lib/coq/abi cp debian/coqvars.mk debian/coq/usr/share/coq/ dh install --after dh_install for u in $(PACKAGES); do \ -- cgit v1.2.3 From 500458bebd552145aa1a5eaa1a45fb3010680350 Mon Sep 17 00:00:00 2001 From: Stephane Glondu Date: Fri, 20 Feb 2009 14:42:47 +0100 Subject: Remove dependency on dpatch --- debian/control | 1 - debian/patches/00list | 0 debian/rules | 6 ++---- 3 files changed, 2 insertions(+), 5 deletions(-) delete mode 100644 debian/patches/00list diff --git a/debian/control b/debian/control index 1f0ec103..805d5879 100644 --- a/debian/control +++ b/debian/control @@ -13,7 +13,6 @@ Standards-Version: 3.8.0 Build-Depends: debhelper (>= 7), dpkg-dev (>= 1.13.19), - dpatch, dh-ocaml (>= 0.2), ocaml-nox, ocaml-best-compilers, diff --git a/debian/patches/00list b/debian/patches/00list deleted file mode 100644 index e69de29b..00000000 diff --git a/debian/rules b/debian/rules index 2943187e..014134a7 100755 --- a/debian/rules +++ b/debian/rules @@ -14,8 +14,6 @@ export CAML_LD_LIBRARY_PATH = $(shell pwd)/kernel/byterun # Show full commands when building Coq export VERBOSE=1 -# We want to use dpatch -include /usr/share/dpatch/dpatch.make include /usr/share/ocaml/ocamlinit.mk HTMLDOC := doc/stdlib/html/index.html @@ -38,7 +36,7 @@ OCAMLINIT_SED += \ -e 's%@CoqABI@%$(COQ_ABI)%' configure: configure-stamp -configure-stamp: patch-stamp ocamlinit-stamp +configure-stamp: ocamlinit-stamp dh build --before dh_auto_configure ./configure $(CONFIGUREOPTS) touch $@ @@ -77,7 +75,7 @@ install-stamp: build-stamp done touch $@ -clean: unpatch ocamlinit-clean +clean: ocamlinit-clean dh $@ binary-indep: install-stamp -- cgit v1.2.3 From 9603746faaccf85ee2e95570d2a0fb0a74a2aa1b Mon Sep 17 00:00:00 2001 From: Stephane Glondu Date: Fri, 20 Feb 2009 13:26:24 +0100 Subject: Update changelog --- debian/changelog | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/debian/changelog b/debian/changelog index 9bf26525..61566020 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,13 +1,12 @@ coq (8.2-1+dfsg-1) UNRELEASED; urgency=low - [ Stephane Glondu ] * New Upstream Version + * Use variables and ocamlinit rule from dh-ocaml in rules + * Added coqvars.mk helper for coq-related packages, and remove + /usr/lib/coq/abi (its contents is now it the COQ_ABI variable) + * Remove dependency on dpatch - [ Samuel Mimram ] - * Use variables from dh-ocaml in rules. - * Added coqvars.mk helper for coq-related packages. - - -- Samuel Mimram Thu, 19 Feb 2009 13:54:38 +0100 + -- Stephane Glondu Fri, 20 Feb 2009 15:21:15 +0100 coq (8.2~rc2+dfsg-3) experimental; urgency=low -- cgit v1.2.3