Skip to content

Commit

Permalink
don't attempt to pass windows flags to cc when building jbigi, jcpuid…
Browse files Browse the repository at this point in the history
… on non-Windows platforms
  • Loading branch information
eyedeekay committed Jan 2, 2023
1 parent c0891c4 commit 0f7dca9
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion core/c/jcpuid/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,13 @@ echo "INCLUDES:$INCLUDES"

echo "Compiling C code..."
rm -f ${LIBFILE}
"${CC_PREFIX}""${CC}" ${CFLAGS} ${LDFLAGS} ${INCLUDES} "${WINDOWS_INCLUDES}" "${WINDOWS_INCLUDES_HOST}" src/*.c -o "${LIBFILE}" || (echo "Failed to compile ${LIBFILE}"; exit 1)
case "$TARGET" in
MINGW*|CYGWIN*|windows*)
"${CC_PREFIX}""${CC}" ${CFLAGS} ${LDFLAGS} ${INCLUDES} "${WINDOWS_INCLUDES}" "${WINDOWS_INCLUDES_HOST}" src/*.c -o "${LIBFILE}" || (echo "Failed to compile ${LIBFILE}"; exit 1)
;;
*)
"${CC_PREFIX}""${CC}" ${CFLAGS} ${LDFLAGS} ${INCLUDES} src/*.c -o "${LIBFILE}" || (echo "Failed to compile ${LIBFILE}"; exit 1)
;;
esac
"${CC_PREFIX}"strip "${LIBFILE}" || (echo "Failed to strip ${LIBFILE}" ; exit 1)
echo Built "$(dirname "$0")"/"${LIBFILE}"

0 comments on commit 0f7dca9

Please sign in to comment.