From: Hongxu Jia <hongxu.jia@windriver.com>
To: <openembedded-devel@lists.openembedded.org>
Subject: Re: [PATCH 3/3][meta-perl] libnet-libidn-perl: add recipe
Date: Mon, 14 Jul 2014 09:50:41 +0800 [thread overview]
Message-ID: <53C33771.5040805@windriver.com> (raw)
In-Reply-To: <1405058915-12198-1-git-send-email-rongqing.li@windriver.com>
Acked-by: Hongxu Jia <hongxu.jia@windriver.com>
//Hongxu
On 07/11/2014 02:08 PM, rongqing.li@windriver.com wrote:
> From: Roy Li <rongqing.li@windriver.com>
>
> Signed-off-by: Roy Li <rongqing.li@windriver.com>
> ---
> .../libidn-wr-cross-compile.patch | 49 ++++++++++++++++++++
> .../recipes-perl/libnet/libnet-libidn-perl_0.12.bb | 34 ++++++++++++++
> 2 files changed, 83 insertions(+)
> create mode 100644 meta-perl/recipes-perl/libnet/libnet-libidn-perl-0.12/libidn-wr-cross-compile.patch
> create mode 100644 meta-perl/recipes-perl/libnet/libnet-libidn-perl_0.12.bb
>
> diff --git a/meta-perl/recipes-perl/libnet/libnet-libidn-perl-0.12/libidn-wr-cross-compile.patch b/meta-perl/recipes-perl/libnet/libnet-libidn-perl-0.12/libidn-wr-cross-compile.patch
> new file mode 100644
> index 0000000..679caa3
> --- /dev/null
> +++ b/meta-perl/recipes-perl/libnet/libnet-libidn-perl-0.12/libidn-wr-cross-compile.patch
> @@ -0,0 +1,49 @@
> +perl-Net-LibIDN: cross-compile
> +
> +Upstream-Status: Pending
> +
> +Add support for cross-compile allowing the compiler binary to be
> +specified into the perl Makefile instead of using the default 'gcc'.
> +
> +Signed-off-by: Greg Moffatt <greg.moffatt@windriver.com>
> +---
> +
> +--- perl-Net-LibIDN-0.12.orig/Makefile.PL 2009-02-26 07:09:45.000000000 -0500
> ++++ perl-Net-LibIDN-0.12/Makefile.PL 2010-10-19 09:34:22.811173965 -0400
> +@@ -9,6 +9,7 @@
> + my $options;
> + my $testno=1;
> + my %MakeParams = InitMakeParams();
> ++my $compiler;
> +
> + WriteMakefile(%MakeParams);
> +
> +@@ -44,7 +45,8 @@
> + (
> + "with-libidn=s" => \$libdir,
> + "with-libidn-inc=s" => \$incdir,
> +- "disable-tld" => \$disable_tld
> ++ "disable-tld" => \$disable_tld,
> ++ "compiler=s" => \$compiler
> + );
> +
> + if ($libdir)
> +@@ -165,12 +167,17 @@
> + return 0;
> + }
> +
> +- foreach my $cc (qw/cc gcc/)
> ++ foreach my $cc ($compiler, qw/cc gcc/)
> + {
> + unlink($test);
> + system "$cc $cflags -o $test $test.c $ldflags";
> + next if ($? >> 8);
> +
> ++ if ($compiler == $cc)
> ++ {
> ++ return 1;
> ++ }
> ++
> + if (open(FILE, "./$test|"))
> + {
> + my $match;
> diff --git a/meta-perl/recipes-perl/libnet/libnet-libidn-perl_0.12.bb b/meta-perl/recipes-perl/libnet/libnet-libidn-perl_0.12.bb
> new file mode 100644
> index 0000000..42b213d
> --- /dev/null
> +++ b/meta-perl/recipes-perl/libnet/libnet-libidn-perl_0.12.bb
> @@ -0,0 +1,34 @@
> +SUMMARY = "Net::LibIDN - Perl bindings for GNU Libidn"
> +DESCRIPTION = "\
> +Provides bindings for GNU Libidn, a C library for handling Internationalized \
> +Domain Names according to IDNA (RFC 3490), in a way very much inspired by \
> +Turbo Fredriksson's PHP-IDN. \
> +"
> +SECTION = "libs"
> +LICENSE = "Artistic-1.0 | GPLv1+"
> +HOMEPAGE = "http://search.cpan.org/dist/Net-LibIDN/"
> +DEPENDS += "libidn"
> +# We must need eglibc-gconvs to enable charset related functions,
> +# such as Net::LibIDN::idn_to_ascii().
> +RDEPENDS_${PN} += "eglibc-gconvs"
> +
> +SRC_URI = "http://search.cpan.org/CPAN/authors/id/T/TH/THOR/Net-LibIDN-${PV}.tar.gz"
> +SRC_URI[md5sum] = "c3e4de2065009d67bcb1df0afb473e12"
> +SRC_URI[sha256sum] = "2f8acc9442b3866ec7dc63cd449fc693ae3e930d5d3e5e9430fbb6f393bdbb17"
> +
> +SRC_URI += "file://libidn-wr-cross-compile.patch"
> +
> +LIC_FILES_CHKSUM = "file://README;beginline=42;endline=92;md5=3374ea0369ca3ead6047520477a43147"
> +
> +S = "${WORKDIR}/Net-LibIDN-${PV}"
> +
> +EXTRA_CPANFLAGS = "--with-libidn=${STAGING_LIBDIR} --with-libidn-inc=${STAGING_INCDIR} --compiler='${CC}'"
> +EXTRA_CPANFLAGS += "--disable-tld"
> +
> +inherit cpan
> +
> +FILES_${PN}-dbg += "${libdir}/perl/vendor_perl/*/auto/Net/LibIDN/.debug/"
> +
> +do_configure_prepend() {
> + rm -rf ${S}/.pc/
> +}
prev parent reply other threads:[~2014-07-14 1:50 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-11 6:08 [PATCH 3/3][meta-perl] libnet-libidn-perl: add recipe rongqing.li
2014-07-14 1:50 ` Hongxu Jia [this message]
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=53C33771.5040805@windriver.com \
--to=hongxu.jia@windriver.com \
--cc=openembedded-devel@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.