From 4e2ab57e3a73f1e11707b3981e78aaba779d8285 Mon Sep 17 00:00:00 2001 From: Jamie Lenehan Date: Tue, 29 May 2007 23:48:37 +0000 Subject: perl 5.8.8: Fix the CFLAGS being used for perl modules. Instead of replacing the CFLAGS from the perl configuration with the OE CFLAGS we prepend the OE CFLAGS. This is needed to ensure that compiler defines (such as _GNU_SOURCE) are correctly definied when building perl modules. This primarily effects modules that link against the core perl library, such as libxml-parser-perl. --- packages/perl/perl-5.8.8/generate-sh.patch | 40 ++++++++++++++++++++++++++---- packages/perl/perl_5.8.8.bb | 2 +- 2 files changed, 36 insertions(+), 6 deletions(-) diff --git a/packages/perl/perl-5.8.8/generate-sh.patch b/packages/perl/perl-5.8.8/generate-sh.patch index 4c2b0bd752..50ce00b42f 100644 --- a/packages/perl/perl-5.8.8/generate-sh.patch +++ b/packages/perl/perl-5.8.8/generate-sh.patch @@ -1,16 +1,46 @@ Use the ld flags from the supplied configuration file. For sh we need the flags that specify to build PIC code so that the shared libraries work. ---- perl-5.8.7/Cross/generate_config_sh~ 2006-09-25 16:34:09.000000000 +1000 -+++ perl-5.8.7/Cross/generate_config_sh 2006-09-25 16:34:09.000000000 +1000 -@@ -19,8 +19,8 @@ +Index: perl-5.8.8/Cross/generate_config_sh +=================================================================== +--- perl-5.8.8.orig/Cross/generate_config_sh 2003-09-05 18:31:08.000000000 +1000 ++++ perl-5.8.8/Cross/generate_config_sh 2007-05-30 09:12:50.000000000 +1000 +@@ -19,10 +19,10 @@ $callbacks->{'ar'} = [\&simple_process, ["AR", "arm-linux-ar"]]; $callbacks->{'archname'} = [\&simple_process, ["SYS", "armv4l-linux"]]; $callbacks->{'cc'} = [\&simple_process, ["CC", "arm-linux-gcc"]]; -$callbacks->{'cccdlflags'} = [\&simple_process, ["CFLAGS", ""]]; -$callbacks->{'ccdlflags'} = [\&simple_process, ["CFLAGS", ""]]; +-$callbacks->{'ccflags'} = [\&simple_process, ["CFLAGS", "-fno-strict-aliasing -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64"]]; +-$callbacks->{'ccflags_uselargefiles'} = [\&simple_process, ["CFLAGS", "-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64"]]; +#$callbacks->{'cccdlflags'} = [\&simple_process, ["CFLAGS", ""]]; +#$callbacks->{'ccdlflags'} = [\&simple_process, ["CFLAGS", ""]]; - $callbacks->{'ccflags'} = [\&simple_process, ["CFLAGS", "-fno-strict-aliasing -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64"]]; - $callbacks->{'ccflags_uselargefiles'} = [\&simple_process, ["CFLAGS", "-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64"]]; ++$callbacks->{'ccflags'} = [\&simple_process_insert, ["CFLAGS", "-fno-strict-aliasing -D_GNU_SOURCE -DTHREADS_HAVE_PIDS -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64"]]; ++$callbacks->{'ccflags_uselargefiles'} = [\&simple_process_insert, ["CFLAGS", "-D_GNU_SOURCE -DTHREADS_HAVE_PIDS -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64"]]; $callbacks->{'ccname'} = [\&simple_process, ["CC", "arm-linux-gcc"]]; + $callbacks->{'cpp'} = [\&simple_process, ["CCP", "arm-linux-cpp"]]; + $callbacks->{'cppflags'} = [\&simple_process, ["CCPFLAGS", "-fno-strict-aliasing"]]; +@@ -105,6 +105,23 @@ + + } + ++# Insert env var into the variables value ++sub simple_process_insert { ++ my $key = shift; ++ my $value = shift; ++ my $envvar = $callbacks->{$key}->[1][0]; ++ ++ if ($ENV{$envvar}) { ++ # Strip quotes from value ++ $value =~ s/^\'//; ++ $value =~ s/\'$//; ++ # Remove -I/usr/local/... from the value ++ $value =~ s#\W-I/usr/local/\w+\W##g; ++ # Prepend env var (OE setting) to value ++ print("$key=\'$ENV{$envvar} $value\'\n"); ++ } ++} ++ + sub library_munge { + my $key = shift; + my $value = shift; diff --git a/packages/perl/perl_5.8.8.bb b/packages/perl/perl_5.8.8.bb index c8e7afebc7..3dfe17cad8 100644 --- a/packages/perl/perl_5.8.8.bb +++ b/packages/perl/perl_5.8.8.bb @@ -5,7 +5,7 @@ LICENSE = "Artistic|GPL" PRIORITY = "optional" # We need gnugrep (for -I) DEPENDS = "virtual/db perl-native grep-native" -PR = "r16" +PR = "r17" # Major part of version PVM = "5.8" -- cgit v1.2.3 From 87fd6c090376dd2a5e54177eaa41bd931007e617 Mon Sep 17 00:00:00 2001 From: Jamie Lenehan Date: Tue, 29 May 2007 23:52:07 +0000 Subject: perl: Bump PR on modules that include shared libraries since these may have been effected by the revent CFLAGS changes to perl 5.8.8. --- packages/perl/libcompress-zlib-perl_1.42.bb | 2 +- packages/perl/libdigest-sha1-perl_2.11.bb | 2 +- packages/perl/libipc-sharelite-perl_0.09.bb | 2 +- packages/perl/liblocale-gettext-perl_1.05.bb | 2 +- packages/perl/libparams-validate-perl_0.86.bb | 2 +- packages/perl/libversion-perl_0.6701.bb | 2 +- packages/perl/libxml-parser-perl_2.34.bb | 2 +- 7 files changed, 7 insertions(+), 7 deletions(-) diff --git a/packages/perl/libcompress-zlib-perl_1.42.bb b/packages/perl/libcompress-zlib-perl_1.42.bb index f30692f576..3447db0a5a 100644 --- a/packages/perl/libcompress-zlib-perl_1.42.bb +++ b/packages/perl/libcompress-zlib-perl_1.42.bb @@ -1,7 +1,7 @@ DESCRIPTION = "Compress::Zlib - Interface to zlib compression library" SECTION = "libs" LICENSE = "Artistic|GPL" -PR = "r7" +PR = "r8" SRC_URI = "http://search.cpan.org/CPAN/authors/id/P/PM/PMQS/Compress-Zlib-${PV}.tar.gz" diff --git a/packages/perl/libdigest-sha1-perl_2.11.bb b/packages/perl/libdigest-sha1-perl_2.11.bb index fa9f2bcbcc..c851ec87c0 100644 --- a/packages/perl/libdigest-sha1-perl_2.11.bb +++ b/packages/perl/libdigest-sha1-perl_2.11.bb @@ -1,7 +1,7 @@ DESCRIPTION = "Digest::SHA1 - Perl interface to the SHA-1 algorithm" SECTION = "libs" LICENSE = "Artistic|GPL" -PR = "r11" +PR = "r12" SRC_URI = "http://search.cpan.org/CPAN/authors/id/G/GA/GAAS/Digest-SHA1-${PV}.tar.gz" diff --git a/packages/perl/libipc-sharelite-perl_0.09.bb b/packages/perl/libipc-sharelite-perl_0.09.bb index d56f0a99d4..5c2f7fcae2 100644 --- a/packages/perl/libipc-sharelite-perl_0.09.bb +++ b/packages/perl/libipc-sharelite-perl_0.09.bb @@ -1,7 +1,7 @@ DESCRIPTION = "IPC::ShareLite - Light-weight interface to shared memory" SECTION = "libs" LICENSE = "Artistic|GPL" -PR = "r11" +PR = "r12" SRC_URI = "http://search.cpan.org/CPAN/authors/id/M/MA/MAURICE/IPC-ShareLite-${PV}.tar.gz" diff --git a/packages/perl/liblocale-gettext-perl_1.05.bb b/packages/perl/liblocale-gettext-perl_1.05.bb index f9490c0c41..621243cd8f 100644 --- a/packages/perl/liblocale-gettext-perl_1.05.bb +++ b/packages/perl/liblocale-gettext-perl_1.05.bb @@ -2,7 +2,7 @@ DESCRIPTION = "Locale::gettext - message handling functions" SECTION = "libs" LICENSE = "Artistic|GPL" DEPENDS = "virtual/libintl" -PR = "r7" +PR = "r8" SRC_URI = "http://search.cpan.org/CPAN/authors/id/P/PV/PVANDRY/gettext-${PV}.tar.gz" diff --git a/packages/perl/libparams-validate-perl_0.86.bb b/packages/perl/libparams-validate-perl_0.86.bb index f3a11d2d60..db1a7bd812 100644 --- a/packages/perl/libparams-validate-perl_0.86.bb +++ b/packages/perl/libparams-validate-perl_0.86.bb @@ -1,7 +1,7 @@ DESCRIPTION = "Params::Validate - Validate method/function parameters" SECTION = "libs" LICENSE = "Artistic|GPL" -PR = "r11" +PR = "r12" SRC_URI = "http://search.cpan.org/CPAN/authors/id/D/DR/DROLSKY/Params-Validate-${PV}.tar.gz" diff --git a/packages/perl/libversion-perl_0.6701.bb b/packages/perl/libversion-perl_0.6701.bb index 1081d98135..246a663d10 100644 --- a/packages/perl/libversion-perl_0.6701.bb +++ b/packages/perl/libversion-perl_0.6701.bb @@ -1,7 +1,7 @@ DESCRIPTION = "version - Perl extension for Version Objects" SECTION = "libs" LICENSE = "Artistic|GPL" -PR = "r6" +PR = "r7" SRC_URI = "http://search.cpan.org/CPAN/authors/id/J/JP/JPEACOCK/version-${PV}.tar.gz" diff --git a/packages/perl/libxml-parser-perl_2.34.bb b/packages/perl/libxml-parser-perl_2.34.bb index b1676bb2fd..52adf2b2bf 100644 --- a/packages/perl/libxml-parser-perl_2.34.bb +++ b/packages/perl/libxml-parser-perl_2.34.bb @@ -1,7 +1,7 @@ SECTION = "libs" LICENSE = "Artistic" DEPENDS += "expat-native" -PR = "r7" +PR = "r8" SRC_URI = "http://www.cpan.org/modules/by-module/XML/XML-Parser-${PV}.tar.gz" -- cgit v1.2.3 From f03de6e7b9bf301212f7219d32d17b74ef0c9a5d Mon Sep 17 00:00:00 2001 From: Jamie Lenehan Date: Wed, 30 May 2007 00:01:50 +0000 Subject: perl: Add some more modules which I've been using locally incase someone else happens to want to use them. --- .../perl/libextutils-depends-perl-native_0.205.bb | 5 ++++ packages/perl/libextutils-depends-perl_0.205.bb | 10 +++++++ .../perl/libextutils-pkgconfig-perl-native_1.07.bb | 5 ++++ packages/perl/libextutils-pkgconfig-perl_1.07.bb | 10 +++++++ packages/perl/libhtml-mason-perl_1.35.bb | 35 ++++++++++++++++++++++ 5 files changed, 65 insertions(+) create mode 100644 packages/perl/libextutils-depends-perl-native_0.205.bb create mode 100644 packages/perl/libextutils-depends-perl_0.205.bb create mode 100644 packages/perl/libextutils-pkgconfig-perl-native_1.07.bb create mode 100644 packages/perl/libextutils-pkgconfig-perl_1.07.bb create mode 100644 packages/perl/libhtml-mason-perl_1.35.bb diff --git a/packages/perl/libextutils-depends-perl-native_0.205.bb b/packages/perl/libextutils-depends-perl-native_0.205.bb new file mode 100644 index 0000000000..e0216cbfb5 --- /dev/null +++ b/packages/perl/libextutils-depends-perl-native_0.205.bb @@ -0,0 +1,5 @@ +SECTION = "libs" + +inherit native + +require libextutils-depends-perl_${PV}.bb diff --git a/packages/perl/libextutils-depends-perl_0.205.bb b/packages/perl/libextutils-depends-perl_0.205.bb new file mode 100644 index 0000000000..274550dbd3 --- /dev/null +++ b/packages/perl/libextutils-depends-perl_0.205.bb @@ -0,0 +1,10 @@ +DESCRIPTION = "ExtUtils::Depends - Easily build XS extensions that depend on XS extensions" +SECTION = "libs" +LICENSE = "Artistic|GPL" +PR = "r2" + +SRC_URI = "http://search.cpan.org/CPAN/authors/id/R/RM/RMCFARLA/Gtk2-Perl/ExtUtils-Depends-${PV}.tar.gz" + +S = "${WORKDIR}/ExtUtils-Depends-${PV}" + +inherit cpan diff --git a/packages/perl/libextutils-pkgconfig-perl-native_1.07.bb b/packages/perl/libextutils-pkgconfig-perl-native_1.07.bb new file mode 100644 index 0000000000..b5cd092dbd --- /dev/null +++ b/packages/perl/libextutils-pkgconfig-perl-native_1.07.bb @@ -0,0 +1,5 @@ +SECTION = "libs" + +inherit native + +require libextutils-pkgconfig-perl_${PV}.bb diff --git a/packages/perl/libextutils-pkgconfig-perl_1.07.bb b/packages/perl/libextutils-pkgconfig-perl_1.07.bb new file mode 100644 index 0000000000..e0b807f374 --- /dev/null +++ b/packages/perl/libextutils-pkgconfig-perl_1.07.bb @@ -0,0 +1,10 @@ +DESCRIPTION = "ExtUtils::PkgConfig - simplistic interface to pkg-config" +SECTION = "libs" +LICENSE = "Artistic|GPL" +PR = "r3" + +SRC_URI = "http://search.cpan.org/CPAN/authors/id/R/RM/RMCFARLA/Gtk2-Perl/ExtUtils-PkgConfig-${PV}.tar.gz" + +S = "${WORKDIR}/ExtUtils-PkgConfig-${PV}" + +inherit cpan diff --git a/packages/perl/libhtml-mason-perl_1.35.bb b/packages/perl/libhtml-mason-perl_1.35.bb new file mode 100644 index 0000000000..7b6ede5d49 --- /dev/null +++ b/packages/perl/libhtml-mason-perl_1.35.bb @@ -0,0 +1,35 @@ +SECTION = "libs" +LICENSE = "Artistic|GPL" +DEPENDS = "libexception-class-perl-native libparams-validate-perl-native \ + libcache-cache-perl-native libclass-container-perl-native" +RDEPENDS_${PN} = "libexception-class-perl libparams-validate-perl \ + libcache-cache-perl libclass-container-perl perl-module-strict \ + perl-module-warnings perl-module-file-basename perl-module-file-path \ + perl-module-file-spec perl-module-file-spec-unix perl-module-file-temp \ + perl-module-carp-heavy perl-module-io-handle perl-module-io \ + perl-module-exporter-heavy perl-module-cwd perl-module-scalar-util \ + perl-module-list-util perl-module-bytes perl-module-file-glob \ + perl-module-data-dumper" +PR = "r0" + +SRC_URI = "http://search.cpan.org/CPAN/authors/id/D/DR/DROLSKY/HTML-Mason-${PV}.tar.gz" + +S = "${WORKDIR}/HTML-Mason-${PV}" + +inherit cpan_build + +do_install_append () { + # Fix up paths to the perl interpreter + for i in ${D}${bindir}/*.pl; do + sed -i -e "s#${STAGING_BINDIR}/perl#${bindir}/perl#g" $i + done + + # Install the html documentation and example files + install -m 0755 -d ${D}${docdir}/${PN}/html \ + ${D}${docdir}/${PN}/examples/samples \ + ${D}${docdir}/${PN}/examples/eg + cp -pRP ${S}/htdocs ${D}${docdir}/${PN}/html + cp -pRP ${S}/eg ${D}${docdir}/${PN}/examples/eg + cp -pRP ${S}/samples ${D}${docdir}/${PN}/examples/samples +} + -- cgit v1.2.3