mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-23 04:00:05 +02:00
uchardet: create recipe. (#452)
This commit is contained in:
19
dev-libs/uchardet/patches/uchardet-0.0.6.patchset
Normal file
19
dev-libs/uchardet/patches/uchardet-0.0.6.patchset
Normal file
@@ -0,0 +1,19 @@
|
||||
From 63d9eeb76747d6afda3f23cfb80eee99e021c973 Mon Sep 17 00:00:00 2001
|
||||
From: fbrosson <fbrosson@localhost>
|
||||
Date: Wed, 20 Jul 2016 00:02:46 +0000
|
||||
Subject: Add missing prefix and exec_prefix in uchardet.pc.in.
|
||||
|
||||
|
||||
diff --git a/uchardet.pc.in b/uchardet.pc.in
|
||||
index 24fdd01..9c5a4d0 100644
|
||||
--- a/uchardet.pc.in
|
||||
+++ b/uchardet.pc.in
|
||||
@@ -1,3 +1,5 @@
|
||||
+prefix=@CMAKE_INSTALL_PREFIX@
|
||||
+exec_prefix=${prefix}
|
||||
libdir=@CMAKE_INSTALL_FULL_LIBDIR@
|
||||
includedir=@CMAKE_INSTALL_FULL_INCLUDEDIR@
|
||||
|
||||
--
|
||||
2.9.2
|
||||
|
||||
84
dev-libs/uchardet/uchardet-0.0.6.recipe
Normal file
84
dev-libs/uchardet/uchardet-0.0.6.recipe
Normal file
@@ -0,0 +1,84 @@
|
||||
SUMMARY="An encoding detector library ported from Mozilla"
|
||||
DESCRIPTION="uchardet is an encoding detector library, which takes a sequence \
|
||||
of bytes in an unknown character encoding without any additional information, \
|
||||
and attempts to determine the encoding of the text. Returned encoding names \
|
||||
are iconv-compatible.
|
||||
uchardet started as a C language binding of the original C++ implementation of \
|
||||
the universal charset detection library by Mozilla. It can now detect more \
|
||||
charsets, and more reliably than the original implementation."
|
||||
HOMEPAGE="https://www.freedesktop.org/wiki/Software/uchardet/"
|
||||
COPYRIGHT="2015-2016 BYVoid, Jehan"
|
||||
LICENSE="MPL v1.1"
|
||||
REVISION="1"
|
||||
SOURCE_URI="https://www.freedesktop.org/software/uchardet/releases/uchardet-$portVersion.tar.xz"
|
||||
CHECKSUM_SHA256="8351328cdfbcb2432e63938721dd781eb8c11ebc56e3a89d0f84576b96002c61"
|
||||
PATCHES="uchardet-$portVersion.patchset"
|
||||
|
||||
ARCHITECTURES="x86_gcc2 x86 x86_64"
|
||||
SECONDARY_ARCHITECTURES="x86_gcc2 x86"
|
||||
|
||||
PROVIDES="
|
||||
uchardet$secondaryArchSuffix = $portVersion
|
||||
lib:libuchardet$secondaryArchSuffix = $portVersion
|
||||
"
|
||||
if [ -z "$secondaryArchSuffix" ]; then
|
||||
PROVIDES="$PROVIDES
|
||||
cmd:uchardet
|
||||
"
|
||||
fi
|
||||
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
"
|
||||
|
||||
PROVIDES_devel="
|
||||
uchardet${secondaryArchSuffix}_devel = $portVersion
|
||||
devel:libuchardet$secondaryArchSuffix = $portVersion
|
||||
"
|
||||
REQUIRES_devel="
|
||||
uchardet$secondaryArchSuffix == $portVersion base
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:cmake
|
||||
cmd:g++$secondaryArchSuffix
|
||||
cmd:ld$secondaryArchSuffix
|
||||
cmd:make
|
||||
"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
cmake . \
|
||||
-DCMAKE_INSTALL_PREFIX=$prefix \
|
||||
-DCMAKE_INSTALL_BINDIR=$binDir \
|
||||
-DCMAKE_INSTALL_INCLUDEDIR=$includeDir \
|
||||
-DCMAKE_INSTALL_LIBDIR=$libDir \
|
||||
-DCMAKE_INSTALL_MANDIR=$manDir \
|
||||
-DCMAKE_BUILD_TYPE=Release
|
||||
make $jobArgs
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
make install
|
||||
|
||||
prepareInstalledDevelLibs libuchardet
|
||||
fixPkgconfig
|
||||
|
||||
if [ -n "$secondaryArchSuffix" ]; then
|
||||
rm -rf $binDir
|
||||
rm -rf $documentationDir
|
||||
fi
|
||||
|
||||
# devel package
|
||||
packageEntries devel \
|
||||
$developDir
|
||||
}
|
||||
|
||||
TEST()
|
||||
{
|
||||
make test
|
||||
}
|
||||
Reference in New Issue
Block a user