Subject: [alpine-devel] lang subpackages

From: Natanael Copa <[email-masked]>
Date: Wed, 5 Oct 2011 13:13:42 +0200

Hi,

So I have implemented a new "special" subpackage in abuild: -lang

This will copy /usr/share/locale into a $pkgname-lang subpackage.

I have also created a "lang" meta package which will pull in the
translation packages and I have splitted out the translations for a
handful packages. I started with the ones who had the
biggest /usr/share/locale dirs.

This can save some megs if you don't use the translations:

alpine-netbook:~/src$ sudo apk del -i lang
The following packages will be REMOVED:
  lang glade3-lang gnome-disk-utility-lang glib-lang gvfs-lang iso-codes-lang
  xfce-utils-lang gimp-lang xfce4-settings-lang thunar-lang gtk+2.0-lang
  lxdm-lang xfce4-panel-lang xfwm4-lang inkscape-lang shotwell-lang
  pidgin-lang gconf-lang gnumeric-lang gigolo-lang
After this operation, 157896 kB of disk space will be freed.

I'm saving 158MB on my lappy. not bad...

If you see the warning about /usr/share/locale then its just to add
$pkgname-lang to subpackages and abuild takes care of the rest.

-nc

---
Unsubscribe:  [email-masked]
Help:         [email-masked]
---

---

From: Jeremy Thomerson <[email-masked]>
Date: Thu, 13 Oct 2011 21:58:21 -0400

> I'm saving 158MB on my lappy. not bad...

Should we try to create a per-lang package instead of one lang package that
has all languages?  I think we discussed this a while back and IIRC we opted
not to because of the bloat it might cause ($packages x $languages =
$lotsOfLittlePackages).  Was that the only reason, or is there another?

It would be nice to "apk add lang-en lang-es" and just get the languages we
needed.

Jeremy Thomerson

---

From: Natanael Copa <[email-masked]>
Date: Fri, 14 Oct 2011 08:34:30 +0200

On Thu, 13 Oct 2011 21:58:21 -0400
Jeremy Thomerson <[email-masked]> wrote:

> >  xfce-utils-lang gimp-lang xfce4-settings-lang thunar-lang
> > gtk+2.0-lang lxdm-lang xfce4-panel-lang xfwm4-lang inkscape-lang
> > shotwell-lang pidgin-lang gconf-lang gnumeric-lang gigolo-lang
> Should we try to create a per-lang package instead of one lang
> package that has all languages?  I think we discussed this a while
> back and IIRC we opted not to because of the bloat it might cause
> ($packages x $languages = $lotsOfLittlePackages).  Was that the only
> reason, or is there another?

That was the only reason. There was a fairly good suggestion of putting
them in a separate repo. Splitting build targets (apk packages frrom
same APKBUILD) into different repos makes the building infra more
complicated. We talked about that for noarch packages too, having x86
and x86_64 packages share same noarch files, but I haven't figured out
how to do that in a straightforward way without having the build
servers know of each other. (I kinda like the ports approach from *BSD)

Part of the problem is, I would like to run a command similar 'make
all' and then should only the packages that are missing or outdated
(APKBUILD is newer than .apk) be built/rebuilt. But if the APKBUILD
puts the packages in $PKGDIR/$arch/ how would abuild know where to look
for the built target? We would need to tell the arch for each
subpackage in some way. (currently this is detected build time and
there is no way to know where the package will end up til after the
build)

> It would be nice to "apk add lang-en lang-es" and just get the
> languages we needed.

I think what we will do is only split the biggest -lang packages
(gimp, pidgin, inkscape, gtk+ etc). Maybe start with the lang packages
bigger than 10MB or similar.

Then the lang-es metapackage should have "lang" as dependency. so if
you do 'apk add lang-es' you'll get the ones that has -lang-es + those
who only has -lang.

-nc

---