Skip to contentSkip to conversation

Discussion about gettext.bbclass

DISCUSSION Henning Heinold 3 participants 7 messages Sep 25, 2008 – Sep 28, 2008

lore
Share & tools
lore
#0 lore raw

Hi,

I want discuss another changes to a classes file. This time about gettext.bbclass I attached a patch which is simpler to understand and a little more powerfull.

So what I changed:

- put the DPENDS field on top, because its easier to understand that this will parsed and set first, besides gettext_after_parse is called after the parsing process

- added virtual/libiconv virtual/libintl to DEPENDS, bescause they are mostly needed anyway when you want NLS and do not harm when you do not need libintl

Second I want to make a propose to rename this bbclass, because it is not gettext depend only. We have libiconv either from libc or gnu and now proxy-libintl involed. So I would suggest to name it nls.bbclass . I wait for you comments.

Bye Henning

#1 lore raw
Quoted 5 lines · On Thursday 25 September 2008 21:14:52 Henning Heinold wrote:

Hi,

I want discuss another changes to a classes file. This time about gettext.bbclass I attached a patch which is simpler to understand and a little more powerfull.

Maybe I'm too tired but I don't see a patch :)

z.

#2 lore raw

Hi
I am trying to build gcc-4.2.0 package using bitbake.
I have done proper changes in meta data, now when i give bitbake
meta data i get some error of a header file. Log file is attached with this mail.
Please help me solve this problem.
Thanks
Nishant Soin

#3 lore raw
In reply to Holger Freyther
Quoted 11 lines · Holger Freyther
Quoted 5 lines · On Thursday 25 September 2008 21:14:52 Henning Heinold wrote:

Hi,

I want discuss another changes to a classes file. This time about gettext.bbclass I attached a patch which is simpler to understand and a little more powerfull.

Maybe I'm too tired but I don't see a patch :)

z.

Yepp,

sorry was to late yesterday and now I am at work. I will send the patch this evening.

Bye Henning

#4 lore raw
In reply to Holger Freyther

Here is the patch now.

Bye Henning

#

# old_revision [6950cb0adadcf0fa171ec2fdd0751373a16fa294]
#
# patch "classes/gettext.bbclass"
#  from [a0ba1057eaf6a5619d05a1d4fe7e262095b34168]
#    to [46480807107b00b5b0a16442a461ddf95332bbb8]
#
============================================================
--- classes/gettext.bbclass	a0ba1057eaf6a5619d05a1d4fe7e262095b34168
+++ classes/gettext.bbclass	46480807107b00b5b0a16442a461ddf95332bbb8
@@ -1,16 +1,16 @@
+DEPENDS =+ "gettext-native virtual/libiconv virtual/libintl"
+EXTRA_OECONF += "--enable-nls"
+
 def gettext_after_parse(d):
     import bb
     # Remove the NLS bits if USE_NLS is no.
     if bb.data.getVar('USE_NLS', d, 1) == 'no':
         cfg = oe_filter_out('^--(dis|en)able-nls$', bb.data.getVar('EXTRA_OECONF', d, 1) or "", d)
         cfg += " --disable-nls"
-        depends = bb.data.getVar('DEPENDS', d, 1) or ""
-        bb.data.setVar('DEPENDS', oe_filter_out('^(virtual/libiconv|virtual/libintl)$', depends, d), d)
         bb.data.setVar('EXTRA_OECONF', cfg, d)
+        depends = bb.data.getVar('DEPENDS', d, 1) or ""
+        bb.data.setVar('DEPENDS', oe_filter_out('^(gettext-native|virtual/libiconv|virtual/libintl)$', depends, d), d)

python () {
gettext_after_parse(d)
}
-
-DEPENDS =+ "gettext-native"
-EXTRA_OECONF += "--enable-nls"

#5 lore raw
Quoted 3 lines · On Friday 26 September 2008 21:36:49 Henning Heinold wrote:

Here is the patch now.

Bye Henning

When do you want to do the renaming to nls.bbclass? Besides that I don't see anything wrong in your patch.

When you propose the nls.bbclass we should also cleanup the existing recipes putting virtual/libintl and virtual/libiconv into the DEPENDS.

z.

#6 lore raw
Quoted 7 lines · Holger Freyther
Quoted 3 lines · On Friday 26 September 2008 21:36:49 Henning Heinold wrote:

Here is the patch now.

Bye Henning

When do you want to do the renaming to nls.bbclass? Besides that I don't see anything wrong in your patch.

Because the class is reflecting if you want NLS support or not and not if you want gettext stuff. Because gettext is now the only tool which generates the .po files is another story, but as I mentioned earlier for runtime there is now proxy-libintl, which is providing libintl too.

Quoted 4 lines

When you propose the nls.bbclass we should also cleanup the existing recipes putting virtual/libintl and virtual/libiconv into the DEPENDS.

Yes, there are a lot of recipes which could be simplify with inherit gettex and there are packages from gtk stuff, which uses gettext but dont honor the --disable-nls configure option like atk or pango.

Quoted 1 line

z.

Bye Henning