From 94207468e3fc041d4063f4935cb5a91a4bb3195e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Joachim=20Mairb=C3=B6ck?= Date: Sun, 5 Jan 2025 11:26:44 +0100 Subject: [PATCH] extutils_libbuilder: new perl module recipe This is another build time dependency of Text::BibTeX. --- .../extutils_libbuilder-0.08.recipe | 61 +++++++++++++++++++ .../patches/extutils_libbuilder-0.08.patchset | 24 ++++++++ 2 files changed, 85 insertions(+) create mode 100644 dev-perl/extutils_libbuilder/extutils_libbuilder-0.08.recipe create mode 100644 dev-perl/extutils_libbuilder/patches/extutils_libbuilder-0.08.patchset diff --git a/dev-perl/extutils_libbuilder/extutils_libbuilder-0.08.recipe b/dev-perl/extutils_libbuilder/extutils_libbuilder-0.08.recipe new file mode 100644 index 000000000..8760f1f2f --- /dev/null +++ b/dev-perl/extutils_libbuilder/extutils_libbuilder-0.08.recipe @@ -0,0 +1,61 @@ +SUMMARY="A tool to build C libraries" +DESCRIPTION="Some Perl modules need to ship C libraries together with their Perl code. Although \ +there are mechanisms to compile and link (or glue) C code in your Perl programs, there isn't a \ +clear method to compile standard, self-contained C libraries. +This module main goal is to help in that task." +HOMEPAGE="https://metacpan.org/pod/ExtUtils::LibBuilder" +COPYRIGHT="2010 Alberto Simoes" +LICENSE="Artistic" +REVISION="1" +SOURCE_URI="https://cpan.metacpan.org/authors/id/A/AM/AMBS/ExtUtils-LibBuilder-$portVersion.tar.gz" +CHECKSUM_SHA256="c51171e06de53039f0bca1d97a6471ec37941ff59e8a3d1cb170ebdd2573b5d2" +SOURCE_DIR="ExtUtils-LibBuilder-$portVersion" +PATCHES="extutils_libbuilder-$portVersion.patchset" + +ARCHITECTURES="any" + +PROVIDES=" + extutils_libbuilder = $portVersion + " +REQUIRES=" + haiku + vendor_perl + " + +BUILD_REQUIRES=" + haiku_devel + module_build + " +BUILD_PREREQUIRES=" + cmd:perl + " + +if [ "$targetArchitecture" = x86_gcc2 ]; then + TEST_REQUIRES=" + cmd:gcc_x86 + " +else + TEST_REQUIRES=" + cmd:gcc + " +fi + +BUILD() +{ + perl Build.PL --prefix=$prefix --installdirs=vendor + ./Build +} + +INSTALL() +{ + ./Build pure_install + + # remove architecture-specific files + cd $prefix + rm -r $(perl -V:vendorarch | cut -d\' -f2 | cut -d/ -f5-) + # cut extracts the quoted string and strips the prefix (which is perl's and not ours) +} + +TEST() { + ./Build test +} diff --git a/dev-perl/extutils_libbuilder/patches/extutils_libbuilder-0.08.patchset b/dev-perl/extutils_libbuilder/patches/extutils_libbuilder-0.08.patchset new file mode 100644 index 000000000..017a4d0f0 --- /dev/null +++ b/dev-perl/extutils_libbuilder/patches/extutils_libbuilder-0.08.patchset @@ -0,0 +1,24 @@ +From e9827c7fd56b1f46940a5dea073c6ca002a59bb6 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Joachim=20Mairb=C3=B6ck?= +Date: Sat, 4 Jan 2025 19:58:34 +0100 +Subject: Haiku support in test + + +diff --git a/t/01-simple.t b/t/01-simple.t +index 6b7e7ac..361bfdc 100644 +--- a/t/01-simple.t ++++ b/t/01-simple.t +@@ -71,6 +71,10 @@ elsif ($^O =~ /aix/i) { + my $oldlibpath = $ENV{LIBPATH} || '/lib:/usr/lib'; + $ENV{LIBPATH} = ".:$oldlibpath"; + } ++elsif ($^O =~ /haiku/i) { ++ my $oldlibpath = $ENV{LIBRARY_PATH} || '/boot/system/lib:/boot/system/lib/x86'; ++ $ENV{LIBRARY_PATH} = ".:$oldlibpath"; ++} + + my $P; + $P = "./" unless $^O =~ /mswin32/i; +-- +2.45.2 +