Patchwork [stable] debian: use a wildcard target for docker-debian-$codename

login
register
mail settings
Submitter Augie Fackler
Date April 22, 2017, 6:19 p.m.
Message ID <ad14d79e419fb860ee59.1492885172@imladris.local>
Download mbox | patch
Permalink /patch/20279/
State Rejected
Headers show

Comments

Augie Fackler - April 22, 2017, 6:19 p.m.
# HG changeset patch
# User Augie Fackler <augie@google.com>
# Date 1492879857 14400
#      Sat Apr 22 12:50:57 2017 -0400
# Branch stable
# Node ID ad14d79e419fb860ee59071d7c557810f913a4cc
# Parent  b5b6bd456279f011ec94f2a16a708d2833dd8119
debian: use a wildcard target for docker-debian-$codename

This makes it easier to build packages for stretch as well as jessie.
Anton Shestakov - April 23, 2017, 4:43 a.m.
On Sat, 22 Apr 2017 14:19:32 -0400
Augie Fackler <raf@durin42.com> wrote:

> # HG changeset patch
> # User Augie Fackler <augie@google.com>
> # Date 1492879857 14400
> #      Sat Apr 22 12:50:57 2017 -0400
> # Branch stable
> # Node ID ad14d79e419fb860ee59071d7c557810f913a4cc
> # Parent  b5b6bd456279f011ec94f2a16a708d2833dd8119
> debian: use a wildcard target for docker-debian-$codename
> 
> This makes it easier to build packages for stretch as well as jessie.
> 
> diff --git a/Makefile b/Makefile
> --- a/Makefile
> +++ b/Makefile
> @@ -193,9 +193,11 @@ deb:
>  ppa:
>  	contrib/builddeb --source-only
>  
> -docker-debian-jessie:
> -	mkdir -p packages/debian-jessie
> -	contrib/dockerdeb debian jessie
> +# Use the code name here, eg jessie for debian 8 and stretch for
> +# debian 9
> +docker-debian-%:
> +	mkdir -p packages/debian-$*
> +	contrib/dockerdeb debian $*

But contrib/dockerdeb uses initcontainer() from contrib/dockerlib.sh,
which needs a dockerfile in contrib/docker/ to work. For Jessie there
is debian-jessie file, but for stretch there is nothing.

I think we should adapt e63dfbbdbd07 for debian targets unless build
dependencies for Jessie and Stretch are different.
Sean Farley - April 24, 2017, 9:12 p.m.
Anton Shestakov <av6@dwimlabs.net> writes:

> On Sat, 22 Apr 2017 14:19:32 -0400
> Augie Fackler <raf@durin42.com> wrote:
>
>> # HG changeset patch
>> # User Augie Fackler <augie@google.com>
>> # Date 1492879857 14400
>> #      Sat Apr 22 12:50:57 2017 -0400
>> # Branch stable
>> # Node ID ad14d79e419fb860ee59071d7c557810f913a4cc
>> # Parent  b5b6bd456279f011ec94f2a16a708d2833dd8119
>> debian: use a wildcard target for docker-debian-$codename
>> 
>> This makes it easier to build packages for stretch as well as jessie.
>> 
>> diff --git a/Makefile b/Makefile
>> --- a/Makefile
>> +++ b/Makefile
>> @@ -193,9 +193,11 @@ deb:
>>  ppa:
>>  	contrib/builddeb --source-only
>>  
>> -docker-debian-jessie:
>> -	mkdir -p packages/debian-jessie
>> -	contrib/dockerdeb debian jessie
>> +# Use the code name here, eg jessie for debian 8 and stretch for
>> +# debian 9
>> +docker-debian-%:
>> +	mkdir -p packages/debian-$*
>> +	contrib/dockerdeb debian $*
>
> But contrib/dockerdeb uses initcontainer() from contrib/dockerlib.sh,
> which needs a dockerfile in contrib/docker/ to work. For Jessie there
> is debian-jessie file, but for stretch there is nothing.
>
> I think we should adapt e63dfbbdbd07 for debian targets unless build
> dependencies for Jessie and Stretch are different.

Hmm, that's my commit ... oh, do you mean make a debian.template file as
I did for ubuntu? If so, then sure, that makes sense.

Might be nice before the release? I have no horse in this race, though.
Augie Fackler - April 24, 2017, 9:13 p.m.
> On Apr 24, 2017, at 17:12, Sean Farley <sean@farley.io> wrote:
> 
> Anton Shestakov <av6@dwimlabs.net> writes:
> 
>> On Sat, 22 Apr 2017 14:19:32 -0400
>> Augie Fackler <raf@durin42.com> wrote:
>> 
>>> # HG changeset patch
>>> # User Augie Fackler <augie@google.com>
>>> # Date 1492879857 14400
>>> #      Sat Apr 22 12:50:57 2017 -0400
>>> # Branch stable
>>> # Node ID ad14d79e419fb860ee59071d7c557810f913a4cc
>>> # Parent  b5b6bd456279f011ec94f2a16a708d2833dd8119
>>> debian: use a wildcard target for docker-debian-$codename
>>> 
>>> This makes it easier to build packages for stretch as well as jessie.
>>> 
>>> diff --git a/Makefile b/Makefile
>>> --- a/Makefile
>>> +++ b/Makefile
>>> @@ -193,9 +193,11 @@ deb:
>>> ppa:
>>> 	contrib/builddeb --source-only
>>> 
>>> -docker-debian-jessie:
>>> -	mkdir -p packages/debian-jessie
>>> -	contrib/dockerdeb debian jessie
>>> +# Use the code name here, eg jessie for debian 8 and stretch for
>>> +# debian 9
>>> +docker-debian-%:
>>> +	mkdir -p packages/debian-$*
>>> +	contrib/dockerdeb debian $*
>> 
>> But contrib/dockerdeb uses initcontainer() from contrib/dockerlib.sh,
>> which needs a dockerfile in contrib/docker/ to work. For Jessie there
>> is debian-jessie file, but for stretch there is nothing.
>> 
>> I think we should adapt e63dfbbdbd07 for debian targets unless build
>> dependencies for Jessie and Stretch are different.
> 
> Hmm, that's my commit ... oh, do you mean make a debian.template file as
> I did for ubuntu? If so, then sure, that makes sense.
> 
> Might be nice before the release? I have no horse in this race, though.

Yeah, I'm not worried about this for the release either. It just occurred to me as a thing we might want to do, and I did it since I was knee-deep in that makefile anyway to check the change where I added sensible-{editor, pager} defaults.

Patch

diff --git a/Makefile b/Makefile
--- a/Makefile
+++ b/Makefile
@@ -193,9 +193,11 @@  deb:
 ppa:
 	contrib/builddeb --source-only
 
-docker-debian-jessie:
-	mkdir -p packages/debian-jessie
-	contrib/dockerdeb debian jessie
+# Use the code name here, eg jessie for debian 8 and stretch for
+# debian 9
+docker-debian-%:
+	mkdir -p packages/debian-$*
+	contrib/dockerdeb debian $*
 
 contrib/docker/ubuntu-%: contrib/docker/ubuntu.template
 	sed "s/__CODENAME__/$*/" $< > $@
@@ -273,7 +275,7 @@  docker-centos7:
 .PHONY: help all local build doc cleanbutpackages clean install install-bin \
 	install-doc install-home install-home-bin install-home-doc \
 	dist dist-notests check tests check-code update-pot \
-	osx deb ppa docker-debian-jessie \
+	osx deb ppa docker-debian-% \
 	docker-ubuntu-trusty docker-ubuntu-trusty-ppa \
 	docker-ubuntu-xenial docker-ubuntu-xenial-ppa \
 	docker-ubuntu-yakkety docker-ubuntu-yakkety-ppa \