Re: pkg/60301: libjpeg-turbo version 3.1.4.1 doesn't build on amiga
"S.P.Zeidler via gnats" <[email protected]> Sat, 30 May 2026 19:35:02 +0000 (UTC)
| Newsgroups | gmane.os.netbsd.devel.pkgsrc.bugs |
|---|---|
| Message-ID | <[email protected]> |
The following reply was made to PR pkg/60301; it has been noted by GNATS. From: "S.P.Zeidler" <[email protected]> To: [email protected] Cc: Subject: Re: pkg/60301: libjpeg-turbo version 3.1.4.1 doesn't build on amiga Date: Sat, 30 May 2026 19:32:38 +0000 Hi Thomas, Thus wrote Thomas Klausner via gnats ([email protected]): > There is a very extensive code in simd/CMakeLists.txt that handles a > lot of platforms. 3.1.4.1 has: # grep CPU_TYPE work/libjpeg-turbo-3.1.4.1/simd/CMakeLists.txt if(CPU_TYPE STREQUAL "x86_64" OR CPU_TYPE STREQUAL "i386") if(CPU_TYPE STREQUAL "x86_64") elseif(CPU_TYPE STREQUAL "i386") if(CPU_TYPE STREQUAL "x86_64") elseif(CPU_TYPE STREQUAL "i386") if(CPU_TYPE STREQUAL "x86_64" AND CMAKE_ASM_NASM_OBJECT_FORMAT MATCHES "^elf") set(CMAKE_ASM_NASM_FLAGS "${CMAKE_ASM_NASM_FLAGS} -I\"${CMAKE_CURRENT_SOURCE_DIR}/nasm/\" -I\"${CMAKE_CURRENT_SOURCE_DIR}/${CPU_TYPE}/\"") if(CPU_TYPE STREQUAL "x86_64") string(REGEX REPLACE "${CPU_TYPE}/" "" filename ${file}) add_library(simd OBJECT ${CPU_TYPE}/jsimd.c) add_library(simd OBJECT ${SIMD_SOURCES} ${CPU_TYPE}/jsimd.c) elseif(CPU_TYPE STREQUAL "arm64" OR CPU_TYPE STREQUAL "arm") if(CPU_TYPE STREQUAL "arm") elseif(CPU_TYPE STREQUAL "mips" OR CPU_TYPE STREQUAL "mipsel") elseif(CPU_TYPE STREQUAL "loongson" OR CPU_TYPE MATCHES "^mips64") elseif(CPU_TYPE STREQUAL "powerpc") endif() # CPU_TYPE so my guess is that x86_64, i386, arm64, arm, mips, mipsel, loongson, variants of mips64 and powerpc will work. I'm trying a build on sparc64 to verify that that will also fail; it's currently slogging through dependencies and will be a while. make configure on amiga yields: CMake Warning at simd/CMakeLists.txt:5 (message): SIMD extensions not available for this CPU (m68k). Performance will suffer. Call Stack (most recent call first): simd/CMakeLists.txt:567 (simd_fail) > you can add something like > > .if ${MACHINE_ARCH} == m68k > CMAKE_CONFIGURE_ARGS+= -DWITH_SIMD=FALSE > .endif > > to disable SIMD detection/support. I used CMAKE_CONFIGURE_ARGS+= -DWITH_SIMD=0 after I found the hint to do that in README.md, and it builds then. Comparing to 3.1.3 on amiga: make configure also yields: CMake Warning at simd/CMakeLists.txt:5 (message): SIMD extensions not available for this CPU (m68k). Performance will suffer. Call Stack (most recent call first): simd/CMakeLists.txt:539 (simd_fail) and simd/CMakeLists.txt isn't a lot different. There is nothing about m68k or amiga in there. Perhaps you remebered a rather earlier version? Anyhow, building 3.1.3 works: work/libjpeg-turbo-3.1.3/cmake-pkgsrc-build/Makefile contains no entries regarding simd, wheras the 3.1.4.1 version has: # Build rule for target. simdcoverage: cmake_check_build_system $(MAKE) $(MAKESILENT) -f CMakeFiles/Makefile2 simdcoverage .PHONY : simdcoverage # fast build rule for target. simdcoverage/fast: $(MAKE) $(MAKESILENT) -f simd/CMakeFiles/simdcoverage.dir/build.make simd/CMakeFiles/simdcoverage.dir/build .PHONY : simdcoverage/fast simdcoverage seems to be new in 3.1.4(.1) and seems to be not sufficiently exempt from building on non-simd CPU architectures. regards, spz