datetime_format_strptime: new perl module recipe

This commit is contained in:
Joachim Mairböck
2024-11-30 15:17:01 +01:00
parent 0a80160924
commit ece8c2b7c7

View File

@@ -0,0 +1,57 @@
SUMMARY="Parse and format strp and strf time patterns"
DESCRIPTION="This module implements most of strptime(3), the POSIX function that is the reverse \
of strftime(3), for DateTime. While strftime takes a DateTime and a pattern and returns a string, \
strptime takes a string and a pattern and returns the DateTime object associated."
HOMEPAGE="https://metacpan.org/pod/DateTime::Format::Strptime"
COPYRIGHT="2015 - 2021 by Dave Rolsky"
LICENSE="Artistic"
REVISION="1"
SOURCE_URI="https://cpan.metacpan.org/authors/id/D/DR/DROLSKY/DateTime-Format-Strptime-$portVersion.tar.gz"
CHECKSUM_SHA256="701e46802c86ed4d88695c1a6dacbbe90b3390beeb794f387e7c792300037579"
SOURCE_DIR="DateTime-Format-Strptime-$portVersion"
ARCHITECTURES="any"
PROVIDES="
datetime_format_strptime = $portVersion
"
REQUIRES="
haiku
datetime
vendor_perl
"
BUILD_REQUIRES="
haiku_devel
"
BUILD_PREREQUIRES="
cmd:make
cmd:perl
"
TEST_REQUIRES="
datetime
test_fatal
test_warnings
"
BUILD()
{
perl Makefile.PL PREFIX=$prefix
make
}
INSTALL()
{
make 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()
{
make test
}