summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--mk/perl.mk17
-rw-r--r--mk/pkg-bottom.mk7
-rw-r--r--package/p5-xml-parser/Makefile (renamed from package/p5-XML-Parser/Makefile)18
3 files changed, 29 insertions, 13 deletions
diff --git a/mk/perl.mk b/mk/perl.mk
index 34b4742f9..dc16bcb00 100644
--- a/mk/perl.mk
+++ b/mk/perl.mk
@@ -1,2 +1,17 @@
PERL_VERSION=5.18.1
-PERL_SITEDIR:=/usr/lib/perl5/site_perl/$(PERL_VERSION)/$(ADK_TARGET_CPU_ARCH)-linux
+PERL_ARCHNAME:=$(ADK_TARGET_CPU_ARCH)-linux
+PERL_SITEDIR:=/usr/lib/perl5/site_perl/$(PERL_VERSION)
+PERL_ENV:= AR="$(TARGET_AR)" \
+ FULL_AR="$(TARGET_AR)" \
+ CC="$(TARGET_CC)" \
+ CCFLAGS="$(TARGET_CFLAGS)" \
+ LD="$(TARGET_CC)" \
+ LDDLFLAGS="-shared $(TARGET_LDFLAGS)" \
+ LDFLAGS="$(TARGET_LDFLAGS)" \
+ PERL_INC=$(STAGING_TARGET_DIR)/usr/lib/perl5/$(PERL_VERSION)/$(PERL_ARCHNAME)/CORE \
+ DESTDIR=$(WRKINST) \
+ INSTALLDIRS=vendor \
+ INSTALLVENDORLIB=$(PERL_SITEDIR) \
+ INSTALLVENDORARCH=$(PERL_SITEDIR)/$(PERL_ARCHNAME) \
+ INSTALLVENDORBIN=/usr/bin \
+ INSTALLVENDORSCRIPT=/usr/bin
diff --git a/mk/pkg-bottom.mk b/mk/pkg-bottom.mk
index 2972ffcfe..cc17c1202 100644
--- a/mk/pkg-bottom.mk
+++ b/mk/pkg-bottom.mk
@@ -53,6 +53,13 @@ else ifneq ($(filter minimal,${CONFIG_STYLE}),)
env ${CONFIGURE_ENV} \
${BASH} ${WRKSRC}/${CONFIGURE_PROG} \
${CONFIGURE_ARGS} $(MAKE_TRACE)
+else ifneq ($(filter perl,${CONFIG_STYLE}),)
+ @$(CMD_TRACE) "configuring perl module... "
+ cd ${WRKBUILD}; \
+ PATH='${HOST_PATH}' \
+ PERL_MM_USE_DEFAULT=1 \
+ PERL_AUTOINSTALL=--skipdeps \
+ perl Makefile.PL $(PERL_ENV)
else ifeq ($(strip ${CONFIG_STYLE}),)
@$(CMD_TRACE) "configuring... "
cd ${WRKBUILD}; rm -f config.{cache,status}; \
diff --git a/package/p5-XML-Parser/Makefile b/package/p5-xml-parser/Makefile
index f2f402a21..00a6f44e7 100644
--- a/package/p5-XML-Parser/Makefile
+++ b/package/p5-xml-parser/Makefile
@@ -3,18 +3,16 @@
include $(TOPDIR)/rules.mk
-PKG_NAME:= p5-XML-Parser
+PKG_NAME:= p5-xml-parser
PKG_VERSION:= 2.40
PKG_RELEASE:= 2
PKG_MD5SUM:= c66e9adba003d0667cc40115ccd837a5
PKG_DESCR:= xml parser
PKG_SECTION:= dev/perl
PKG_DEPENDS:= perl libexpat
-PKG_BUILDDEP:= perl-host expat
+PKG_BUILDDEP:= perl expat
PKG_SITES:= http://search.cpan.org/CPAN/authors/id/C/CH/CHORNY/
-PKG_CFLINE_P5_XML_PARSER:= depends on ADK_BROKEN
-
DISTFILES:= XML-Parser-${PKG_VERSION}.tar.gz
WRKDIST= ${WRKDIR}/XML-Parser-${PKG_VERSION}
@@ -22,16 +20,12 @@ include $(TOPDIR)/mk/package.mk
$(eval $(call PKG_template,P5_XML_PARSER,p5-xml-parser,$(PKG_VERSION)-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
-CONFIG_STYLE:= manual
-XAKE_FLAGS+= CC="$(TARGET_CC)" CCFLAGS="$(TARGET_CFLAGS)"
-
include $(TOPDIR)/mk/perl.mk
-pre-build:
- (cd ${WRKSRC} && PATH='${HOST_PATH}' \
- perl-host Makefile.PL \
- EXPATLIBPATH=${STAGING_TARGET_DIR}/usr/lib \
- EXPATINCPATH=${STAGING_TARGET_DIR}/usr/include)
+PERL_ENV+= EXPATLIBPATH=${STAGING_TARGET_DIR}/usr/lib \
+ EXPATINCPATH=${STAGING_TARGET_DIR}/usr/include
+CONFIG_STYLE:= perl
+XAKE_FLAGS+= $(PERL_ENV)
p5-xml-parser-install:
$(INSTALL_DIR) $(IDIR_P5_XML_PARSER)$(PERL_SITEDIR)