[cmake-commits] king committed CMakeLists.txt 1.3 1.4 testExe1.c 1.1
1.2 testExe1lib.c NONE 1.1
cmake-commits at cmake.org
cmake-commits at cmake.org
Mon Jan 28 13:38:01 EST 2008
Update of /cvsroot/CMake/CMake/Tests/ExportImport/Export
In directory public:/mounts/ram/cvs-serv17316/Tests/ExportImport/Export
Modified Files:
CMakeLists.txt testExe1.c
Added Files:
testExe1lib.c
Log Message:
BUG: Fix export/import file generation to not store link dependencies of executables or modules.
Index: testExe1.c
===================================================================
RCS file: /cvsroot/CMake/CMake/Tests/ExportImport/Export/testExe1.c,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- testExe1.c 28 Jan 2008 13:40:20 -0000 1.1
+++ testExe1.c 28 Jan 2008 18:37:59 -0000 1.2
@@ -1,5 +1,7 @@
#include <stdio.h>
+extern int testExe1lib();
+
int main(int argc, const char* argv[])
{
if(argc < 2)
@@ -20,5 +22,5 @@
return 1;
}
}
- return 0;
+ return testExe1lib();
}
Index: CMakeLists.txt
===================================================================
RCS file: /cvsroot/CMake/CMake/Tests/ExportImport/Export/CMakeLists.txt,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- CMakeLists.txt 28 Jan 2008 18:21:42 -0000 1.3
+++ CMakeLists.txt 28 Jan 2008 18:37:59 -0000 1.4
@@ -5,7 +5,9 @@
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_ANSI_CFLAGS}")
endif(CMAKE_ANSI_CFLAGS)
+add_library(testExe1lib STATIC testExe1lib.c) # not exported
add_executable(testExe1 testExe1.c)
+target_link_libraries(testExe1 testExe1lib)
add_executable(testExe2 testExe2.c)
set_property(TARGET testExe2 PROPERTY ENABLE_EXPORTS 1)
--- NEW FILE: testExe1lib.c ---
int testExe1lib() { return 0; }
More information about the Cmake-commits
mailing list