summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Olbrich <m.olbrich@pengutronix.de>2013-05-27 10:06:40 +0200
committerMichael Olbrich <m.olbrich@pengutronix.de>2013-06-03 12:21:39 +0200
commit2cf310a83bad2b6cd6321131f81051d720bb9539 (patch)
tree4e40a0e627c61f7dfb382b27c130542afbc0a77d
parent920db42c91d2c2b5e59118ff9b492e0c2da18fdf (diff)
downloadptxdist-2cf310a83bad2b6cd6321131f81051d720bb9539.tar.gz
ptxdist-2cf310a83bad2b6cd6321131f81051d720bb9539.tar.xz
host-system-perl: new package
This is a generic check for the system perl. Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
-rw-r--r--rules/host-system-perl.in12
-rw-r--r--rules/host-system-perl.make34
2 files changed, 46 insertions, 0 deletions
diff --git a/rules/host-system-perl.in b/rules/host-system-perl.in
new file mode 100644
index 000000000..fc487ced8
--- /dev/null
+++ b/rules/host-system-perl.in
@@ -0,0 +1,12 @@
+## SECTION=hosttools_noprompt
+
+config HOST_SYSTEM_PERL
+ tristate
+
+if HOST_SYSTEM_PERL
+
+config HOST_SYSTEM_PERL_XMLPARSER
+ bool
+
+endif
+
diff --git a/rules/host-system-perl.make b/rules/host-system-perl.make
new file mode 100644
index 000000000..8a7b33cf0
--- /dev/null
+++ b/rules/host-system-perl.make
@@ -0,0 +1,34 @@
+# -*-makefile-*-
+#
+# Copyright (C) 2013 by Michael Olbrich <m.olbrich@pengutronix.de>
+#
+# See CREDITS for details about who has contributed to this project.
+#
+# For further information about the PTXdist project and license conditions
+# see the README file.
+#
+
+#
+# We provide this package
+#
+PACKAGES-$(PTXCONF_HOST_SYSTEM_PERL) += host-system-perl
+
+# ----------------------------------------------------------------------------
+# Prepare
+# ----------------------------------------------------------------------------
+
+$(STATEDIR)/host-system-perl.prepare:
+ @$(call targetinfo)
+ @echo "Checking for Perl ..."
+ @perl -v >/dev/null 2>&1 || \
+ ptxd_bailout "'perl' not found! Please install.";
+ifdef PTXCONF_HOST_SYSTEM_PERL_XMLPARSER
+ @echo "Checking for Perl: XML::Parser"
+ @perl -e "require XML::Parser" 2>/dev/null || \
+ ptxd_bailout "XML::Parser perl module is required. \
+ Please install libxml-parser-perl (debian)."
+endif
+ @echo
+ @$(call touch)
+
+# vim: syntax=make