Fixed silly error in Windows build of tests (abitest-cc not linking to libtcc)
I really should do this when less tired; I keep breaking one platform while fixing another. I've also fixed some Windows issues with tcctest since Windows printf() uses different format flags to those on Linux, and removed some conditional compilation tests in tcctest since they now should work.
This commit is contained in:
@ -5,13 +5,12 @@ if(WIN32)
|
||||
set(TCC_CFLAGS ${TCC_CFLAGS} -I${CMAKE_SOURCE_DIR}/win32/include)
|
||||
else()
|
||||
set(TCC_MATH_LDFLAGS -lm)
|
||||
set(LIBTCC_EXTRA_LIBS dl)
|
||||
set(LIBTCC_LDFLAGS -ldl -lm -Wl,-rpath=${CMAKE_BINARY_DIR})
|
||||
endif()
|
||||
|
||||
add_executable(abitest-cc abitest.c)
|
||||
if(NOT WIN32)
|
||||
target_link_libraries(abitest-cc libtcc dl)
|
||||
endif()
|
||||
target_link_libraries(abitest-cc libtcc ${LIBTCC_EXTRA_LIBS})
|
||||
add_test(NAME abitest-cc WORKING_DIRECTORY ${CMAKE_BINARY_DIR} COMMAND abitest-cc lib_path=${CMAKE_BINARY_DIR} include=${CMAKE_SOURCE_DIR}/include)
|
||||
|
||||
set(ABITEST_TCC abitest-tcc${CMAKE_EXECUTABLE_SUFFIX})
|
||||
|
||||
Reference in New Issue
Block a user