summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorJosh Holmer2022-06-03 21:53:00 -0400
committerJosh Holmer2022-06-03 21:53:00 -0400
commite7cbe76825b7b84eb06bc0838a634068876c6842 (patch)
tree92280a6900d8e2b04af10659f15e4229336b9649
parent025c01302692aa00169dfc0f8fe6248548bba254 (diff)
downloadaur-e7cbe76825b7b84eb06bc0838a634068876c6842.tar.gz
Build improvements
-rw-r--r--.SRCINFO4
-rw-r--r--PKGBUILD99
2 files changed, 52 insertions, 51 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 39805591768b..97061dc1a2a2 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = libjxl-metrics-git
pkgdesc = JPEG XL image format reference implementation with butteraugli and ssimulacra (git version)
- pkgver = v0.3.7.870.g373c5928
- pkgrel = 2
+ pkgver = v0.3.7.1056.g7d047b5f
+ pkgrel = 1
url = https://jpeg.org/jpegxl/
arch = x86_64
license = BSD
diff --git a/PKGBUILD b/PKGBUILD
index 0b44f888b72d..6fcb3a8778dc 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,42 +1,42 @@
# Maintainer: Joshua Holmer <jholmer.in@gmail.com>
pkgname=libjxl-metrics-git
-pkgver=v0.3.7.870.g373c5928
-pkgrel=2
+pkgver=v0.3.7.1056.g7d047b5f
+pkgrel=1
pkgdesc="JPEG XL image format reference implementation with butteraugli and ssimulacra (git version)"
arch=('x86_64')
url='https://jpeg.org/jpegxl/'
license=('BSD')
makedepends=('git' 'cmake' 'clang' 'brotli' 'gdk-pixbuf2' 'giflib' 'gimp'
- 'gperftools' 'libjpeg-turbo' 'libpng' 'openexr' 'gflags'
- 'gtest' 'java-environment' 'python' 'asciidoc' 'doxygen'
- 'graphviz' 'xdg-utils' 'highway')
+ 'gperftools' 'libjpeg-turbo' 'libpng' 'openexr' 'gflags'
+ 'gtest' 'java-environment' 'python' 'asciidoc' 'doxygen'
+ 'graphviz' 'xdg-utils' 'highway')
provides=('libjxl' 'libjpeg-xl-git' 'libjxl.so' 'libjxl_threads.so' 'libjxl-doc' 'libjpeg-xl-doc-git')
conflicts=('libjxl' 'libjpeg-xl-git' 'libjxl-doc' 'libjpeg-xl-doc-git')
replaces=('libjpeg-xl-git' 'libjpeg-xl-doc-git')
optdepends=('gdk-pixbuf2: for gdk-pixbuf loader'
- 'gimp: for gimp plugin')
+ 'gimp: for gimp plugin')
options=('!lto')
source=('git+https://github.com/libjxl/libjxl.git'
- 'git+https://github.com/google/brotli.git'
- 'git+https://github.com/mm2/Little-CMS.git'
- 'git+https://github.com/google/googletest.git'
- 'git+https://github.com/webmproject/sjpeg.git'
- 'git+https://skia.googlesource.com/skcms.git'
- 'git+https://github.com/google/highway.git'
- 'git+https://github.com/glennrp/libpng.git'
- 'git+https://github.com/madler/zlib.git'
- 'git+https://github.com/gflags/gflags.git')
+ 'git+https://github.com/google/brotli.git'
+ 'git+https://github.com/mm2/Little-CMS.git'
+ 'git+https://github.com/google/googletest.git'
+ 'git+https://github.com/webmproject/sjpeg.git'
+ 'git+https://skia.googlesource.com/skcms.git'
+ 'git+https://github.com/google/highway.git'
+ 'git+https://github.com/glennrp/libpng.git'
+ 'git+https://github.com/madler/zlib.git'
+ 'git+https://github.com/gflags/gflags.git')
sha256sums=('SKIP'
- 'SKIP'
- 'SKIP'
- 'SKIP'
- 'SKIP'
- 'SKIP'
- 'SKIP'
- 'SKIP'
- 'SKIP'
- 'SKIP')
+ 'SKIP'
+ 'SKIP'
+ 'SKIP'
+ 'SKIP'
+ 'SKIP'
+ 'SKIP'
+ 'SKIP'
+ 'SKIP'
+ 'SKIP')
prepare() {
git -C libjxl submodule init
@@ -53,36 +53,37 @@ prepare() {
}
pkgver() {
- cd libjxl
- echo "$(git describe --long --tags | tr - .)"
+ cd libjxl
+ echo "$(git describe --long --tags | tr - .)"
}
build() {
- export CC='clang -flto=thin'
- export CXX='clang++ -flto=thin'
- export CFLAGS+=' -DNDEBUG'
- export CXXFLAGS+=' -DNDEBUG'
+ export LDFLAGS="-fuse-ld=lld -Wl,--thinlto-jobs=all"
+ COMMON_FLAGS="-O3 -march=native -flto=thin -pipe $LD_FLAGS"
+ export CC=clang CXX=clang++
+ export CPPFLAGS="${COMMON_FLAGS}" CCXFLAGS="${COMMON_FLAGS}"
+
cmake -B build -S libjxl \
- -DCMAKE_BUILD_TYPE:STRING='None' \
- -DCMAKE_INSTALL_PREFIX:PATH='/usr' \
- -DBUILD_TESTING=false \
- -DJPEGXL_ENABLE_DEVTOOLS:BOOL='true' \
- -DJPEGXL_ENABLE_BENCHMARK:BOOL='false' \
- -DJPEGXL_ENABLE_EXAMPLES:BOOL='false' \
- -DJPEGXL_ENABLE_FUZZERS:BOOL='false' \
- -DJPEGXL_ENABLE_PLUGINS:BOOL='true' \
- -DJPEGXL_ENABLE_VIEWERS:BOOL='false' \
- -DJPEGXL_FORCE_SYSTEM_BROTLI:BOOL='true' \
- -DJPEGXL_FORCE_SYSTEM_GTEST:BOOL='true' \
- -DJPEGXL_FORCE_SYSTEM_HWY:BOOL='true' \
- -DJPEGXL_BUNDLE_LIBPNG:BOOL='NO' \
- -DJPEGXL_BUNDLE_GFLAGS='NO' \
+ -DCMAKE_BUILD_TYPE='Release' \
+ -DCMAKE_INSTALL_PREFIX='/usr' \
+ -DCMAKE_C_COMPILER="${CC}" \
+ -DCMAKE_CXX_COMPILER="${CXX}" \
+ -DCMAKE_C_FLAGS="$COMMON_FLAGS" \
+ -DCMAKE_CXX_FLAGS="$COMMON_FLAGS" \
+ -DCMAKE_EXE_LINKER_FLAGS="$LDFLAGS" \
+ -DBUILD_SHARED_LIBS=1 \
+ -DBUILD_TESTING=0 \
+ -DJPEGXL_ENABLE_FUZZERS=0 \
+ -DJPEGXL_ENABLE_DEVTOOLS=1 \
+ -DJPEGXL_ENABLE_BENCHMARK=0 \
+ -DJPEGXL_ENABLE_EXAMPLES=0 \
+ -DJPEGXL_FORCE_SYSTEM_BROTLI=1 \
+ -DJPEGXL_FORCE_SYSTEM_GTEST=1 \
+ -DJPEGXL_FORCE_SYSTEM_HWY=1 \
+ -DJPEGXL_BUNDLE_LIBPNG=0 \
+ -DJPEGXL_BUNDLE_GFLAGS=0 \
-Wno-dev
- make -C build all doc -j$(nproc)
-}
-
-check() {
- make -C build test
+ make -C build all doc -j $(nproc)
}
package() {