Patchwork [5,of,6,packaging] packaging: extract packagelib for common code from builddeb and buildrpm

login
register
mail settings
Submitter Pierre-Yves David
Date May 8, 2015, 9:29 p.m.
Message ID <554D2AC4.6060508@ens-lyon.org>
Download mbox | patch
Permalink /patch/8985/
State Accepted
Commit 56c64c91b42937759dfced7ca551b1d6a34a522c
Delegated to: Augie Fackler
Headers show

Comments

Pierre-Yves David - May 8, 2015, 9:29 p.m.
On 05/08/2015 10:10 AM, Augie Fackler wrote:
> # HG changeset patch
> # User Augie Fackler <augie@google.com>
> # Date 1431008938 14400
> #      Thu May 07 10:28:58 2015 -0400
> # Node ID eb1672b7b846324d4275b49c09d33373e3cb1920
> # Parent  25e90eb8e6dd9a142d52128d13584d2d99147d7f
> packaging: extract packagelib for common code from builddeb and buildrpm

I would have been happy to get the extraction before the debian related 
patch. I got two breackage of my nightly build setup with that one.
1) dash was unhappy about your bash script
2) the machine have no gcc installed and were unable to retrieve version 
number

I applied the patch below to fix theses issue.

      hgversion=`$HG version | sed -ne 's/.*(version \(.*\))$/\1/p'`
Augie Fackler - May 9, 2015, 10:16 p.m.
On May 8, 2015, at 5:29 PM, Pierre-Yves David <pierre-yves.david@ens-lyon.org> wrote:

> 2) the machine have no gcc installed and were unable to retrieve version number

which machine? the base machine, or the docker image? If it’s the latter, we should fix that.
Pierre-Yves David - May 10, 2015, 1:41 a.m.
On 05/09/2015 03:16 PM, Augie Fackler wrote:
>
> On May 8, 2015, at 5:29 PM, Pierre-Yves David <pierre-yves.david@ens-lyon.org> wrote:
>
>> 2) the machine have no gcc installed and were unable to retrieve version number
>
> which machine? the base machine, or the docker image? If it’s the latter, we should fix that.

The base machine.
Augie Fackler - May 10, 2015, 2:56 a.m.
On May 9, 2015, at 9:41 PM, Pierre-Yves David <pierre-yves.david@ens-lyon.org> wrote:

> 
> 
> On 05/09/2015 03:16 PM, Augie Fackler wrote:
>> 
>> On May 8, 2015, at 5:29 PM, Pierre-Yves David <pierre-yves.david@ens-lyon.org> wrote:
>> 
>>> 2) the machine have no gcc installed and were unable to retrieve version number
>> 
>> which machine? the base machine, or the docker image? If it’s the latter, we should fix that.
> 
> The base machine.

That gives me the thought that we should probably take care in the packaging scripts to ensure we never accidentally build packages with --pure.

> 
> -- 
> Pierre-Yves David

Patch

diff --git a/contrib/packagelib.sh b/contrib/packagelib.sh
--- a/contrib/packagelib.sh
+++ b/contrib/packagelib.sh
@@ -1,8 +1,8 @@ 
-function gethgversion() {
+gethgversion() {
      make clean
-    make local
+    make local || make local PURE=--pure
      HG="$PWD/hg"

      $HG version > /dev/null || { echo 'abort: hg version failed!'; 
exit 1 ; }