File tree Expand file tree Collapse file tree 1 file changed +17
-1
lines changed Expand file tree Collapse file tree 1 file changed +17
-1
lines changed Original file line number Diff line number Diff line change @@ -552,14 +552,30 @@ build_jpeg() {
552552 ;;
553553 esac
554554
555+ local jpeg_cmake_args=()
556+
557+ case " ${PLATFORM} " in
558+ windows-* -* )
559+ ;;
560+ * )
561+ # Workaround for: undefined reference to `log10'
562+ # The CMakeLists.txt file only does -lm if UNIX,
563+ # but UNIX may not be true on Linux.
564+ jpeg_cmake_args=(-DUNIX=True)
565+ ;;
566+ esac
567+
555568 cd " ${dir_name} "
556569
570+ # Add -lm to fix:
571+ # undefined reference to `log10'
557572 cmake_build \
558573 -DENABLE_SHARED=" ${LIBS_SHARED} " \
559574 -DENABLE_STATIC=" ${LIBS_STATIC} " \
560575 -DCMAKE_SYSTEM_NAME=" ${LIBS_STATIC} " \
561576 -DCMAKE_SYSTEM_PROCESSOR=" ${SYSTEM_PROCESSOR} " \
562- -DWITH_JPEG8=1
577+ -DWITH_JPEG8=1 \
578+ " ${jpeg_cmake_args[@]} "
563579}
564580
565581# Build WebP
You can’t perform that action at this time.
0 commit comments