[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Bug#733033: ocl-icd-libopencl1: arch-dependent file in "Multi-Arch: same" package



On 24/12/2013 12:59, Julien Cristau wrote:
> On Tue, Dec 24, 2013 at 12:23:08 +0100, Vincent Danjean wrote:
> 
>>   Hi,
>>
>>   Does anybody know how to force the date on manapages generated by
>> asciidoc? A quick look for 'date' in asciidoc manpage and a google
>> search on "asciidoc multiarch date" do not give me anything useful
>> at first glance.
>>
> Run it under faketime?

Thanks. I did not know it. For the record, here is what I did to
get the date of the last changelog entry for the generated manpage.

  Joyeux Noël
    Vincent
diff -Nru ocl-icd-2.1.3/debian/asciidoc ocl-icd-2.1.3/debian/asciidoc
--- ocl-icd-2.1.3/debian/asciidoc	1970-01-01 01:00:00.000000000 +0100
+++ ocl-icd-2.1.3/debian/asciidoc	2013-12-24 14:48:16.000000000 +0100
@@ -0,0 +1,6 @@
+#!/bin/sh
+CHANGELOG="$(dirname "$0")/changelog"
+DATE_CHANGELOG="$(dpkg-parsechangelog -l"$CHANGELOG" --show-field Date)"
+DATE="$(date --utc -d "$DATE_CHANGELOG" --rfc-3339 second )"
+set -x
+exec faketime -f "$DATE" asciidoc "$@"
diff -Nru ocl-icd-2.1.3/debian/rules ocl-icd-2.1.3/debian/rules
--- ocl-icd-2.1.3/debian/rules	2013-12-22 14:28:10.000000000 +0100
+++ ocl-icd-2.1.3/debian/rules	2013-12-24 14:48:16.000000000 +0100
@@ -15,7 +15,8 @@
 .PHONY: override_dh_auto_configure
 override_dh_auto_configure:
 	./bootstrap
-	dh_auto_configure -- --disable-debug --disable-update-database
+	env ASCIIDOC="$(CURDIR)/debian/asciidoc" \
+		dh_auto_configure -- --disable-debug --disable-update-database
 
 .PHONY: override_dh_shlibdeps
 override_dh_shlibdeps:

Attachment: signature.asc
Description: OpenPGP digital signature


Reply to: