blob: 47fae082023645846db6048e7a8a56a64555ead6 (
plain)
1 # Description: Indexing and searching library
2 # URL: https://www.sourceforge.net/projects/clucene
3 # Maintainer: Tim Biermann, tbier at posteo dot de
4 # Depends on: cmake
5 # Optional: log4cxx bzip2 exiv2 boost
6
7 name=clucene
8 version=2.3.3.4
9 release=1
10 source=(https://downloads.sourceforge.net/project/clucene/clucene-core-unstable/2.3/$name-core-$version.tar.gz
11 fix_zlib_detections.diff clucene-core-2.3.3.4-install_contribs_lib.patch clucene-narrowing-conversions.patch
12 clucene-warnings.patch clucene-debug.patch clucene-gcc-atomics.patch clucene-multimap-put.patch
13 clucene-2.3.3.4-contribs_lib-1.patch cmake.patch contribs-lib-makefile.patch)
14
15 build() {
16 [[ -e /usr/bin/ninja ]] && PKGMK_CLUCENE=' -G Ninja'
17
18 patch -Np1 -d $name-core-$version -i $SRC/cmake.patch
19 patch -Np1 -d $name-core-$version -i $SRC/clucene-2.3.3.4-contribs_lib-1.patch
20 patch -Np1 -d $name-core-$version -i $SRC/fix_zlib_detections.diff
21 # LibreOffice patches http://cgit.freedesktop.org/libreoffice/core/tree/clucene/patches
22 patch -Np0 -d $name-core-$version -i $SRC/clucene-warnings.patch
23 patch -Np0 -d $name-core-$version -i $SRC/clucene-gcc-atomics.patch
24 patch -Np0 -d $name-core-$version -i $SRC/clucene-debug.patch
25 patch -Np0 -d $name-core-$version -i $SRC/clucene-narrowing-conversions.patch
26 patch -Np0 -d $name-core-$version -i $SRC/clucene-multimap-put.patch
27
28 cmake -S $name-core-$version -B build $PKGMK_CLUCENE \
29 -D CMAKE_INSTALL_PREFIX=/usr \
30 -D CMAKE_BUILD_TYPE=Release \
31 -D CMAKE_CXX_FLAGS_RELEASE="$CXXFLAGS" \
32 -D CMAKE_C_FLAGS_RELEASE="$CFLAGS" \
33 -D BUILD_CONTRIBS_LIB=ON \
34 -D ENABLE_ASCII_MODE=OFF \
35 -D ENABLE_PACKAGING=OFF \
36 -D DISABLE_MULTITHREADING=OFF \
37 -Wno-dev
38 cmake --build build
39 DESTDIR=$PKG cmake --install build
40 }
|