2010-08-14 00:00:09 -07:00
|
|
|
# This is a D app that links a C object.
|
|
|
|
#
|
|
|
|
# The linker preference of D is higher than C (or CXX), so after
|
|
|
|
# the objects are created, the D toolchain will drive linking.
|
|
|
|
#
|
2010-12-09 23:08:33 +01:00
|
|
|
# TODO
|
|
|
|
# dirty fix
|
|
|
|
# we should make the CMAKE_D_COMPILER_ID work
|
|
|
|
IF("${CMAKE_BASE_NAME}" MATCHES "dmd")
|
2011-02-22 15:08:08 +01:00
|
|
|
SET(CMAKE_C_FLAGS "-m32 ${CMAKE_C_FLAGS}" )
|
2010-12-09 23:08:33 +01:00
|
|
|
ENDIF()
|
2010-08-14 00:00:09 -07:00
|
|
|
ADD_EXECUTABLE ( app_5 app_5.d cfunc.c )
|
|
|
|
ADD_TEST( app_5 app_5 )
|