Package Details: halide 21.0.0-1

Git Clone URL: https://aur.archlinux.org/halide.git (read-only, click to copy)
Package Base: halide
Description: A language for fast and portable data-parallel computation.
Upstream URL: https://halide-lang.org/
Licenses: MIT
Submitter: OmarEmaraDev
Maintainer: OmarEmaraDev
Last Packager: OmarEmaraDev
Votes: 2
Popularity: 0.000000
First Submitted: 2021-09-04 19:56 (UTC)
Last Updated: 2025-10-30 08:49 (UTC)

Dependencies (9)

Sources (1)

Latest Comments

calcmogul commented on 2025-12-01 23:17 (UTC) (edited on 2025-12-01 23:29 (UTC) by calcmogul)

The default makepkg.conf options (see https://gitlab.archlinux.org/archlinux/packaging/packages/pacman/-/blob/main/makepkg.conf?ref_type=heads#L98) have strip set, which stripped all symbols from the static and shared libraries I installed and prevented me from consuming the Halide::Generator CMake target.

[1/5] Linking CXX executable apriltag_gen
FAILED: [code=1] apriltag_gen 
: && /usr/lib/ccache/bin/c++ -O3 -DNDEBUG -march=native -mtune=native -ffast-math -Wl,--dependency-file=CMakeFiles/apriltag_gen.dir/link.d CMakeFiles/apriltag_gen.dir/src/apriltag_halide_generator.cpp.o -o apriltag_gen  -Wl,--push-state,--whole-archive  /usr/lib/libHalide_GenGen.a  -Wl,--pop-state  /usr/lib/libHalide.so.21.0.0  -ldl && :
mold: fatal: GenGen.cpp.o: not claimed by the LTO plugin; please make sure you are using the same compiler of the same version for all object files
collect2: error: ld returned 1 exit status
ninja: build stopped: subcommand failed.

Symbol list:

[tav@myriad ~]$ nm /usr/lib/libHalide_GenGen.a /usr/lib/libHalide.so

/usr/lib/libHalide_GenGen.a:

GenGen.cpp.o:
0000000000000001 C __gnu_lto_slim

/usr/lib/libHalide.so:
nm: /usr/lib/libHalide.so: no symbols

Adding an override for strip fixed my linking issue.

diff --git a/PKGBUILD b/PKGBUILD
index 34a3974..45a9493 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -13,6 +13,7 @@ optdepends=(
   'emscripten: WebAssembly backend.'
   'libpng: PNG support in the Image IO Utility.'
   'libjpeg: JPEG support in the Image IO Utility.')
+options=('!strip' 'staticlibs')
 source=("https://github.com/halide/Halide/archive/refs/tags/v$pkgver.tar.gz")
 sha256sums=('aa6b6f5e89709ca6bc754ce72b8b13b2abce0d6b001cb2516b1c6f518f910141')

Symbol list:

[tav@myriad ~]$ nm /usr/lib/libHalide_GenGen.a /usr/lib/libHalide.so

/usr/lib/libHalide_GenGen.a:

GenGen.cpp.o:
00000000 T main
         U _ZN6Halide8Internal20generate_filter_mainEiPPc

/usr/lib/libHalide.so:
0000000000db5168 d $tlsld
                 U abort
0000000000dbbf00 d abort$got
<...snip...>

Note that !staticlibs is also set by default, which may or may not be intended. It didn't seem to affect the final package though.

daskol commented on 2024-07-31 07:15 (UTC) (edited on 2024-07-31 07:16 (UTC) by daskol)

Add tarball checksums in PKGBUILD, please.

diff --git a/PKGBUILD b/PKGBUILD
index a81e3d4..2357efb 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -14,7 +14,7 @@ optdepends=(
   'libpng: PNG support in the Image IO Utility.'
   'libjpeg: JPEG support in the Image IO Utility.')
 source=("https://github.com/halide/Halide/archive/refs/tags/v$pkgver.tar.gz")
-md5sums=('SKIP')
+sha256sums=('1176b42a3e2374ab38555d9316c78e39b157044b5a8e765c748bf3afd2edb351')

 build() {
   cmake -B build -S "Halide-$pkgver" \

OmarEmaraDev commented on 2022-07-14 11:15 (UTC)

@shirok1 It seems to me POSITION_INDEPENDENT_CODE is already set to ON in the cmake file, so I am not sure how that would help. See CMakeLists.txt. What is the issue/error exactly?

shirok1 commented on 2022-07-13 04:31 (UTC) (edited on 2022-07-13 04:32 (UTC) by shirok1)

Mine have same PIC issue too. I suggest adding -DCMAKE_POSITION_INDEPENDENT_CODE=ON to PKGBUILD instead of changing $CXXFLAGS manually.

carlosal1015 commented on 2022-07-08 21:13 (UTC)

Thank you, is fixed now.

OmarEmaraDev commented on 2022-07-08 20:52 (UTC)

@carlosal1015 I updated the package to 14.0.0 and it seems to build fine. Can you try this new build?

OmarEmaraDev commented on 2022-03-13 11:32 (UTC)

Started using tarballs instead. The library is built with PIC by default, check the generated ninja build file. So it is unclear why that would make a difference for you. Perhaps it is something in your environment?

shirok1 commented on 2022-03-13 08:33 (UTC)

please consider using tarball links like https://github.com/halide/Halide/archive/refs/tags/v13.0.4.tar.gz and add these lines to build():

CFLAGS="$CFLAGS -fPIC"
CXXFLAGS="$CXXFLAGS -fPIC"

my ld can't link without -fPIC