mirror of
https://github.com/yann64/haikuports.git
synced 2026-03-19 01:46:00 +01:00
x86_64 is used as a baseline: the "x86_64" entry, whatever status it has, is transformed into "all", and then the other entries in ARCHITECTURES either dropped or rearranged appropriately.
93 lines
2.2 KiB
Bash
93 lines
2.2 KiB
Bash
SUMMARY="Tool and library to extract CAB files from InstallShield installers"
|
|
DESCRIPTION="Unshield extracts CAB files from InstallShield installers, \
|
|
used to install software on Microsoft Windows based machines."
|
|
HOMEPAGE="https://github.com/twogood/unshield"
|
|
COPYRIGHT="2017 David Eriksson"
|
|
LICENSE="MIT"
|
|
REVISION="2"
|
|
SOURCE_URI="https://github.com/twogood/unshield/archive/$portVersion.tar.gz"
|
|
CHECKSUM_SHA256="aa8c978dc0eb1158d266eaddcd1852d6d71620ddfc82807fe4bf2e19022b7bab"
|
|
SOURCE_FILENAME="unshield-$portVersion.tar.gz"
|
|
|
|
ARCHITECTURES="all !x86_gcc2"
|
|
SECONDARY_ARCHITECTURES="x86"
|
|
|
|
libVersion="0.0.0"
|
|
libVersionCompat="$libVersion compat >= ${libVersion%%.*}"
|
|
|
|
PROVIDES="
|
|
unshield$secondaryArchSuffix = $portVersion
|
|
cmd:unshield$secondaryArchSuffix = $portVersion
|
|
lib:libunshield$secondaryArchSuffix = $libVersionCompat
|
|
"
|
|
REQUIRES="
|
|
haiku$secondaryArchSuffix
|
|
lib:libcrypto$secondaryArchSuffix
|
|
lib:libiconv$secondaryArchSuffix
|
|
lib:libz$secondaryArchSuffix
|
|
"
|
|
|
|
PROVIDES_devel="
|
|
unshield${secondaryArchSuffix}_devel = $portVersion
|
|
devel:libunshield$secondaryArchSuffix = $libVersionCompat
|
|
"
|
|
REQUIRES_devel="
|
|
unshield$secondaryArchSuffix == $portVersion base
|
|
"
|
|
|
|
BUILD_REQUIRES="
|
|
haiku${secondaryArchSuffix}_devel
|
|
devel:libcrypto$secondaryArchSuffix
|
|
devel:libiconv$secondaryArchSuffix
|
|
devel:libz$secondaryArchSuffix
|
|
"
|
|
BUILD_PREREQUIRES="
|
|
cmd:c++$secondaryArchSuffix
|
|
cmd:cc$secondaryArchSuffix
|
|
cmd:cmake
|
|
cmd:make
|
|
"
|
|
|
|
TEST_REQUIRES="
|
|
cmd:curl
|
|
cmd:diff
|
|
cmd:find
|
|
cmd:unzip
|
|
cmd:xargs
|
|
"
|
|
|
|
BUILD()
|
|
{
|
|
cmake . \
|
|
$cmakeDirArgs \
|
|
-DCMAKE_BUILD_TYPE=Release \
|
|
-DCMAKE_EXE_LINKER_FLAGS="-liconv"
|
|
make $jobArgs
|
|
}
|
|
|
|
INSTALL()
|
|
{
|
|
make install
|
|
|
|
install -d -m 755 "$docDir" "$manDir" "$dataDir/expander/rules"
|
|
install -t "$docDir" ChangeLog
|
|
|
|
mv "$dataDir/man/man1" "$manDir/man1"
|
|
rm -rf "$dataDir/man"
|
|
|
|
cat > "$dataDir/expander/rules/unshield-expander-rules" << EOF
|
|
"application/x-installshield-cab" .cab "unshield$secondaryArchSuffix l %s" "unshield$secondaryArchSuffix x %s"
|
|
EOF
|
|
|
|
prepareInstalledDevelLib libunshield
|
|
fixPkgconfig
|
|
packageEntries devel "$developDir"
|
|
}
|
|
|
|
# The scripts called by run-tests.sh download a few files from the internet.
|
|
# The total size is currently around 10 MB.
|
|
TEST()
|
|
{
|
|
LC_ALL=en_US UNSHIELD="$sourceDir"/src/unshield ./run-tests.sh
|
|
}
|