From: Richard Purdie <richard.purdie@linuxfoundation.org>
To: Patches and discussions about the oe-core layer
<openembedded-core@lists.openembedded.org>
Subject: Re: [PATCH 5/9] sat-solver: Fix build on uclibc
Date: Fri, 15 Jun 2012 13:55:54 +0100 [thread overview]
Message-ID: <1339764954.24333.117.camel@ted> (raw)
In-Reply-To: <c49e7e2915d4ade3dd67f706f12b3979a3b5c021.1339740433.git.raj.khem@gmail.com>
On Thu, 2012-06-14 at 23:12 -0700, Khem Raj wrote:
> futimes is not available on uclibc so use utimes
> qsort is also not as expected by sat-solver therefore
> for uclibc we resort to using internal version of
> qsort
>
> Signed-off-by: Khem Raj <raj.khem@gmail.com>
> ---
> .../sat-solver/sat-solver/futimes.patch | 32 ++++++++++++++++++++
> meta/recipes-extended/sat-solver/sat-solver_git.bb | 3 ++
> 2 files changed, 35 insertions(+), 0 deletions(-)
> create mode 100644 meta/recipes-extended/sat-solver/sat-solver/futimes.patch
>
> diff --git a/meta/recipes-extended/sat-solver/sat-solver/futimes.patch b/meta/recipes-extended/sat-solver/sat-solver/futimes.patch
> new file mode 100644
> index 0000000..b24d852
> --- /dev/null
> +++ b/meta/recipes-extended/sat-solver/sat-solver/futimes.patch
> @@ -0,0 +1,32 @@
> +This patch uses utimes instead of futimes for uclibc
> +since futimes is not available
> +
> +Upstream-Status: Pending
> +Signed-off-by: Khem Raj <raj.khem@gmail.com>
> +
> +Index: git/examples/solv.c
> +===================================================================
> +--- git.orig/examples/solv.c 2012-06-01 12:06:22.041552848 -0700
> ++++ git/examples/solv.c 2012-06-01 12:49:17.417677449 -0700
> +@@ -1027,7 +1027,8 @@
> + int flags;
> +
> + cinfo = repo->appdata;
> +- if (!(fp = fopen(calccachepath(repo, repoext), "r")))
> ++ const char* fname = calccachepath(repo, repoext);
> ++ if (!(fp = fopen(fname, "r")))
> + return 0;
> + if (fseek(fp, -sizeof(mycookie), SEEK_END) || fread(mycookie, sizeof(mycookie), 1, fp) != 1)
> + {
> +@@ -1068,7 +1069,11 @@
> + memcpy(cinfo->extcookie, myextcookie, sizeof(myextcookie));
> + }
> + if (mark)
> ++#ifdef __UCLIBC__
> ++ utimes(fname, 0); /* try to set modification time */
> ++#else
> + futimes(fileno(fp), 0); /* try to set modification time */
> ++#endif
> + fclose(fp);
> + return 1;
> + }
> diff --git a/meta/recipes-extended/sat-solver/sat-solver_git.bb b/meta/recipes-extended/sat-solver/sat-solver_git.bb
> index b0382f6..b0daa6a 100644
> --- a/meta/recipes-extended/sat-solver/sat-solver_git.bb
> +++ b/meta/recipes-extended/sat-solver/sat-solver_git.bb
> @@ -20,6 +20,7 @@ SRC_URI = "git://github.com/openSUSE/sat-solver.git;protocol=git \
> file://sat-solver_core.patch \
> file://fix_gcc-4.6.0_compile_issue.patch \
> file://0001-sat_xfopen.c-Forward-port-to-zlib-1.2.6-gzFile.patch \
> + file://futimes.patch \
> "
>
> S = "${WORKDIR}/git"
> @@ -28,6 +29,8 @@ EXTRA_OECMAKE += "-DRPM5=RPM5 -DOE_CORE=OE_CORE"
>
> EXTRA_OECMAKE += " -DLIB=${@os.path.basename('${libdir}')}"
>
> +TUNE_CCARGS_libc-uclibc_append = " -DUSE_OWN_QSORT=1 "
> +
I suspect you mean TUNE_CCARGS_append_libc-uclibc here?
Cheers,
Richard
next prev parent reply other threads:[~2012-06-15 13:06 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-06-15 6:12 [PATCH 0/9 V3] rpm compilation on uclibc Khem Raj
2012-06-15 6:12 ` [PATCH 1/9] uclibc_0.9.33.bb: Upgrade to latest git Khem Raj
2012-06-15 6:12 ` [PATCH 2/9] site/x86_64-linux-uclibc: Cache definitions of guint32/guint64 Khem Raj
2012-06-15 6:12 ` [PATCH 3/9] rpm: Fix compilation on uclibc Khem Raj
2012-06-15 6:12 ` [PATCH 4/9] rpm: Use link time check for libssp Khem Raj
2012-06-15 12:43 ` Richard Purdie
2012-06-15 14:34 ` Khem Raj
2012-09-24 20:36 ` McClintock Matthew-B29882
2012-09-24 21:18 ` Khem Raj
2012-09-24 22:30 ` McClintock Matthew-B29882
2012-06-15 6:12 ` [PATCH 5/9] sat-solver: Fix build on uclibc Khem Raj
2012-06-15 12:55 ` Richard Purdie [this message]
2012-06-15 14:35 ` Khem Raj
2012-06-15 13:07 ` Bernhard Reutner-Fischer
2012-06-15 6:12 ` [PATCH 6/9] libzypp: Fix build with uclibc Khem Raj
2012-06-15 6:12 ` [PATCH 7/9] rpm: pass lrt and lpthread to link step explicitly for uclibc Khem Raj
2012-06-15 6:12 ` [PATCH 8/9] zypper: Fix build on uclibc Khem Raj
2012-06-15 6:12 ` [PATCH 9/9] libzypp: Define OECMAKE_CXX_LINK_FLAGS when compiling for uclibc Khem Raj
2012-06-18 16:48 ` [PATCH 0/9 V3] rpm compilation on uclibc Saul Wold
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1339764954.24333.117.camel@ted \
--to=richard.purdie@linuxfoundation.org \
--cc=openembedded-core@lists.openembedded.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox