sanity.bbclass: allow dash to be used as /bin/sh, but print a warning
[vuplus_openembedded] / classes / cpan-base.bbclass
index a5fdb33..19d431c 100644 (file)
@@ -4,13 +4,13 @@
 #
 FILES_${PN} += "${libdir}/perl5 ${datadir}/perl5"
 
-DEPENDS  += "perl perl-native"
-RDEPENDS += "perl"
+DEPENDS  += "${@["perl", "perl-native"][(bb.data.inherits_class('native', d))]}"
+RDEPENDS  += "${@["perl", ""][(bb.data.inherits_class('native', d))]}"
 
 # Determine the staged version of perl from the perl configuration file
 def get_perl_version(d):
        import os, bb, re
-       cfg = bb.data.expand('${STAGING_DIR}/${HOST_SYS}/perl/config.sh', d)
+       cfg = bb.data.expand('${STAGING_DIR_HOST}/perl/config.sh', d)
        try:
                f = open(cfg, 'r')
        except IOError: