Bug#819397: src:ncurses: Add udeb support to libtinfo5

2016-04-23 Thread Roger Shimizu
On Fri, Apr 22, 2016 at 3:28 AM, Sven Joachim  wrote:
> On 2016-04-13 18:12 +0200, Sven Joachim wrote:
>
>> On 2016-04-13 23:19 +0900, Roger Shimizu wrote:
>>
>>> I find another way, may be considered tricky though.
>>> I find screen actually uses libtinfo.so, but not uses libtic.so, which
>>> includes in libtinfo5-udeb.
>>> After I applied the patch below to removed libtic.so from
>>> libtinfo5-udeb, the dependency becomes normal as ARCH armel:
>>>
>>> $ dpkg-deb -I libtinfo5-udeb_6.0+20160319-2_amd64.udeb
>>> Depends: libc6-udeb (>= 2.19)
>>>
>>> diff --git a/debian/libtinfo5-udeb.install b/debian/libtinfo5-udeb.install
>>> index c6aa24a..576962e 100644
>>> --- a/debian/libtinfo5-udeb.install
>>> +++ b/debian/libtinfo5-udeb.install
>>> @@ -1,2 +1 @@
>>>  usr/lib/*/libtinfo.so.*
>>> -usr/lib/*/libtic.so.*
>
> Okay, I have done just that now.
>
>> I don't like that, since the information in the libtinfo5 shlibs file
>> information then becomes incorrect.  The shlibs file says that udebs
>> with binaries linking to libtic should depend on libtinfo5-udeb, but
>> libtinfo5-udeb would not actually contain the library.
>
> To fix this, I have chosen to adjust the shlibs file with a sed command
> in debian/rules after dh_installdeb.  Perhaps not too pretty, but it's
> short and does the job.
>
> Building screen from the screen-udeb branch seems to work correctly,
> please double-check that.

Dear Sven,

Really appreciate your favour helping on this!

Those shlibs stuff are beyond my knowledge. I spent some time on a few
manpages, but still didn't get a clear picture.

I have tried latest master in alioth, it builds fine on armel arch,
screen-udeb and debian-installer also builds fine along with.
Then I tested the d-i image on my armel/orion5x based Linkstation, the
screen inside d-i works fine, too.

So I guess you can safely make a release, after that I can ask Axel to
proceed the screen package.
Thank you!

Cheers,
-- 
Roger Shimizu, GMT +9 Tokyo
PGP/GPG: 17B3ACB1



Bug#819397: src:ncurses: Add udeb support to libtinfo5

2016-04-21 Thread Sven Joachim
On 2016-04-13 18:12 +0200, Sven Joachim wrote:

> On 2016-04-13 23:19 +0900, Roger Shimizu wrote:
>
>> I find another way, may be considered tricky though.
>> I find screen actually uses libtinfo.so, but not uses libtic.so, which
>> includes in libtinfo5-udeb.
>> After I applied the patch below to removed libtic.so from
>> libtinfo5-udeb, the dependency becomes normal as ARCH armel:
>>
>> $ dpkg-deb -I libtinfo5-udeb_6.0+20160319-2_amd64.udeb
>> Depends: libc6-udeb (>= 2.19)
>>
>> diff --git a/debian/libtinfo5-udeb.install b/debian/libtinfo5-udeb.install
>> index c6aa24a..576962e 100644
>> --- a/debian/libtinfo5-udeb.install
>> +++ b/debian/libtinfo5-udeb.install
>> @@ -1,2 +1 @@
>>  usr/lib/*/libtinfo.so.*
>> -usr/lib/*/libtic.so.*

Okay, I have done just that now.

> I don't like that, since the information in the libtinfo5 shlibs file
> information then becomes incorrect.  The shlibs file says that udebs
> with binaries linking to libtic should depend on libtinfo5-udeb, but
> libtinfo5-udeb would not actually contain the library.

To fix this, I have chosen to adjust the shlibs file with a sed command
in debian/rules after dh_installdeb.  Perhaps not too pretty, but it's
short and does the job.

Building screen from the screen-udeb branch seems to work correctly,
please double-check that.

Cheers,
   Sven



Bug#819397: src:ncurses: Add udeb support to libtinfo5

2016-04-21 Thread Sven Joachim
On 2016-04-02 21:17 +0900, Roger Shimizu wrote:

> Control: retitle -1 Add udeb support to libtinfo5
>
> On Sat, Apr 2, 2016 at 6:42 PM, Sven Joachim  wrote:
>>
>> I had come to the same conclusion.  For better or worse, packages are
>> not only built in minimal chroots, so screen had better be fixed not to
>> gain the extraneous dependencies if libncurses5-dev or libutempter-dev
>> are installed on the build system.  I have filed bugs #819781 and
>> #819789 for that purpose, you're welcome to tackle them.
>
> Thanks for the two reports above!
> Things will be easier if these two gets resolved.
>
> And here's patch v4.
>
> Changes v2:
>  - add udeb supoort to libncurses5
> Changes v3:
>  - add "Priority: extra" to udeb in debian/control
>  - fix typo when calling dh_makeshlibs
> Changes v4:
>  - remove udeb support for libncurses5, since it's not required by screen-udeb

I have merged this version of the patch (with one tiny amendment), thanks.

> diff --git a/debian/changelog b/debian/changelog
> index a02785a..6810fa1 100644
> --- a/debian/changelog
> +++ b/debian/changelog
> @@ -1,3 +1,10 @@
> +ncurses (6.0+20160319-2) UNRELEASED; urgency=medium
> +
> +  [ Roger Shimizu ]
> +  * Add udeb support to libtinfo5

Added a " (Closes: #819397)." here.

Cheers,
   Sven



Bug#819397: src:ncurses: Add udeb support to libtinfo5

2016-04-20 Thread Sven Joachim
On 2016-04-20 03:26 +0900, Roger Shimizu wrote:

> Dear Sven,
>
> On Fri, Apr 15, 2016 at 3:00 AM, Sven Joachim  wrote:
>> It doesn't help.  I have filed a bug against dpkg-shlibdeps (#821025),
>> you should have received a copy of that report.
>
> Thanks for the report on #821025.
>
> I read comment from Guillem, but have no idea on the words below:
>
>> But in your case I think simply using -x with the name of the two
>> multilib paclages should be enough, as the undesirable dependency is
>> simply a self-depends masked as a multilib one. And this can be done
>> right now.
>
> This seems to be quick fix, but do you know how to do it exactly?

Probably something like this in debian/rules (untested):

,
|   dh_shlibdeps -s -N$(package-ti)-udeb
|   dh_shlibdeps -p$(package-ti)-udeb -- -x$(package-ti-64) 
-x$(package-ti-32)
`

But I have a different fix in mind, will send an update tomorrow.

Cheers,
   Sven



Bug#819397: src:ncurses: Add udeb support to libtinfo5

2016-04-19 Thread Roger Shimizu
Dear Sven,

On Fri, Apr 15, 2016 at 3:00 AM, Sven Joachim  wrote:
> It doesn't help.  I have filed a bug against dpkg-shlibdeps (#821025),
> you should have received a copy of that report.

Thanks for the report on #821025.

I read comment from Guillem, but have no idea on the words below:

> But in your case I think simply using -x with the name of the two
> multilib paclages should be enough, as the undesirable dependency is
> simply a self-depends masked as a multilib one. And this can be done
> right now.

This seems to be quick fix, but do you know how to do it exactly?

Cheers,
-- 
Roger Shimizu, GMT +9 Tokyo
PGP/GPG: 17B3ACB1



Bug#819397: src:ncurses: Add udeb support to libtinfo5

2016-04-14 Thread Sven Joachim
On 2016-04-14 20:37 +0900, Roger Shimizu wrote:

> On Thu, Apr 14, 2016 at 4:24 AM, Sven Joachim  wrote:
>> On 2016-04-14 02:42 +0900, Roger Shimizu wrote:
>>> I tried to remove install add install.in:
>>>
>>> diff --git a/debian/libtinfo5-udeb.install.in 
>>> b/debian/libtinfo5-udeb.install.in
>>> new file mode 100644
>>> index 000..b0b4373
>>> --- /dev/null
>>> +++ b/debian/libtinfo5-udeb.install.in
>>> @@ -0,0 +1,2 @@
>>> +usr/lib/${DEB_HOST_MULTIARCH}/libtinfo.so.*  lib/${DEB_HOST_MULTIARCH}
>>> +usr/lib/${DEB_HOST_MULTIARCH}/libtic.so.*
>>
>> Apparently you have to install the libraries directly into lib/ and
>> avoid the multiarch directories in the udeb.
>>
>>> and register the install:
>>>
>>> --- a/debian/rules
>>> +++ b/debian/rules
>>> @@ -69,8 +69,8 @@ DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture
>>> -qDEB_HOST_MULTIARCH)
>>>  autogen-files := debian/libncurses5-dev.links debian/libtinfo-dev.links \
>>>   debian/libncurses5.install debian/libncursesw5.install \
>>>   debian/libncurses5-dev.install debian/libncursesw5-dev.install \
>>> - debian/libtinfo5.install debian/libtinfo-dev.install \
>>> - debian/libtermcap.so
>>> + debian/libtinfo5.install debian/libtinfo5-udeb.install \
>>> + debian/libtinfo-dev.install debian/libtermcap.so
>>>
>>> But the result of built package keeps the same.
>>> It still depends on lib32tinfo5, which is not udeb.
>>>
>>> I also confirmed that there's no "/usr/lib/32" library in the udeb.
>>> Library so files looks alright in udeb.
>>
>> Huh, indeed.  Looks like something is rather odd with dpkg-shlibdeps,
>> however this can be avoided by putting the libraries into lib/ (see
>> above).

Another embarrassment for me, on closer look this does not actually
work. :-/

> Since you're confident on moving udeb lib so to lib/ to solve the
> problem, here enclosed you can find the v5 patch.
> However, I still have the issue on my amd64 environment:
>
> Depends: lib32tinfo5 (>= 6), libc6-udeb (>= 2.19)
>
> Maybe I my environment is not clean, so you can try the patch yourself.

It doesn't help.  I have filed a bug against dpkg-shlibdeps (#821025),
you should have received a copy of that report.

> diff --git a/debian/.gitignore b/debian/.gitignore
> index cf040fd..367708f 100644
> --- a/debian/.gitignore
> +++ b/debian/.gitignore
> @@ -7,6 +7,7 @@ libncursesw5-dev.install
>  libtinfo-dev.install
>  libtinfo-dev.links
>  libtinfo5.install
> +libtinfo5-udeb.install
>  libtermcap.so
>  *.substvars
>  *.debhelper

As I wrote in my previous mail a few minutes ago, there's actually no
need for libtinfo5-udeb.install.in, so this change and the one to
autogen-files in debian/rules can be backed out.

> diff --git a/debian/changelog b/debian/changelog
> index a02785a..6810fa1 100644
> --- a/debian/changelog
> +++ b/debian/changelog
> @@ -1,3 +1,10 @@
> +ncurses (6.0+20160319-2) UNRELEASED; urgency=medium
> +
> +  [ Roger Shimizu ]
> +  * Add udeb support to libtinfo5

Please add a " (Closes: #819397)" at the end of this line.

Cheers,
   Sven



Bug#819397: src:ncurses: Add udeb support to libtinfo5

2016-04-14 Thread Sven Joachim
On 2016-04-13 18:12 +0200, Sven Joachim wrote:

> On 2016-04-13 23:19 +0900, Roger Shimizu wrote:
>>
>> I was always on armel boxes do the screen support for d-i, so I didn't
>> find there's a problem on amd64 until yesterday.
>> With the previous v4 patch, building packages for src:ncurses on ARCH
>> amd64, then check the dependency of built udeb:
>>
>> $ dpkg-deb -I libtinfo5-udeb_6.0+20160319-2_amd64.udeb
>> Depends: lib32tinfo5 (>= 6), libc6-udeb (>= 2.19)
>
> I see why: the debian/libtinfo5-udeb.install file installs files named
> usr/lib/*/libtic.so.*, and unfortunately the multilib libraries match
> that wildcard, so you end up with /usr/lib/32/libtic.so.5 in the udeb
> which is not what we want.

Seems I had displaced my brain yesterday, since this is nonsense.  The
multilib libraries are placed in /usr/lib32 rather than /usr/lib/32 and
do not end up in the udeb.

> Yes, the right solution is not to install these files into the udeb in
> the first place.  This could be achieved by creating
> libtinfo5-udeb.install from libtinfo5-udeb.install.in, as in the first
> version of your patch.

Consequently, this is not necessary and we don't need a
libtinfo5-udeb.install.in file.

Cheers,
   Sven



Bug#819397: src:ncurses: Add udeb support to libtinfo5

2016-04-14 Thread Roger Shimizu
On Thu, Apr 14, 2016 at 4:24 AM, Sven Joachim  wrote:
> On 2016-04-14 02:42 +0900, Roger Shimizu wrote:
>> I tried to remove install add install.in:
>>
>> diff --git a/debian/libtinfo5-udeb.install.in 
>> b/debian/libtinfo5-udeb.install.in
>> new file mode 100644
>> index 000..b0b4373
>> --- /dev/null
>> +++ b/debian/libtinfo5-udeb.install.in
>> @@ -0,0 +1,2 @@
>> +usr/lib/${DEB_HOST_MULTIARCH}/libtinfo.so.*  lib/${DEB_HOST_MULTIARCH}
>> +usr/lib/${DEB_HOST_MULTIARCH}/libtic.so.*
>
> Apparently you have to install the libraries directly into lib/ and
> avoid the multiarch directories in the udeb.
>
>> and register the install:
>>
>> --- a/debian/rules
>> +++ b/debian/rules
>> @@ -69,8 +69,8 @@ DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture
>> -qDEB_HOST_MULTIARCH)
>>  autogen-files := debian/libncurses5-dev.links debian/libtinfo-dev.links \
>>   debian/libncurses5.install debian/libncursesw5.install \
>>   debian/libncurses5-dev.install debian/libncursesw5-dev.install \
>> - debian/libtinfo5.install debian/libtinfo-dev.install \
>> - debian/libtermcap.so
>> + debian/libtinfo5.install debian/libtinfo5-udeb.install \
>> + debian/libtinfo-dev.install debian/libtermcap.so
>>
>> But the result of built package keeps the same.
>> It still depends on lib32tinfo5, which is not udeb.
>>
>> I also confirmed that there's no "/usr/lib/32" library in the udeb.
>> Library so files looks alright in udeb.
>
> Huh, indeed.  Looks like something is rather odd with dpkg-shlibdeps,
> however this can be avoided by putting the libraries into lib/ (see
> above).

Since you're confident on moving udeb lib so to lib/ to solve the
problem, here enclosed you can find the v5 patch.
However, I still have the issue on my amd64 environment:

Depends: lib32tinfo5 (>= 6), libc6-udeb (>= 2.19)

Maybe I my environment is not clean, so you can try the patch yourself.

 diff --git a/debian/libtinfo5-udeb.install b/debian/libtinfo5-udeb.install
 index c6aa24a..576962e 100644
 --- a/debian/libtinfo5-udeb.install
 +++ b/debian/libtinfo5-udeb.install
 @@ -1,2 +1 @@
  usr/lib/*/libtinfo.so.*
 -usr/lib/*/libtic.so.*
>>>
>>> I don't like that, since the information in the libtinfo5 shlibs file
>>> information then becomes incorrect.  The shlibs file says that udebs
>>> with binaries linking to libtic should depend on libtinfo5-udeb, but
>>> libtinfo5-udeb would not actually contain the library.
>>
>> Understand your points.
>> But I can argue that udeb is the deb package only contain the stuff
>> necessary for d-i.
>> Stuff d-i don't need can be removed.
>
> It is correct that d-i does not currently need libtic, but if some udeb
> package ever does it will end up installable but broken, a situation I
> would rather not let happen.

Understand.
So we have to resolve this before upload.

Cheers,
-- 
Roger Shimizu, GMT +9 Tokyo
PGP/GPG: 17B3ACB1
From c4f0dfcdea050a5c9bb7df273aa41fc0b9f2ca38 Mon Sep 17 00:00:00 2001
From: Roger Shimizu 
Date: Sun, 27 Mar 2016 23:15:51 +0900
Subject: [PATCH] Add udeb support to libtinfo5

---
 debian/.gitignore|  1 +
 debian/changelog |  7 +++
 debian/control   | 13 +
 debian/libtinfo5-udeb.install.in |  2 ++
 debian/rules |  6 +++---
 5 files changed, 26 insertions(+), 3 deletions(-)
 create mode 100644 debian/libtinfo5-udeb.install.in

diff --git a/debian/.gitignore b/debian/.gitignore
index cf040fd..367708f 100644
--- a/debian/.gitignore
+++ b/debian/.gitignore
@@ -7,6 +7,7 @@ libncursesw5-dev.install
 libtinfo-dev.install
 libtinfo-dev.links
 libtinfo5.install
+libtinfo5-udeb.install
 libtermcap.so
 *.substvars
 *.debhelper
diff --git a/debian/changelog b/debian/changelog
index a02785a..6810fa1 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,10 @@
+ncurses (6.0+20160319-2) UNRELEASED; urgency=medium
+
+  [ Roger Shimizu ]
+  * Add udeb support to libtinfo5
+
+ -- Roger Shimizu   Sat, 26 Mar 2016 18:22:36 +0900
+
 ncurses (6.0+20160319-1) unstable; urgency=medium
 
   * New upstream patchlevel.
diff --git a/debian/control b/debian/control
index a740fa2..253e66e 100644
--- a/debian/control
+++ b/debian/control
@@ -27,6 +27,19 @@ Description: shared low-level terminfo library for terminal handling
  .
  This package contains the shared low-level terminfo library.
 
+Package: libtinfo5-udeb
+Package-Type: udeb
+Section: debian-installer
+Architecture: any
+Priority: extra
+Depends: ${shlibs:Depends}, ${misc:Depends}
+Description: shared low-level terminfo library for terminal handling - udeb
+ The ncurses library routines are a terminal-independent method of
+ updating character screens with reasonable optimization.
+ .
+ This package contains the stripped-down udeb version of shared low-level
+ terminfo library.
+
 Package: libncurses5
 Architecture: any
 Pre-Depends: 

Bug#819397: src:ncurses: Add udeb support to libtinfo5

2016-04-13 Thread Sven Joachim
On 2016-04-14 02:42 +0900, Roger Shimizu wrote:

> On Thu, Apr 14, 2016 at 1:12 AM, Sven Joachim  wrote:
>
>> On 2016-04-13 23:19 +0900, Roger Shimizu wrote:
>>
>>> Dear Sven,
>>>
>>> On Sat, Apr 2, 2016 at 9:17 PM, Roger Shimizu  
>>> wrote:

 And here's patch v4.

 Changes v2:
  - add udeb supoort to libncurses5
 Changes v3:
  - add "Priority: extra" to udeb in debian/control
  - fix typo when calling dh_makeshlibs
 Changes v4:
  - remove udeb support for libncurses5, since it's not required by 
 screen-udeb
>>>
>>> I was always on armel boxes do the screen support for d-i, so I didn't
>>> find there's a problem on amd64 until yesterday.
>>> With the previous v4 patch, building packages for src:ncurses on ARCH
>>> amd64, then check the dependency of built udeb:
>>>
>>> $ dpkg-deb -I libtinfo5-udeb_6.0+20160319-2_amd64.udeb
>>> Depends: lib32tinfo5 (>= 6), libc6-udeb (>= 2.19)
>>
>> I see why: the debian/libtinfo5-udeb.install file installs files named
>> usr/lib/*/libtic.so.*, and unfortunately the multilib libraries match
>> that wildcard, so you end up with /usr/lib/32/libtic.so.5 in the udeb
>> which is not what we want.
>>
>>> It seems "lib32tinfo5" only exists on amd64 and ppc64.
>>> Then I tried to add "lib32tinfo5-udeb" support in debian/control and
>>> debian/rules, but built "lib32tinfo5-udeb" depend on libc6-i386, which
>>> is not udeb. So I decide not to choose this solution.
>>
>> Yes, the right solution is not to install these files into the udeb in
>> the first place.  This could be achieved by creating
>> libtinfo5-udeb.install from libtinfo5-udeb.install.in, as in the first
>> version of your patch.
>
> Thanks for your comment!
>
> I tried to remove install add install.in:
>
> diff --git a/debian/libtinfo5-udeb.install.in 
> b/debian/libtinfo5-udeb.install.in
> new file mode 100644
> index 000..b0b4373
> --- /dev/null
> +++ b/debian/libtinfo5-udeb.install.in
> @@ -0,0 +1,2 @@
> +usr/lib/${DEB_HOST_MULTIARCH}/libtinfo.so.*  lib/${DEB_HOST_MULTIARCH}
> +usr/lib/${DEB_HOST_MULTIARCH}/libtic.so.*

Apparently you have to install the libraries directly into lib/ and
avoid the multiarch directories in the udeb.

> and register the install:
>
> --- a/debian/rules
> +++ b/debian/rules
> @@ -69,8 +69,8 @@ DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture
> -qDEB_HOST_MULTIARCH)
>  autogen-files := debian/libncurses5-dev.links debian/libtinfo-dev.links \
>   debian/libncurses5.install debian/libncursesw5.install \
>   debian/libncurses5-dev.install debian/libncursesw5-dev.install \
> - debian/libtinfo5.install debian/libtinfo-dev.install \
> - debian/libtermcap.so
> + debian/libtinfo5.install debian/libtinfo5-udeb.install \
> + debian/libtinfo-dev.install debian/libtermcap.so
>
> But the result of built package keeps the same.
> It still depends on lib32tinfo5, which is not udeb.
>
> I also confirmed that there's no "/usr/lib/32" library in the udeb.
> Library so files looks alright in udeb.

Huh, indeed.  Looks like something is rather odd with dpkg-shlibdeps,
however this can be avoided by putting the libraries into lib/ (see
above).

>>> I find screen actually uses libtinfo.so, but not uses libtic.so, which
>>> includes in libtinfo5-udeb.
>>> After I applied the patch below to removed libtic.so from
>>> libtinfo5-udeb, the dependency becomes normal as ARCH armel:
>>>
>>> $ dpkg-deb -I libtinfo5-udeb_6.0+20160319-2_amd64.udeb
>>> Depends: libc6-udeb (>= 2.19)
>>>
>>> diff --git a/debian/libtinfo5-udeb.install b/debian/libtinfo5-udeb.install
>>> index c6aa24a..576962e 100644
>>> --- a/debian/libtinfo5-udeb.install
>>> +++ b/debian/libtinfo5-udeb.install
>>> @@ -1,2 +1 @@
>>>  usr/lib/*/libtinfo.so.*
>>> -usr/lib/*/libtic.so.*
>>
>> I don't like that, since the information in the libtinfo5 shlibs file
>> information then becomes incorrect.  The shlibs file says that udebs
>> with binaries linking to libtic should depend on libtinfo5-udeb, but
>> libtinfo5-udeb would not actually contain the library.
>
> Understand your points.
> But I can argue that udeb is the deb package only contain the stuff
> necessary for d-i.
> Stuff d-i don't need can be removed.

It is correct that d-i does not currently need libtic, but if some udeb
package ever does it will end up installable but broken, a situation I
would rather not let happen.

Cheers,
   Sven



Bug#819397: src:ncurses: Add udeb support to libtinfo5

2016-04-13 Thread Roger Shimizu
On Thu, Apr 14, 2016 at 1:12 AM, Sven Joachim  wrote:
> Hi Roger,
>
> sorry for not having replied last week, I was busy with other things.

Dear Sven,

Sorry about previous push.
Obviously there's still issue I didn't notice, and didn't resolve yet.

> On 2016-04-13 23:19 +0900, Roger Shimizu wrote:
>
>> Dear Sven,
>>
>> On Sat, Apr 2, 2016 at 9:17 PM, Roger Shimizu  wrote:
>>>
>>> And here's patch v4.
>>>
>>> Changes v2:
>>>  - add udeb supoort to libncurses5
>>> Changes v3:
>>>  - add "Priority: extra" to udeb in debian/control
>>>  - fix typo when calling dh_makeshlibs
>>> Changes v4:
>>>  - remove udeb support for libncurses5, since it's not required by 
>>> screen-udeb
>>
>> I was always on armel boxes do the screen support for d-i, so I didn't
>> find there's a problem on amd64 until yesterday.
>> With the previous v4 patch, building packages for src:ncurses on ARCH
>> amd64, then check the dependency of built udeb:
>>
>> $ dpkg-deb -I libtinfo5-udeb_6.0+20160319-2_amd64.udeb
>> Depends: lib32tinfo5 (>= 6), libc6-udeb (>= 2.19)
>
> I see why: the debian/libtinfo5-udeb.install file installs files named
> usr/lib/*/libtic.so.*, and unfortunately the multilib libraries match
> that wildcard, so you end up with /usr/lib/32/libtic.so.5 in the udeb
> which is not what we want.
>
>> It seems "lib32tinfo5" only exists on amd64 and ppc64.
>> Then I tried to add "lib32tinfo5-udeb" support in debian/control and
>> debian/rules, but built "lib32tinfo5-udeb" depend on libc6-i386, which
>> is not udeb. So I decide not to choose this solution.
>
> Yes, the right solution is not to install these files into the udeb in
> the first place.  This could be achieved by creating
> libtinfo5-udeb.install from libtinfo5-udeb.install.in, as in the first
> version of your patch.

Thanks for your comment!

I tried to remove install add install.in:

diff --git a/debian/libtinfo5-udeb.install.in b/debian/libtinfo5-udeb.install.in
new file mode 100644
index 000..b0b4373
--- /dev/null
+++ b/debian/libtinfo5-udeb.install.in
@@ -0,0 +1,2 @@
+usr/lib/${DEB_HOST_MULTIARCH}/libtinfo.so.*  lib/${DEB_HOST_MULTIARCH}
+usr/lib/${DEB_HOST_MULTIARCH}/libtic.so.*

and register the install:

--- a/debian/rules
+++ b/debian/rules
@@ -69,8 +69,8 @@ DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture
-qDEB_HOST_MULTIARCH)
 autogen-files := debian/libncurses5-dev.links debian/libtinfo-dev.links \
  debian/libncurses5.install debian/libncursesw5.install \
  debian/libncurses5-dev.install debian/libncursesw5-dev.install \
- debian/libtinfo5.install debian/libtinfo-dev.install \
- debian/libtermcap.so
+ debian/libtinfo5.install debian/libtinfo5-udeb.install \
+ debian/libtinfo-dev.install debian/libtermcap.so

But the result of built package keeps the same.
It still depends on lib32tinfo5, which is not udeb.

I also confirmed that there's no "/usr/lib/32" library in the udeb.
Library so files looks alright in udeb.
So I get lost completely.

>> I find another way, may be considered tricky though.
>> I find screen actually uses libtinfo.so, but not uses libtic.so, which
>> includes in libtinfo5-udeb.
>> After I applied the patch below to removed libtic.so from
>> libtinfo5-udeb, the dependency becomes normal as ARCH armel:
>>
>> $ dpkg-deb -I libtinfo5-udeb_6.0+20160319-2_amd64.udeb
>> Depends: libc6-udeb (>= 2.19)
>>
>> diff --git a/debian/libtinfo5-udeb.install b/debian/libtinfo5-udeb.install
>> index c6aa24a..576962e 100644
>> --- a/debian/libtinfo5-udeb.install
>> +++ b/debian/libtinfo5-udeb.install
>> @@ -1,2 +1 @@
>>  usr/lib/*/libtinfo.so.*
>> -usr/lib/*/libtic.so.*
>
> I don't like that, since the information in the libtinfo5 shlibs file
> information then becomes incorrect.  The shlibs file says that udebs
> with binaries linking to libtic should depend on libtinfo5-udeb, but
> libtinfo5-udeb would not actually contain the library.

Understand your points.
But I can argue that udeb is the deb package only contain the stuff
necessary for d-i.
Stuff d-i don't need can be removed.

If you don't accept that, we have to find out the perfect/clean solution..

Cheers,
-- 
Roger Shimizu, GMT +9 Tokyo
PGP/GPG: 17B3ACB1



Bug#819397: src:ncurses: Add udeb support to libtinfo5

2016-04-13 Thread Sven Joachim
Hi Roger,

sorry for not having replied last week, I was busy with other things.

On 2016-04-13 23:19 +0900, Roger Shimizu wrote:

> Dear Sven,
>
> On Sat, Apr 2, 2016 at 9:17 PM, Roger Shimizu  wrote:
>>
>> And here's patch v4.
>>
>> Changes v2:
>>  - add udeb supoort to libncurses5
>> Changes v3:
>>  - add "Priority: extra" to udeb in debian/control
>>  - fix typo when calling dh_makeshlibs
>> Changes v4:
>>  - remove udeb support for libncurses5, since it's not required by 
>> screen-udeb
>
> I was always on armel boxes do the screen support for d-i, so I didn't
> find there's a problem on amd64 until yesterday.
> With the previous v4 patch, building packages for src:ncurses on ARCH
> amd64, then check the dependency of built udeb:
>
> $ dpkg-deb -I libtinfo5-udeb_6.0+20160319-2_amd64.udeb
> Depends: lib32tinfo5 (>= 6), libc6-udeb (>= 2.19)

I see why: the debian/libtinfo5-udeb.install file installs files named
usr/lib/*/libtic.so.*, and unfortunately the multilib libraries match
that wildcard, so you end up with /usr/lib/32/libtic.so.5 in the udeb
which is not what we want.

> It seems "lib32tinfo5" only exists on amd64 and ppc64.
> Then I tried to add "lib32tinfo5-udeb" support in debian/control and
> debian/rules, but built "lib32tinfo5-udeb" depend on libc6-i386, which
> is not udeb. So I decide not to choose this solution.

Yes, the right solution is not to install these files into the udeb in
the first place.  This could be achieved by creating
libtinfo5-udeb.install from libtinfo5-udeb.install.in, as in the first
version of your patch.

> I find another way, may be considered tricky though.
> I find screen actually uses libtinfo.so, but not uses libtic.so, which
> includes in libtinfo5-udeb.
> After I applied the patch below to removed libtic.so from
> libtinfo5-udeb, the dependency becomes normal as ARCH armel:
>
> $ dpkg-deb -I libtinfo5-udeb_6.0+20160319-2_amd64.udeb
> Depends: libc6-udeb (>= 2.19)
>
> diff --git a/debian/libtinfo5-udeb.install b/debian/libtinfo5-udeb.install
> index c6aa24a..576962e 100644
> --- a/debian/libtinfo5-udeb.install
> +++ b/debian/libtinfo5-udeb.install
> @@ -1,2 +1 @@
>  usr/lib/*/libtinfo.so.*
> -usr/lib/*/libtic.so.*

I don't like that, since the information in the libtinfo5 shlibs file
information then becomes incorrect.  The shlibs file says that udebs
with binaries linking to libtic should depend on libtinfo5-udeb, but
libtinfo5-udeb would not actually contain the library.

Cheers,
   Sven



Bug#819397: src:ncurses: Add udeb support to libtinfo5

2016-04-13 Thread Roger Shimizu
Dear Sven,

On Sat, Apr 2, 2016 at 9:17 PM, Roger Shimizu  wrote:
>
> And here's patch v4.
>
> Changes v2:
>  - add udeb supoort to libncurses5
> Changes v3:
>  - add "Priority: extra" to udeb in debian/control
>  - fix typo when calling dh_makeshlibs
> Changes v4:
>  - remove udeb support for libncurses5, since it's not required by screen-udeb

I was always on armel boxes do the screen support for d-i, so I didn't
find there's a problem on amd64 until yesterday.
With the previous v4 patch, building packages for src:ncurses on ARCH
amd64, then check the dependency of built udeb:

$ dpkg-deb -I libtinfo5-udeb_6.0+20160319-2_amd64.udeb
Depends: lib32tinfo5 (>= 6), libc6-udeb (>= 2.19)

It seems "lib32tinfo5" only exists on amd64 and ppc64.
Then I tried to add "lib32tinfo5-udeb" support in debian/control and
debian/rules, but built "lib32tinfo5-udeb" depend on libc6-i386, which
is not udeb. So I decide not to choose this solution.

I find another way, may be considered tricky though.
I find screen actually uses libtinfo.so, but not uses libtic.so, which
includes in libtinfo5-udeb.
After I applied the patch below to removed libtic.so from
libtinfo5-udeb, the dependency becomes normal as ARCH armel:

$ dpkg-deb -I libtinfo5-udeb_6.0+20160319-2_amd64.udeb
Depends: libc6-udeb (>= 2.19)

diff --git a/debian/libtinfo5-udeb.install b/debian/libtinfo5-udeb.install
index c6aa24a..576962e 100644
--- a/debian/libtinfo5-udeb.install
+++ b/debian/libtinfo5-udeb.install
@@ -1,2 +1 @@
 usr/lib/*/libtinfo.so.*
-usr/lib/*/libtic.so.*

I also confirmed that the updated libtinfo5-udeb works well under
armel debian-installer with screen-udeb support.
(I still haven't figure out how to build d-i under amd64, fortunately
it's irrelevant to current topic)
So I'm wondering whether you can accept the above modify (patch).

Appreciate your continuous guidance and help!
And look forward to your feedback.

Cheers,
-- 
Roger Shimizu, GMT +9 Tokyo
PGP/GPG: 17B3ACB1



Bug#819397: src:ncurses: Add udeb support to libtinfo5

2016-04-10 Thread Roger Shimizu
Dear Sven,

May I know your release plan/schedule to add this libtinfo5-udeb patch?
Axel seems already prepared it well on package screen [0][1].

[0] https://anonscm.debian.org/cgit/collab-maint/screen.git/log/?h=screen-udeb
[1] https://bugs.debian.org/819988#31

Thank you for your support!

Cheers,
-- 
Roger Shimizu, GMT +9 Tokyo
PGP/GPG: 17B3ACB1



Bug#819397: src:ncurses: Add udeb support to libtinfo5

2016-04-02 Thread Roger Shimizu
Control: retitle -1 Add udeb support to libtinfo5

On Sat, Apr 2, 2016 at 6:42 PM, Sven Joachim  wrote:
>
> I had come to the same conclusion.  For better or worse, packages are
> not only built in minimal chroots, so screen had better be fixed not to
> gain the extraneous dependencies if libncurses5-dev or libutempter-dev
> are installed on the build system.  I have filed bugs #819781 and
> #819789 for that purpose, you're welcome to tackle them.

Thanks for the two reports above!
Things will be easier if these two gets resolved.

And here's patch v4.

Changes v2:
 - add udeb supoort to libncurses5
Changes v3:
 - add "Priority: extra" to udeb in debian/control
 - fix typo when calling dh_makeshlibs
Changes v4:
 - remove udeb support for libncurses5, since it's not required by screen-udeb

Cheers,
-- 
Roger Shimizu, GMT +9 Tokyo
PGP/GPG: 17B3ACB1
From 46932b5d1a19dd8613be590e65d0d78ec114e102 Mon Sep 17 00:00:00 2001
From: Roger Shimizu 
Date: Sun, 27 Mar 2016 23:15:51 +0900
Subject: [PATCH] Add udeb support to libtinfo5

---
 debian/changelog  |  7 +++
 debian/control| 13 +
 debian/libtinfo5-udeb.install |  2 ++
 debian/rules  |  2 +-
 4 files changed, 23 insertions(+), 1 deletion(-)
 create mode 100644 debian/libtinfo5-udeb.install

diff --git a/debian/changelog b/debian/changelog
index a02785a..6810fa1 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,10 @@
+ncurses (6.0+20160319-2) UNRELEASED; urgency=medium
+
+  [ Roger Shimizu ]
+  * Add udeb support to libtinfo5
+
+ -- Roger Shimizu   Sat, 26 Mar 2016 18:22:36 +0900
+
 ncurses (6.0+20160319-1) unstable; urgency=medium
 
   * New upstream patchlevel.
diff --git a/debian/control b/debian/control
index a740fa2..253e66e 100644
--- a/debian/control
+++ b/debian/control
@@ -27,6 +27,19 @@ Description: shared low-level terminfo library for terminal handling
  .
  This package contains the shared low-level terminfo library.
 
+Package: libtinfo5-udeb
+Package-Type: udeb
+Section: debian-installer
+Architecture: any
+Priority: extra
+Depends: ${shlibs:Depends}, ${misc:Depends}
+Description: shared low-level terminfo library for terminal handling - udeb
+ The ncurses library routines are a terminal-independent method of
+ updating character screens with reasonable optimization.
+ .
+ This package contains the stripped-down udeb version of shared low-level
+ terminfo library.
+
 Package: libncurses5
 Architecture: any
 Pre-Depends: ${misc:Pre-Depends}
diff --git a/debian/libtinfo5-udeb.install b/debian/libtinfo5-udeb.install
new file mode 100644
index 000..c6aa24a
--- /dev/null
+++ b/debian/libtinfo5-udeb.install
@@ -0,0 +1,2 @@
+usr/lib/*/libtinfo.so.*
+usr/lib/*/libtic.so.*
diff --git a/debian/rules b/debian/rules
index e1f67dc..4316d8d 100755
--- a/debian/rules
+++ b/debian/rules
@@ -471,7 +471,7 @@ endif
 	dh_compress -s -N$(package-examples)
 	dh_fixperms -s
 	dh_link -s
-	dh_makeshlibs -p$(package-ti) -V "$(package-ti) $(sodepver)" -- -c4
+	dh_makeshlibs -p$(package-ti) -V "$(package-ti) $(sodepver)" --add-udeb=$(package-ti)-udeb -- -c4
 	dh_makeshlibs -p$(package-lib) -V "$(package-lib) $(sodepver)" -- -c4
 	dh_makeshlibs -p$(package-libw) -V "$(package-libw) $(sodepver)" -- -c4
 ifneq ($(build_32),)
-- 
2.8.0.rc3



Bug#819397: src:ncurses: Add udeb support to libtinfo5

2016-04-02 Thread Sven Joachim
On 2016-04-02 17:49 +0900, Roger Shimizu wrote:

> On Sat, Apr 2, 2016 at 3:40 PM, Roger Shimizu  wrote:
>> On Sat, Apr 2, 2016 at 3:06 AM, Sven Joachim  wrote:
>>> Care to elaborate why that is needed?  The screen package does not
>>> depend on libncurses5.
>>
>> Yes, screen in ftp archive doesn't depend on libncurses5.
>> But if you build now, it depends more libraries than before.
>> Here's my result:
>>
>>  Depends: libc6 (>= 2.15), libncurses5 (>= 6), libpam0g (>= 0.99.7.1),
>> libtinfo5 (>= 6), libutempter0 (>= 1.1.5)
>
> I find if I remove "libncurses5-dev" and "libutempter-dev" from my
> system then rebuild screen, the Depends can be restored back to the
> same as ftp archive version.
>
> Depends: libc6 (>= 2.15), libpam0g (>= 0.99.7.1), libtinfo5 (>= 6)

I had come to the same conclusion.  For better or worse, packages are
not only built in minimal chroots, so screen had better be fixed not to
gain the extraneous dependencies if libncurses5-dev or libutempter-dev
are installed on the build system.  I have filed bugs #819781 and
#819789 for that purpose, you're welcome to tackle them.

Cheers,
   Sven



Bug#819397: src:ncurses: Add udeb support to libtinfo5

2016-04-02 Thread Roger Shimizu
On Sat, Apr 2, 2016 at 3:40 PM, Roger Shimizu  wrote:
> On Sat, Apr 2, 2016 at 3:06 AM, Sven Joachim  wrote:
>> Care to elaborate why that is needed?  The screen package does not
>> depend on libncurses5.
>
> Yes, screen in ftp archive doesn't depend on libncurses5.
> But if you build now, it depends more libraries than before.
> Here's my result:
>
>  Depends: libc6 (>= 2.15), libncurses5 (>= 6), libpam0g (>= 0.99.7.1),
> libtinfo5 (>= 6), libutempter0 (>= 1.1.5)

I find if I remove "libncurses5-dev" and "libutempter-dev" from my
system then rebuild screen, the Depends can be restored back to the
same as ftp archive version.

Depends: libc6 (>= 2.15), libpam0g (>= 0.99.7.1), libtinfo5 (>= 6)

So I'll update the patch again.

-- 
Roger Shimizu, GMT +9 Tokyo
PGP/GPG: 17B3ACB1



Bug#819397: src:ncurses: Add udeb support to libtinfo5

2016-04-02 Thread Roger Shimizu
On Sat, Apr 2, 2016 at 3:06 AM, Sven Joachim  wrote:
> On 2016-03-31 19:57 +0900, Roger Shimizu wrote:
>
>> Control: retitle -1 Add udeb support to libtinfo5 and libncurses5
>>
>>
>> Dear Sven,
>>
>> Really appreciate your review and comments!
>> I addressed your concern, and here's patch v2.
>>
>> Changes v2:
>> - add udeb supoort to libncurses5
>
> Care to elaborate why that is needed?  The screen package does not
> depend on libncurses5.

Yes, screen in ftp archive doesn't depend on libncurses5.
But if you build now, it depends more libraries than before.
Here's my result:

 Depends: libc6 (>= 2.15), libncurses5 (>= 6), libpam0g (>= 0.99.7.1),
libtinfo5 (>= 6), libutempter0 (>= 1.1.5)

>> +Package: libtinfo5-udeb
>> +Package-Type: udeb
>> +Section: debian-installer
>> +Architecture: any
>> +Depends: ${shlibs:Depends}, ${misc:Depends}
>> +Description: shared low-level terminfo library for terminal handling - udeb
>> + The ncurses library routines are a terminal-independent method of
>> + updating character screens with reasonable optimization.
>> + .
>> + This package contains the stripped-down udeb version of shared low-level
>> + terminfo library.
>
> Minor nitpick: you may want to add a "Priority: extra" line, otherwise
> the udebs inherit the priority from the source package (i.e. required).

Fixed in v3.

>> index e1f67dc..063495c 100755
>> --- a/debian/rules
>> +++ b/debian/rules
>> @@ -471,8 +471,8 @@ endif
>>   dh_compress -s -N$(package-examples)
>>   dh_fixperms -s
>>   dh_link -s
>> - dh_makeshlibs -p$(package-ti) -V "$(package-ti) $(sodepver)" -- -c4
>> - dh_makeshlibs -p$(package-lib) -V "$(package-lib) $(sodepver)" -- -c4
>> + dh_makeshlibs -p$(package-ti) -V "$(package-ti) $(sodepver)" 
>> --add-udeb=$(package-ti)-udeb -- -c4
>> + dh_makeshlibs -p$(package-lib) -V "$(package-lib) $(sodepver)" 
>> --add-udeb=$(package-ti)-udeb -- -c4
>
> Surely the last line should read "…--add-udeb=$(package-lib)-udeb…"
> instead?

Thanks for pointing out!
And here goes the patch v3.

Changes v2:
 - add udeb supoort to libncurses5
Changes v3:
 - add "Priority: extra" to udeb in debian/control
 - fix typo when calling dh_makeshlibs

Cheers,
-- 
Roger Shimizu, GMT +9 Tokyo
PGP/GPG: 17B3ACB1
From c3a9246635351ebf2aead211ce35a0c9b841c372 Mon Sep 17 00:00:00 2001
From: Roger Shimizu 
Date: Sun, 27 Mar 2016 23:15:51 +0900
Subject: [PATCH] Add udeb support to libtinfo5 and libncurses5

---
 debian/changelog|  7 +++
 debian/control  | 26 ++
 debian/libncurses5-udeb.install |  4 
 debian/libtinfo5-udeb.install   |  2 ++
 debian/rules|  4 ++--
 5 files changed, 41 insertions(+), 2 deletions(-)
 create mode 100644 debian/libncurses5-udeb.install
 create mode 100644 debian/libtinfo5-udeb.install

diff --git a/debian/changelog b/debian/changelog
index a02785a..55ea615 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,10 @@
+ncurses (6.0+20160319-2) UNRELEASED; urgency=medium
+
+  [ Roger Shimizu ]
+  * Add udeb support to libtinfo5 and libncurses5
+
+ -- Roger Shimizu   Sat, 26 Mar 2016 18:22:36 +0900
+
 ncurses (6.0+20160319-1) unstable; urgency=medium
 
   * New upstream patchlevel.
diff --git a/debian/control b/debian/control
index a740fa2..8b8509b 100644
--- a/debian/control
+++ b/debian/control
@@ -27,6 +27,19 @@ Description: shared low-level terminfo library for terminal handling
  .
  This package contains the shared low-level terminfo library.
 
+Package: libtinfo5-udeb
+Package-Type: udeb
+Section: debian-installer
+Architecture: any
+Priority: extra
+Depends: ${shlibs:Depends}, ${misc:Depends}
+Description: shared low-level terminfo library for terminal handling - udeb
+ The ncurses library routines are a terminal-independent method of
+ updating character screens with reasonable optimization.
+ .
+ This package contains the stripped-down udeb version of shared low-level
+ terminfo library.
+
 Package: libncurses5
 Architecture: any
 Pre-Depends: ${misc:Pre-Depends}
@@ -40,6 +53,19 @@ Description: shared libraries for terminal handling
  This package contains the shared libraries necessary to run programs
  compiled with ncurses.
 
+Package: libncurses5-udeb
+Package-Type: udeb
+Section: debian-installer
+Architecture: any
+Priority: extra
+Depends: libtinfo5-udeb (= ${binary:Version}), ${shlibs:Depends}, ${misc:Depends}
+Description: shared libraries for terminal handling -udeb
+ The ncurses library routines are a terminal-independent method of
+ updating character screens with reasonable optimization.
+ .
+ This package contains the stripped-down udeb version of shared libraries
+ necessary to run programs compiled with ncurses.
+
 Package: libtinfo-dev
 Architecture: any
 Section: libdevel
diff --git a/debian/libncurses5-udeb.install b/debian/libncurses5-udeb.install
new file mode 100644
index 000..162fb52
--- 

Bug#819397: src:ncurses: Add udeb support to libtinfo5

2016-04-01 Thread Sven Joachim
On 2016-03-31 19:57 +0900, Roger Shimizu wrote:

> Control: retitle -1 Add udeb support to libtinfo5 and libncurses5
>
>
> Dear Sven,
>
> Really appreciate your review and comments!
> I addressed your concern, and here's patch v2.
>
> Changes v2:
> - add udeb supoort to libncurses5

Care to elaborate why that is needed?  The screen package does not
depend on libncurses5.

> +Package: libtinfo5-udeb
> +Package-Type: udeb
> +Section: debian-installer
> +Architecture: any
> +Depends: ${shlibs:Depends}, ${misc:Depends}
> +Description: shared low-level terminfo library for terminal handling - udeb
> + The ncurses library routines are a terminal-independent method of
> + updating character screens with reasonable optimization.
> + .
> + This package contains the stripped-down udeb version of shared low-level
> + terminfo library.

Minor nitpick: you may want to add a "Priority: extra" line, otherwise
the udebs inherit the priority from the source package (i.e. required).

> index e1f67dc..063495c 100755
> --- a/debian/rules
> +++ b/debian/rules
> @@ -471,8 +471,8 @@ endif
>   dh_compress -s -N$(package-examples)
>   dh_fixperms -s
>   dh_link -s
> - dh_makeshlibs -p$(package-ti) -V "$(package-ti) $(sodepver)" -- -c4
> - dh_makeshlibs -p$(package-lib) -V "$(package-lib) $(sodepver)" -- -c4
> + dh_makeshlibs -p$(package-ti) -V "$(package-ti) $(sodepver)" 
> --add-udeb=$(package-ti)-udeb -- -c4
> + dh_makeshlibs -p$(package-lib) -V "$(package-lib) $(sodepver)" 
> --add-udeb=$(package-ti)-udeb -- -c4

Surely the last line should read "…--add-udeb=$(package-lib)-udeb…"
instead?

Cheers,
   Sven



Bug#819397: src:ncurses: Add udeb support to libtinfo5

2016-03-31 Thread Roger Shimizu
Control: retitle -1 Add udeb support to libtinfo5 and libncurses5


Dear Sven,

Really appreciate your review and comments!
I addressed your concern, and here's patch v2.

Changes v2:
- add udeb supoort to libncurses5
- change install.in to install for udeb
- add "--add-udeb" option to dh_makeshlibs in debian/rules
- remove no use arch for udeb in debian/control

Cheers,
-- 
Roger Shimizu, GMT +9 Tokyo
PGP/GPG: 17B3ACB1
From 16a4000c8fbf052796e399302a79812f270fa8ed Mon Sep 17 00:00:00 2001
From: Roger Shimizu 
Date: Sun, 27 Mar 2016 23:15:51 +0900
Subject: [PATCH] Add udeb support to libtinfo5 and libncurses5

---
 debian/changelog|  7 +++
 debian/control  | 24 
 debian/libncurses5-udeb.install |  4 
 debian/libtinfo5-udeb.install   |  2 ++
 debian/rules|  4 ++--
 5 files changed, 39 insertions(+), 2 deletions(-)
 create mode 100644 debian/libncurses5-udeb.install
 create mode 100644 debian/libtinfo5-udeb.install

diff --git a/debian/changelog b/debian/changelog
index a02785a..55ea615 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,10 @@
+ncurses (6.0+20160319-2) UNRELEASED; urgency=medium
+
+  [ Roger Shimizu ]
+  * Add udeb support to libtinfo5 and libncurses5
+
+ -- Roger Shimizu   Sat, 26 Mar 2016 18:22:36 +0900
+
 ncurses (6.0+20160319-1) unstable; urgency=medium
 
   * New upstream patchlevel.
diff --git a/debian/control b/debian/control
index a740fa2..5de67a4 100644
--- a/debian/control
+++ b/debian/control
@@ -27,6 +27,18 @@ Description: shared low-level terminfo library for terminal handling
  .
  This package contains the shared low-level terminfo library.
 
+Package: libtinfo5-udeb
+Package-Type: udeb
+Section: debian-installer
+Architecture: any
+Depends: ${shlibs:Depends}, ${misc:Depends}
+Description: shared low-level terminfo library for terminal handling - udeb
+ The ncurses library routines are a terminal-independent method of
+ updating character screens with reasonable optimization.
+ .
+ This package contains the stripped-down udeb version of shared low-level
+ terminfo library.
+
 Package: libncurses5
 Architecture: any
 Pre-Depends: ${misc:Pre-Depends}
@@ -40,6 +52,18 @@ Description: shared libraries for terminal handling
  This package contains the shared libraries necessary to run programs
  compiled with ncurses.
 
+Package: libncurses5-udeb
+Package-Type: udeb
+Section: debian-installer
+Architecture: any
+Depends: libtinfo5-udeb (= ${binary:Version}), ${shlibs:Depends}, ${misc:Depends}
+Description: shared libraries for terminal handling -udeb
+ The ncurses library routines are a terminal-independent method of
+ updating character screens with reasonable optimization.
+ .
+ This package contains the stripped-down udeb version of shared libraries
+ necessary to run programs compiled with ncurses.
+
 Package: libtinfo-dev
 Architecture: any
 Section: libdevel
diff --git a/debian/libncurses5-udeb.install b/debian/libncurses5-udeb.install
new file mode 100644
index 000..162fb52
--- /dev/null
+++ b/debian/libncurses5-udeb.install
@@ -0,0 +1,4 @@
+usr/lib/*/libncurses.so.*
+usr/lib/*/libpanel.so.*
+usr/lib/*/libform.so.*
+usr/lib/*/libmenu.so.*
diff --git a/debian/libtinfo5-udeb.install b/debian/libtinfo5-udeb.install
new file mode 100644
index 000..c6aa24a
--- /dev/null
+++ b/debian/libtinfo5-udeb.install
@@ -0,0 +1,2 @@
+usr/lib/*/libtinfo.so.*
+usr/lib/*/libtic.so.*
diff --git a/debian/rules b/debian/rules
index e1f67dc..063495c 100755
--- a/debian/rules
+++ b/debian/rules
@@ -471,8 +471,8 @@ endif
 	dh_compress -s -N$(package-examples)
 	dh_fixperms -s
 	dh_link -s
-	dh_makeshlibs -p$(package-ti) -V "$(package-ti) $(sodepver)" -- -c4
-	dh_makeshlibs -p$(package-lib) -V "$(package-lib) $(sodepver)" -- -c4
+	dh_makeshlibs -p$(package-ti) -V "$(package-ti) $(sodepver)" --add-udeb=$(package-ti)-udeb -- -c4
+	dh_makeshlibs -p$(package-lib) -V "$(package-lib) $(sodepver)" --add-udeb=$(package-ti)-udeb -- -c4
 	dh_makeshlibs -p$(package-libw) -V "$(package-libw) $(sodepver)" -- -c4
 ifneq ($(build_32),)
 	dh_makeshlibs -p$(package-ti-32) -V "$(package-ti-32) $(sodepver)" -- -c4
-- 
2.8.0.rc3



Bug#819397: src:ncurses: Add udeb support to libtinfo5

2016-03-30 Thread Sven Joachim
Control: severity -1 wishlist
Control: tags -1 + moreinfo

On 2016-03-28 09:39 +0900, Roger Shimizu wrote:

> Package: src:ncurses
> Severity: normal
> Tags: patch, d-i
> X-Debbugs-Cc: rogershim...@gmail.com
>
> Dear Maintainer,
>
> I'm trying to port GNU/screen to debian-installer [0].
> GNU/screen depends on your library, so enclosed the patch I created to
> make those udeb support.
>
> I hope you can merge my patch soon. Thank you!

There are various things wrong with it, unfortunately.

> +Package: libtinfo5-udeb
> +XC-Package-Type: udeb

Please use Package-Type rather than XC-Package-Type.
See "lintian-info -t xc-package-type-in-debian-control".

> +Section: debian-installer
> +Architecture: any
> +Pre-Depends: ${misc:Pre-Depends}

Uhm, why Pre-Depends?

> +Multi-Arch: same

It does not really make sense to mark udebs as "Multi-Arch: same" since
you won't be using more than one architecture in the installer.

> +Depends: ${misc:Depends}
> +Description: shared low-level terminfo library for terminal handling - udeb
> + The ncurses library routines are a terminal-independent method of
> + updating character screens with reasonable optimization.
> + .
> + This package contains the stripped-down udeb version of shared low-level
> + terminfo library.
> +
>  Package: libncurses5
>  Architecture: any
>  Pre-Depends: ${misc:Pre-Depends}
> diff --git a/debian/libtinfo5-udeb.install.in 
> b/debian/libtinfo5-udeb.install.in
> new file mode 100644
> index 000..b0b4373
> --- /dev/null
> +++ b/debian/libtinfo5-udeb.install.in
> @@ -0,0 +1,2 @@
> +usr/lib/${DEB_HOST_MULTIARCH}/libtinfo.so.*  lib/${DEB_HOST_MULTIARCH}
> +usr/lib/${DEB_HOST_MULTIARCH}/libtic.so.*

I would just install all libraries into lib, and then you don't need to
use a libtinfo5-udeb.install.in file.

Most importantly, you need to generate udeb lines in the libtinfo5
shlibs file, so that udebs with programs linked against libtinfo depend
on libtinfo5-udeb rather than libtinfo5.  To achieve that, pass
"--add-udeb" in the dh_makeshlibs call for libtinfo5 in debian/rules.

Cheers,
   Sven



Bug#819397: src:ncurses: Add udeb support to libtinfo5

2016-03-27 Thread Roger Shimizu
Package: src:ncurses
Severity: normal
Tags: patch, d-i
X-Debbugs-Cc: rogershim...@gmail.com

Dear Maintainer,

I'm trying to port GNU/screen to debian-installer [0].
GNU/screen depends on your library, so enclosed the patch I created to
make those udeb support.

I hope you can merge my patch soon. Thank you!

[0] https://lists.debian.org/debian-boot/2016/02/msg00547.html

Cheers,
-- 
Roger Shimizu, GMT +9 Tokyo
PGP/GPG: 17B3ACB1
From b04aa53a4779be55bed8c426ccbdbc5ad37a0008 Mon Sep 17 00:00:00 2001
From: Roger Shimizu 
Date: Sun, 27 Mar 2016 23:15:51 +0900
Subject: [PATCH] Add udeb support to libtinfo5

---
 debian/changelog |  7 +++
 debian/control   | 14 ++
 debian/libtinfo5-udeb.install.in |  2 ++
 debian/rules |  4 ++--
 4 files changed, 25 insertions(+), 2 deletions(-)
 create mode 100644 debian/libtinfo5-udeb.install.in

diff --git a/debian/changelog b/debian/changelog
index a02785a..6810fa1 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,10 @@
+ncurses (6.0+20160319-2) UNRELEASED; urgency=medium
+
+  [ Roger Shimizu ]
+  * Add udeb support to libtinfo5
+
+ -- Roger Shimizu   Sat, 26 Mar 2016 18:22:36 +0900
+
 ncurses (6.0+20160319-1) unstable; urgency=medium
 
   * New upstream patchlevel.
diff --git a/debian/control b/debian/control
index a740fa2..7cdc4aa 100644
--- a/debian/control
+++ b/debian/control
@@ -27,6 +27,20 @@ Description: shared low-level terminfo library for terminal handling
  .
  This package contains the shared low-level terminfo library.
 
+Package: libtinfo5-udeb
+XC-Package-Type: udeb
+Section: debian-installer
+Architecture: any
+Pre-Depends: ${misc:Pre-Depends}
+Multi-Arch: same
+Depends: ${misc:Depends}
+Description: shared low-level terminfo library for terminal handling - udeb
+ The ncurses library routines are a terminal-independent method of
+ updating character screens with reasonable optimization.
+ .
+ This package contains the stripped-down udeb version of shared low-level
+ terminfo library.
+
 Package: libncurses5
 Architecture: any
 Pre-Depends: ${misc:Pre-Depends}
diff --git a/debian/libtinfo5-udeb.install.in b/debian/libtinfo5-udeb.install.in
new file mode 100644
index 000..b0b4373
--- /dev/null
+++ b/debian/libtinfo5-udeb.install.in
@@ -0,0 +1,2 @@
+usr/lib/${DEB_HOST_MULTIARCH}/libtinfo.so.*  lib/${DEB_HOST_MULTIARCH}
+usr/lib/${DEB_HOST_MULTIARCH}/libtic.so.*
diff --git a/debian/rules b/debian/rules
index e1f67dc..a2c31bd 100755
--- a/debian/rules
+++ b/debian/rules
@@ -69,8 +69,8 @@ DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH)
 autogen-files := debian/libncurses5-dev.links debian/libtinfo-dev.links \
 		 debian/libncurses5.install debian/libncursesw5.install \
 		 debian/libncurses5-dev.install debian/libncursesw5-dev.install \
-		 debian/libtinfo5.install debian/libtinfo-dev.install \
-		 debian/libtermcap.so
+		 debian/libtinfo5.install debian/libtinfo5-udeb.install \
+		 debian/libtinfo-dev.install debian/libtermcap.so
 
 ifeq ($(DEB_HOST_ARCH),i386)
 build_64_target = x86_64-$(DEB_HOST_GNU_SYSTEM)
-- 
2.8.0.rc3