Patchwork [1/1] curl: Backport a fix for a build issue

login
register
mail settings
Submitter Tudor Florea
Date May 2, 2014, 10:21 p.m.
Message ID <1399069283-22753-1-git-send-email-tudor.florea@enea.com>
Download mbox | patch
Permalink /patch/71423/
State Accepted
Commit 530e66cb04508e361643609496da8b2b4f75e3bf
Headers show

Comments

Tudor Florea - May 2, 2014, 10:21 p.m.
mkhelp: generate code for --disable-manual as well

This allows configure --disable-manual to run and build without having
to regenerate the src/tool_hugehelp.c file which otherwise is necessary
since we ship tarballs with that file present.

Signed-off-by: Tudor Florea <tudor.florea@enea.com>
---
 .../curl/generate_code_for_disable_manual.patch    |   38 ++++++++++++++++++++
 meta/recipes-support/curl/curl_7.36.0.bb           |    1 +
 2 files changed, 39 insertions(+)
 create mode 100644 meta/recipes-support/curl/curl/generate_code_for_disable_manual.patch
Otavio Salvador - May 3, 2014, 1:04 p.m.
Hello Tudor,

On Fri, May 2, 2014 at 7:21 PM, Tudor Florea <tudor.florea@enea.com> wrote:
> mkhelp: generate code for --disable-manual as well
>
> This allows configure --disable-manual to run and build without having
> to regenerate the src/tool_hugehelp.c file which otherwise is necessary
> since we ship tarballs with that file present.
>
> Signed-off-by: Tudor Florea <tudor.florea@enea.com>

Thanks for looking at this. Comments below...

>  .../curl/generate_code_for_disable_manual.patch    |   38 ++++++++++++++++++++
>  meta/recipes-support/curl/curl_7.36.0.bb           |    1 +
>  2 files changed, 39 insertions(+)
>  create mode 100644 meta/recipes-support/curl/curl/generate_code_for_disable_manual.patch
>
> diff --git a/meta/recipes-support/curl/curl/generate_code_for_disable_manual.patch b/meta/recipes-support/curl/curl/generate_code_for_disable_manual.patch
> new file mode 100644
> index 0000000..dc755e4
> --- /dev/null
> +++ b/meta/recipes-support/curl/curl/generate_code_for_disable_manual.patch
> @@ -0,0 +1,38 @@
> +Upsteam-Status Backport [fixed in 7.37.0]
> +commit 38d582ff541353d738858299d4a2b78bafac03ed
> +Author: Daniel Stenberg <daniel@haxx.se>
> +Date:   Wed Mar 26 13:22:10 2014 +0100
> +
> +    mkhelp: generate code for --disable-manual as well
> +
> +    This allows configure --disable-manual to run and build without having
> +    to regenerate the src/tool_hugehelp.c file which otherwise is necessary
> +    since we ship tarballs with that file present.
> +
> +    Reported-by: Remi Gacogne
> +    Bug: http://curl.haxx.se/bug/view.cgi?id=1350

Upstream-Status please.

...
> diff --git a/meta/recipes-support/curl/curl_7.36.0.bb b/meta/recipes-support/curl/curl_7.36.0.bb
> index 6f55463..bd7191d 100644
> --- a/meta/recipes-support/curl/curl_7.36.0.bb
> +++ b/meta/recipes-support/curl/curl_7.36.0.bb
> @@ -11,6 +11,7 @@ DEPENDS_class-nativesdk = "nativesdk-zlib"
>
>  SRC_URI = "http://curl.haxx.se/download/curl-${PV}.tar.bz2 \
>             file://pkgconfig_fix.patch \
> +           file://generate_code_for_disable_manual.patch \
>  "
>
>  # curl likes to set -g0 in CFLAGS, so we stop it

The manual detection is floating as it was reproduced in our builder
and worked for you initially. Please pass --disable-manual explicitly.

Patch

diff --git a/meta/recipes-support/curl/curl/generate_code_for_disable_manual.patch b/meta/recipes-support/curl/curl/generate_code_for_disable_manual.patch
new file mode 100644
index 0000000..dc755e4
--- /dev/null
+++ b/meta/recipes-support/curl/curl/generate_code_for_disable_manual.patch
@@ -0,0 +1,38 @@ 
+Upsteam-Status Backport [fixed in 7.37.0]
+commit 38d582ff541353d738858299d4a2b78bafac03ed
+Author: Daniel Stenberg <daniel@haxx.se>
+Date:   Wed Mar 26 13:22:10 2014 +0100
+
+    mkhelp: generate code for --disable-manual as well
+    
+    This allows configure --disable-manual to run and build without having
+    to regenerate the src/tool_hugehelp.c file which otherwise is necessary
+    since we ship tarballs with that file present.
+    
+    Reported-by: Remi Gacogne
+    Bug: http://curl.haxx.se/bug/view.cgi?id=1350
+
+diff --git a/src/mkhelp.pl b/src/mkhelp.pl
+index 444b669..7ed86f7 100644
+--- a/src/mkhelp.pl
++++ b/src/mkhelp.pl
+@@ -6,7 +6,7 @@
+ #                            | (__| |_| |  _ <| |___
+ #                             \___|\___/|_| \_\_____|
+ #
+-# Copyright (C) 1998 - 2011, Daniel Stenberg, <daniel@haxx.se>, et al.
++# Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
+ #
+ # This software is licensed as described in the file COPYING, which
+ # you should have received as part of this distribution. The terms
+@@ -256,6 +256,10 @@ foot();
+ 
+ sub foot {
+   print <<FOOT
++#else /* !USE_MANUAL */
++/* built-in manual is disabled, blank function */
++#include "tool_hugehelp.h"
++void hugehelp(void) {}
+ #endif /* USE_MANUAL */
+ FOOT
+   ;
diff --git a/meta/recipes-support/curl/curl_7.36.0.bb b/meta/recipes-support/curl/curl_7.36.0.bb
index 6f55463..bd7191d 100644
--- a/meta/recipes-support/curl/curl_7.36.0.bb
+++ b/meta/recipes-support/curl/curl_7.36.0.bb
@@ -11,6 +11,7 @@  DEPENDS_class-nativesdk = "nativesdk-zlib"
 
 SRC_URI = "http://curl.haxx.se/download/curl-${PV}.tar.bz2 \
            file://pkgconfig_fix.patch \
+           file://generate_code_for_disable_manual.patch \
 "
 
 # curl likes to set -g0 in CFLAGS, so we stop it