Patchwork [8/8] distcc_2.18.3.bb: Fix compilation on uclibc

login
register
mail settings
Submitter Saul Wold
Date May 21, 2011, 6:38 p.m.
Message ID <92c28973316e62fd2e4054fe3bab85685c5acc3e.1306002889.git.sgw@linux.intel.com>
Download mbox | patch
Permalink /patch/4583/
State New, archived
Headers show

Comments

Saul Wold - May 21, 2011, 6:38 p.m.
From: Khem Raj <raj.khem@gmail.com>

We enable gtk/gnome in distcc that code uses loadavg()
a function unimplemented in uclibc. Therefore for uclibc
we disable gnome and gtk+ features in distcc

Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
 meta/recipes-devtools/distcc/distcc_2.18.3.bb |   17 ++++++++++++-----
 1 files changed, 12 insertions(+), 5 deletions(-)
Khem Raj - May 21, 2011, 11:06 p.m.
On Sat, May 21, 2011 at 11:38 AM, Saul Wold <sgw@linux.intel.com> wrote:
> From: Khem Raj <raj.khem@gmail.com>
>
> We enable gtk/gnome in distcc that code uses loadavg()
> a function unimplemented in uclibc. Therefore for uclibc
> we disable gnome and gtk+ features in distcc
>


This patch had reviews to be addressed which I have done
the patch is updated in pull branch. Use that one

> Signed-off-by: Khem Raj <raj.khem@gmail.com>
> ---
>  meta/recipes-devtools/distcc/distcc_2.18.3.bb |   17 ++++++++++++-----
>  1 files changed, 12 insertions(+), 5 deletions(-)
>
> diff --git a/meta/recipes-devtools/distcc/distcc_2.18.3.bb b/meta/recipes-devtools/distcc/distcc_2.18.3.bb
> index 1f5c2af..34b04a5 100644
> --- a/meta/recipes-devtools/distcc/distcc_2.18.3.bb
> +++ b/meta/recipes-devtools/distcc/distcc_2.18.3.bb
> @@ -6,7 +6,10 @@ LICENSE = "GPLv2"
>  LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
>  PR = "r6"
>
> -DEPENDS = "avahi gtk+"
> +DEPENDS = "avahi ${GTKDEP}"
> +GTKDEP_libc-uclibc = ""
> +GTKDEP = "gtk+"
> +
>  RRECOMMENDS_${PN} = "avahi-daemon"
>
>  # Upstream change this patch periodically so store locally
> @@ -24,17 +27,21 @@ inherit autotools pkgconfig update-rc.d
>
>  INITSCRIPT_NAME = "distcc"
>
> -EXTRA_OECONF = " --with-gtk "
> -
> +EXTRA_OECONF_libc-glibc = " --with-gtk "
> +EXTRA_OECONF_libc-uclibc = " --without-gtk --without-gnome "
>  do_install_append() {
>     install -d ${D}${sysconfdir}/init.d/
>     install -d ${D}${sysconfdir}/default
>     install -m 0755 ${WORKDIR}/distcc ${D}${sysconfdir}/init.d/
>     install -m 0755 ${WORKDIR}/default ${D}${sysconfdir}/default/distcc
> +    ${DESKTOPINSTALL}
> +}
> +DESKTOPINSTALL = ""
> +DESKTOPINSTALL_libc-glibc () {
> +    install -d ${D}${datadir}/distcc/
>     install -m 0644 ${WORKDIR}/distccmon-gnome.desktop ${D}${datadir}/distcc/
>  }
> -
> -PACKAGES += "distcc-distmon-gnome"
> +PACKAGES_append_libc-glibc = " distcc-distmon-gnome"
>
>  FILES_${PN} = " ${sysconfdir} \
>                ${bindir}/distcc \
> --
> 1.7.3.4
>
>
Saul Wold - May 22, 2011, 3:17 a.m.
On 05/21/2011 04:06 PM, Khem Raj wrote:
> On Sat, May 21, 2011 at 11:38 AM, Saul Wold<sgw@linux.intel.com>  wrote:
>> From: Khem Raj<raj.khem@gmail.com>
>>
>> We enable gtk/gnome in distcc that code uses loadavg()
>> a function unimplemented in uclibc. Therefore for uclibc
>> we disable gnome and gtk+ features in distcc
>>
>
>
> This patch had reviews to be addressed which I have done
> the patch is updated in pull branch. Use that one
>
I will pull the lastest into my sgw/stage branch.  When I did the pull, 
I thought things were completed, I guess bad timing on my part.

Sau!


>> Signed-off-by: Khem Raj<raj.khem@gmail.com>
>> ---
>>   meta/recipes-devtools/distcc/distcc_2.18.3.bb |   17 ++++++++++++-----
>>   1 files changed, 12 insertions(+), 5 deletions(-)
>>
>> diff --git a/meta/recipes-devtools/distcc/distcc_2.18.3.bb b/meta/recipes-devtools/distcc/distcc_2.18.3.bb
>> index 1f5c2af..34b04a5 100644
>> --- a/meta/recipes-devtools/distcc/distcc_2.18.3.bb
>> +++ b/meta/recipes-devtools/distcc/distcc_2.18.3.bb
>> @@ -6,7 +6,10 @@ LICENSE = "GPLv2"
>>   LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
>>   PR = "r6"
>>
>> -DEPENDS = "avahi gtk+"
>> +DEPENDS = "avahi ${GTKDEP}"
>> +GTKDEP_libc-uclibc = ""
>> +GTKDEP = "gtk+"
>> +
>>   RRECOMMENDS_${PN} = "avahi-daemon"
>>
>>   # Upstream change this patch periodically so store locally
>> @@ -24,17 +27,21 @@ inherit autotools pkgconfig update-rc.d
>>
>>   INITSCRIPT_NAME = "distcc"
>>
>> -EXTRA_OECONF = " --with-gtk "
>> -
>> +EXTRA_OECONF_libc-glibc = " --with-gtk "
>> +EXTRA_OECONF_libc-uclibc = " --without-gtk --without-gnome "
>>   do_install_append() {
>>      install -d ${D}${sysconfdir}/init.d/
>>      install -d ${D}${sysconfdir}/default
>>      install -m 0755 ${WORKDIR}/distcc ${D}${sysconfdir}/init.d/
>>      install -m 0755 ${WORKDIR}/default ${D}${sysconfdir}/default/distcc
>> +    ${DESKTOPINSTALL}
>> +}
>> +DESKTOPINSTALL = ""
>> +DESKTOPINSTALL_libc-glibc () {
>> +    install -d ${D}${datadir}/distcc/
>>      install -m 0644 ${WORKDIR}/distccmon-gnome.desktop ${D}${datadir}/distcc/
>>   }
>> -
>> -PACKAGES += "distcc-distmon-gnome"
>> +PACKAGES_append_libc-glibc = " distcc-distmon-gnome"
>>
>>   FILES_${PN} = " ${sysconfdir} \
>>                 ${bindir}/distcc \
>> --
>> 1.7.3.4
>>
>>

Patch

diff --git a/meta/recipes-devtools/distcc/distcc_2.18.3.bb b/meta/recipes-devtools/distcc/distcc_2.18.3.bb
index 1f5c2af..34b04a5 100644
--- a/meta/recipes-devtools/distcc/distcc_2.18.3.bb
+++ b/meta/recipes-devtools/distcc/distcc_2.18.3.bb
@@ -6,7 +6,10 @@  LICENSE = "GPLv2"
 LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
 PR = "r6"
 
-DEPENDS = "avahi gtk+"
+DEPENDS = "avahi ${GTKDEP}"
+GTKDEP_libc-uclibc = ""
+GTKDEP = "gtk+"
+
 RRECOMMENDS_${PN} = "avahi-daemon"
 
 # Upstream change this patch periodically so store locally
@@ -24,17 +27,21 @@  inherit autotools pkgconfig update-rc.d
 
 INITSCRIPT_NAME = "distcc"
 
-EXTRA_OECONF = " --with-gtk "
-
+EXTRA_OECONF_libc-glibc = " --with-gtk "
+EXTRA_OECONF_libc-uclibc = " --without-gtk --without-gnome "
 do_install_append() {
     install -d ${D}${sysconfdir}/init.d/
     install -d ${D}${sysconfdir}/default
     install -m 0755 ${WORKDIR}/distcc ${D}${sysconfdir}/init.d/
     install -m 0755 ${WORKDIR}/default ${D}${sysconfdir}/default/distcc
+    ${DESKTOPINSTALL}
+}
+DESKTOPINSTALL = ""
+DESKTOPINSTALL_libc-glibc () {
+    install -d ${D}${datadir}/distcc/
     install -m 0644 ${WORKDIR}/distccmon-gnome.desktop ${D}${datadir}/distcc/
 }
-
-PACKAGES += "distcc-distmon-gnome"
+PACKAGES_append_libc-glibc = " distcc-distmon-gnome"
 
 FILES_${PN} = " ${sysconfdir} \
 		${bindir}/distcc \