DLib: new recipe (#1945)

This commit is contained in:
miqlas
2017-12-26 20:19:49 +01:00
committed by waddlesplash
parent 926920fce9
commit c50975aa0b
2 changed files with 115 additions and 0 deletions

View File

@@ -0,0 +1,92 @@
SUMMARY="Numerical and networking C++ library"
DESCRIPTION="Dlib is a modern C++ toolkit containing machine learning \
algorithms and tools for creating complex software in C++ to solve real \
world problems."
HOMEPAGE="http://dlib.net/"
COPYRIGHT="2003-2017 Davis E. King"
LICENSE="Boost v1.0"
REVISION="1"
SOURCE_URI="https://downloads.sourceforge.net/dclib/dlib-$portVersion.tar.bz2"
CHECKSUM_SHA256="dbd31f7b97166e58f366c83fa5127e9fa44c492921558b61ce63a7d775be696b"
ARCHITECTURES="!x86_gcc2 x86 x86_64"
SECONDARY_ARCHITECTURES="x86"
PROVIDES="
dlib$secondaryArchSuffix = $portVersion
lib:libdlib$secondaryArchSuffix = $portVersion
"
REQUIRES="
haiku$secondaryArchSuffix
lib:libgif$secondaryArchSuffix
lib:libjpeg$secondaryArchSuffix
lib:liblapack$secondaryArchSuffix
lib:libopenblas$secondaryArchSuffix
lib:libpng16$secondaryArchSuffix
lib:libsqlite3$secondaryArchSuffix
lib:libz$secondaryArchSuffix
"
PROVIDES_devel="
dlib${secondaryArchSuffix}_devel = $portVersion
devel:libdlib$secondaryArchSuffix = $portVersion
"
REQUIRES_devel="
dlib$secondaryArchSuffix == $portVersion base
"
BUILD_REQUIRES="
haiku${secondaryArchSuffix}_devel
devel:libgif$secondaryArchSuffix
devel:libjpeg$secondaryArchSuffix
devel:liblapack$secondaryArchSuffix
devel:libopenblas$secondaryArchSuffix
devel:libpng16$secondaryArchSuffix
devel:libsqlite3$secondaryArchSuffix
devel:libz$secondaryArchSuffix
"
BUILD_PREREQUIRES="
cmd:cmake
cmd:g++$secondaryArchSuffix
cmd:make
cmd:pkg_config$secondaryArchSuffix
"
defineDebugInfoPackage dlib$secondaryArchSuffix \
$libDir/libdlib.so.19.8.0
BUILD()
{
mkdir -p build && cd "$_"
cmake .. \
$cmakeDirArgs
make $jobArgs
}
INSTALL()
{
cd build
make install
mkdir -p $libDir/cmake/
prepareInstalledDevelLib libdlib
sed -i "1i prefix=$prefix" \
$libDir/pkgconfig/dlib-1.pc
fixPkgconfig
packageEntries devel \
$developDir \
$libDir/cmake
}
TEST()
{
#make test
# dlib provides no tests through cmake AFAIK
true
}

View File

@@ -0,0 +1,23 @@
Boost Software License - Version 1.0 - August 17th, 2003
Permission is hereby granted, free of charge, to any person or organization
obtaining a copy of the software and accompanying documentation covered by
this license (the "Software") to use, reproduce, display, distribute,
execute, and transmit the Software, and to prepare derivative works of the
Software, and to permit third-parties to whom the Software is furnished to
do so, all subject to the following:
The copyright notices in the Software and this entire statement, including
the above license grant, this restriction and the following disclaimer,
must be included in all copies of the Software, in whole or in part, and
all derivative works of the Software, unless such copies or derivative
works are solely in the form of machine-executable object code generated by
a source language processor.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT
SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.