public inbox for openembedded-core@lists.openembedded.org
 help / color / mirror / Atom feed
* [PATCH] cpan_build: Fix cmaker Build.PL module builds
@ 2013-01-19 23:48 Richard Purdie
  0 siblings, 0 replies; only message in thread
From: Richard Purdie @ 2013-01-19 23:48 UTC (permalink / raw)
  To: openembedded-core

Certain cpan Build.PL based modules were failing to build due to
the host's config information being used instead of the targets.

This patch sets the appropriate variables to ensure the modules
get the correct configuration from the target config_heavy.pl script.

It also ensures the linker is CCLD, not LD since the LDFLAGS contain
-Wl,XXX options and build failures result if LD is used.

libencode-detect-perl is a module which tests this class extensively.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
diff --git a/meta/classes/cpan_build.bbclass b/meta/classes/cpan_build.bbclass
index 78592be..eaba40a 100644
--- a/meta/classes/cpan_build.bbclass
+++ b/meta/classes/cpan_build.bbclass
@@ -1,7 +1,12 @@
 #
 # This is for perl modules that use the new Build.PL build system
 #
-inherit cpan-base
+inherit cpan-base perlnative
+
+# Env var which tells perl if it should use host (no) or target (yes) settings
+export PERLCONFIGTARGET = "${@is_target(d)}"
+export PERL_ARCHLIB = "${STAGING_LIBDIR}${PERL_OWN_DIR}/perl/${@get_perl_version(d)}"
+export LD = "${CCLD}"
 
 #
 # We also need to have built libmodule-build-perl-native for





^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2013-01-20  0:03 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-01-19 23:48 [PATCH] cpan_build: Fix cmaker Build.PL module builds Richard Purdie

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox