[CMAKE]: Make simple rule for building ASM files.
authorSir Richard <sir_richard@svn.reactos.org>
Tue, 3 Aug 2010 14:53:12 +0000 (14:53 +0000)
committerSir Richard <sir_richard@svn.reactos.org>
Tue, 3 Aug 2010 14:53:12 +0000 (14:53 +0000)
[CMAKE]: Enable RC support.
[CMAKE]: Stop building tools we won't need.

svn path=/branches/cmake-bringup/; revision=48427

CMakeLists.txt
toolchain-mingw32.cmake

index 4464234..2ed4db3 100644 (file)
@@ -16,13 +16,16 @@ include_directories(./include/reactos/wine)
 add_subdirectory(tools)
 add_subdirectory(lib)
 
-export(TARGETS widl winebuild wmc wrc nci pefixup rsym FILE ${CMAKE_BINARY_DIR}/ImportExecutables.cmake NAMESPACE native- )
+export(TARGETS widl winebuild nci FILE ${CMAKE_BINARY_DIR}/ImportExecutables.cmake NAMESPACE native- )
 
 else()
 
-# Activate support for asm source files
+# Activate support for assembly source files
 enable_language(ASM)
 
+# Activate language support for resource files
+enable_language(RC)
+
 set(IMPORT_EXECUTABLES "${REACTOS_SOURCE_DIR}/build/ImportExecutables.cmake" CACHE FILEPATH "Host executables")
 include(${IMPORT_EXECUTABLES})
 
@@ -40,7 +43,10 @@ add_definitions(-DUSE_COMPILER_EXCEPTIONS)
 add_definitions(-D_USE_32BIT_TIME_T)
 
 # Compiler Core
-add_definitions(-gstabs+ -pipe -fms-extensions -fno-set-stack-executable)
+add_definitions(-pipe -fms-extensions -fno-set-stack-executable)
+
+# Debugging (Note: DWARF-4 on 4.5.1 when we ship)
+add_definitions(-gdwarf-2 -g2 -femit-struct-debug-detailed=none -feliminate-unused-debug-types)
 
 # Tuning
 add_definitions(-march=pentium -mtune=i686)
index 7deaee2..c50029b 100644 (file)
@@ -15,8 +15,9 @@ SET(CMAKE_SYSTEM_PROCESSOR i686)
 # which compilers to use for C and C++
 SET(CMAKE_C_COMPILER ${MINGW_PREFIX}gcc)
 SET(CMAKE_CXX_COMPILER ${MINGW_PREFIX}g++)
-
+SET(CMAKE_RC_COMPILER ${MINGW_PREFIX}windres)
 SET(CMAKE_ASM_COMPILER ${MINGW_PREFIX}gcc)
+set(CMAKE_ASM_COMPILE_OBJECT "<CMAKE_ASM_COMPILER> -x assembler-with-cpp -o <OBJECT> <FLAGS> <DEFINES> -D__ASM__ -c <SOURCE>")
 
 # adjust the default behaviour of the FIND_XXX() commands:
 # search headers and libraries in the target environment, search