From: Amine Khaldi Date: Mon, 13 Jun 2011 15:31:11 +0000 (+0000) Subject: [CMAKE] X-Git-Tag: backups/ros-amd64-bringup@60669^2~393 X-Git-Url: https://git.reactos.org/?p=reactos.git;a=commitdiff_plain;h=7c3e144a2ce5339077651f8474930a89e6a88450 [CMAKE] * Automatically add _DLL and __USE_CRTIMP definitions when linking to msvcrt. * Separate some flags from definitions (using add_compiler_flags). svn path=/trunk/; revision=52213 --- diff --git a/reactos/base/applications/cmdutils/find/CMakeLists.txt b/reactos/base/applications/cmdutils/find/CMakeLists.txt index f94e42eee18..11b838b6f9f 100644 --- a/reactos/base/applications/cmdutils/find/CMakeLists.txt +++ b/reactos/base/applications/cmdutils/find/CMakeLists.txt @@ -1,4 +1,3 @@ -add_definitions(-D_DLL -D__USE_CRTIMP) add_executable(find find.c find.rc) diff --git a/reactos/base/applications/cmdutils/hostname/CMakeLists.txt b/reactos/base/applications/cmdutils/hostname/CMakeLists.txt index 528d64f04ec..d9e9edac79f 100644 --- a/reactos/base/applications/cmdutils/hostname/CMakeLists.txt +++ b/reactos/base/applications/cmdutils/hostname/CMakeLists.txt @@ -1,4 +1,3 @@ -add_definitions(-D_DLL -D__USE_CRTIMP) add_executable(hostname hostname.c hostname.rc) diff --git a/reactos/base/applications/findstr/CMakeLists.txt b/reactos/base/applications/findstr/CMakeLists.txt index 68b0e741727..df2257a41c4 100644 --- a/reactos/base/applications/findstr/CMakeLists.txt +++ b/reactos/base/applications/findstr/CMakeLists.txt @@ -1,9 +1,5 @@ -add_definitions(-D_DLL -D__USE_CRTIMP) - -add_executable(findstr - findstr.c - findstr.rc) +add_executable(findstr findstr.c findstr.rc) set_module_type(findstr win32cui) add_importlibs(findstr user32 msvcrt kernel32) diff --git a/reactos/base/applications/logoff/CMakeLists.txt b/reactos/base/applications/logoff/CMakeLists.txt index 9a674b7e0d8..cb7bd231e24 100644 --- a/reactos/base/applications/logoff/CMakeLists.txt +++ b/reactos/base/applications/logoff/CMakeLists.txt @@ -1,6 +1,4 @@ -add_definitions(-D_DLL -D__USE_CRTIMP) - list(APPEND SOURCE misc.c logoff.c diff --git a/reactos/base/applications/network/dwnl/CMakeLists.txt b/reactos/base/applications/network/dwnl/CMakeLists.txt index b1aff5f18b6..cf9e64a6164 100644 --- a/reactos/base/applications/network/dwnl/CMakeLists.txt +++ b/reactos/base/applications/network/dwnl/CMakeLists.txt @@ -1,4 +1,3 @@ -add_definitions(-D_DLL -D__USE_CRTIMP) set_unicode() @@ -10,7 +9,7 @@ target_link_libraries(dwnl uuid) add_importlibs(dwnl urlmon wininet msvcrt kernel32) if(MSVC) -add_importlibs(dwnl ntdll) + add_importlibs(dwnl ntdll) endif() add_cd_file(TARGET dwnl DESTINATION reactos/system32 FOR all) diff --git a/reactos/base/applications/network/finger/CMakeLists.txt b/reactos/base/applications/network/finger/CMakeLists.txt index 88e1076475f..e6156a14af7 100644 --- a/reactos/base/applications/network/finger/CMakeLists.txt +++ b/reactos/base/applications/network/finger/CMakeLists.txt @@ -1,7 +1,5 @@ -add_definitions( - -D__USE_W32_SOCKETS - -D_DLL -D__USE_CRTIMP) +add_definitions(-D__USE_W32_SOCKETS) add_executable(finger finger.c diff --git a/reactos/base/applications/network/ftp/CMakeLists.txt b/reactos/base/applications/network/ftp/CMakeLists.txt index 522da951bec..902f9de6ea7 100644 --- a/reactos/base/applications/network/ftp/CMakeLists.txt +++ b/reactos/base/applications/network/ftp/CMakeLists.txt @@ -1,7 +1,5 @@ -add_definitions( - -D_DLL -D__USE_CRTIMP - -Dlint) +add_definitions(-Dlint) add_executable(ftp cmds.c diff --git a/reactos/base/applications/network/route/CMakeLists.txt b/reactos/base/applications/network/route/CMakeLists.txt index 7dde646d9ff..77dde09896b 100644 --- a/reactos/base/applications/network/route/CMakeLists.txt +++ b/reactos/base/applications/network/route/CMakeLists.txt @@ -1,6 +1,4 @@ -add_definitions(-D_DLL -D__USE_CRTIMP) - set_unicode() add_executable(route route.c route.rc) diff --git a/reactos/base/applications/network/telnet/CMakeLists.txt b/reactos/base/applications/network/telnet/CMakeLists.txt index 8807761f2ca..51c76fa0ebc 100644 --- a/reactos/base/applications/network/telnet/CMakeLists.txt +++ b/reactos/base/applications/network/telnet/CMakeLists.txt @@ -1,7 +1,5 @@ -add_definitions( - -D_CRT_NONSTDC_NO_DEPRECATE - -D_DLL -D__USE_CRTIMP) +add_definitions(-D_CRT_NONSTDC_NO_DEPRECATE) set_cpp() diff --git a/reactos/base/applications/network/whois/CMakeLists.txt b/reactos/base/applications/network/whois/CMakeLists.txt index fb67240d921..755fc7a9818 100644 --- a/reactos/base/applications/network/whois/CMakeLists.txt +++ b/reactos/base/applications/network/whois/CMakeLists.txt @@ -1,6 +1,4 @@ -add_definitions(-D_DLL -D__USE_CRTIMP) - add_executable(whois whois.c whois.rc) set_module_type(whois win32cui) diff --git a/reactos/base/applications/regedit/CMakeLists.txt b/reactos/base/applications/regedit/CMakeLists.txt index b7125dd9389..f79bf4f1490 100644 --- a/reactos/base/applications/regedit/CMakeLists.txt +++ b/reactos/base/applications/regedit/CMakeLists.txt @@ -1,6 +1,4 @@ -add_definitions(-D_DLL -D__USE_CRTIMP) - set_unicode() set_rc_compiler() diff --git a/reactos/base/applications/shutdown/CMakeLists.txt b/reactos/base/applications/shutdown/CMakeLists.txt index 641904671ad..2401f8cf9ce 100644 --- a/reactos/base/applications/shutdown/CMakeLists.txt +++ b/reactos/base/applications/shutdown/CMakeLists.txt @@ -1,6 +1,4 @@ -add_definitions(-D_DLL -D__USE_CRTIMP) - list(APPEND SOURCE misc.c shutdown.c diff --git a/reactos/base/applications/sndvol32/CMakeLists.txt b/reactos/base/applications/sndvol32/CMakeLists.txt index bcd79cbea49..1e5f425efeb 100644 --- a/reactos/base/applications/sndvol32/CMakeLists.txt +++ b/reactos/base/applications/sndvol32/CMakeLists.txt @@ -1,11 +1,9 @@ -add_definitions(-D_DLL -D__USE_CRTIMP) - set_unicode() list(APPEND SOURCE dialog.c - misc.c + misc.c mixer.c sndvol32.c sndvol32.rc) diff --git a/reactos/base/applications/winhlp32/CMakeLists.txt b/reactos/base/applications/winhlp32/CMakeLists.txt index 8b1e1fe154f..6f3b9e1b7d4 100644 --- a/reactos/base/applications/winhlp32/CMakeLists.txt +++ b/reactos/base/applications/winhlp32/CMakeLists.txt @@ -7,8 +7,7 @@ add_definitions( -D__ROS_LONG64__ -D_CRT_NONSTDC_NO_DEPRECATE -Dfileno=_fileno - -Disatty=_isatty - -D_DLL -D__USE_CRTIMP) + -Disatty=_isatty) add_executable(winhlp32 callback.c @@ -20,7 +19,6 @@ add_executable(winhlp32 rsrc.rc) set_module_type(winhlp32 win32gui) - target_link_libraries(winhlp32 wine) add_importlibs(winhlp32 user32 gdi32 shell32 comctl32 comdlg32 msvcrt kernel32 ntdll) add_cd_file(TARGET winhlp32 DESTINATION reactos FOR all) diff --git a/reactos/base/applications/wordpad/CMakeLists.txt b/reactos/base/applications/wordpad/CMakeLists.txt index e8f3906dda9..d04e11ccbe5 100644 --- a/reactos/base/applications/wordpad/CMakeLists.txt +++ b/reactos/base/applications/wordpad/CMakeLists.txt @@ -1,9 +1,7 @@ include_directories(BEFORE ${REACTOS_SOURCE_DIR}/include/reactos/wine) -add_definitions( - -D__ROS_LONG64__ - -D_DLL -D__USE_CRTIMP) +add_definitions(-D__ROS_LONG64__) set_rc_compiler() @@ -17,7 +15,6 @@ list(APPEND SOURCE add_executable(wordpad ${SOURCE}) set_module_type(wordpad win32gui) - target_link_libraries(wordpad wine uuid) add_importlibs(wordpad comdlg32 ole32 shell32 user32 gdi32 advapi32 comctl32 msvcrt kernel32 ntdll) add_cd_file(TARGET wordpad DESTINATION reactos/system32 FOR all) diff --git a/reactos/base/services/telnetd/CMakeLists.txt b/reactos/base/services/telnetd/CMakeLists.txt index 225696094d5..f22c3e88ea9 100644 --- a/reactos/base/services/telnetd/CMakeLists.txt +++ b/reactos/base/services/telnetd/CMakeLists.txt @@ -1,6 +1,4 @@ -add_definitions(-D_DLL -D__USE_CRTIMP) - add_executable(telnetd telnetd.c serviceentry.c diff --git a/reactos/base/shell/explorer/CMakeLists.txt b/reactos/base/shell/explorer/CMakeLists.txt index ded70541558..14f73046157 100644 --- a/reactos/base/shell/explorer/CMakeLists.txt +++ b/reactos/base/shell/explorer/CMakeLists.txt @@ -10,8 +10,7 @@ set_unicode() add_definitions( -DWIN32 - -D__WINDRES__ - -D_DLL -D__USE_CRTIMP) + -D__WINDRES__) #add_pch(explorer precomp.h) include_directories(${CMAKE_CURRENT_SOURCE_DIR}) @@ -67,9 +66,7 @@ target_link_libraries(explorer uuid) add_importlibs(explorer advapi32 gdi32 user32 ws2_32 msimg32 comctl32 ole32 oleaut32 shell32 notifyhook msvcrt kernel32 ntdll) - set_image_base(explorer 0x00400000) - add_dependencies(explorer psdk) add_cd_file(TARGET explorer DESTINATION reactos FOR all) add_cd_file(FILE ${CMAKE_CURRENT_SOURCE_DIR}/explorer-cfg-template.xml DESTINATION reactos FOR all) diff --git a/reactos/base/system/bootok/CMakeLists.txt b/reactos/base/system/bootok/CMakeLists.txt index e59cd62ce20..bcd13f747ac 100644 --- a/reactos/base/system/bootok/CMakeLists.txt +++ b/reactos/base/system/bootok/CMakeLists.txt @@ -1,6 +1,4 @@ -add_definitions(-D_DLL -D__USE_CRTIMP) - set_unicode() add_executable(bootok bootok.c bootok.rc) diff --git a/reactos/base/system/expand/CMakeLists.txt b/reactos/base/system/expand/CMakeLists.txt index d82276adcfc..5a680bfa97c 100644 --- a/reactos/base/system/expand/CMakeLists.txt +++ b/reactos/base/system/expand/CMakeLists.txt @@ -1,6 +1,4 @@ -add_definitions(-D_DLL -D__USE_CRTIMP) - include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine) add_executable(expand expand.c expand.rc) diff --git a/reactos/base/system/format/CMakeLists.txt b/reactos/base/system/format/CMakeLists.txt index ba1aa8da7c5..5973db5f814 100644 --- a/reactos/base/system/format/CMakeLists.txt +++ b/reactos/base/system/format/CMakeLists.txt @@ -1,7 +1,4 @@ -add_definitions(-D_DLL -D__USE_CRTIMP) - -include_directories(.) set_rc_compiler() add_executable(format format.c format.rc) diff --git a/reactos/base/system/msiexec/CMakeLists.txt b/reactos/base/system/msiexec/CMakeLists.txt index 9e4c2562343..2d19d4f98da 100644 --- a/reactos/base/system/msiexec/CMakeLists.txt +++ b/reactos/base/system/msiexec/CMakeLists.txt @@ -1,7 +1,5 @@ -add_definitions( - -D_DLL -D__USE_CRTIMP - -D__WINESRC__) +add_definitions(-D__WINESRC__) include_directories(${REACTOS_SOURCE_DIR}/include/wine) @@ -13,7 +11,6 @@ add_executable(msiexec rsrc.rc) set_module_type(msiexec win32gui) - target_link_libraries(msiexec uuid wine) add_importlibs(msiexec user32 advapi32 ole32 msi msvcrt kernel32 ntdll) add_cd_file(TARGET msiexec DESTINATION reactos/system32 FOR all) diff --git a/reactos/base/system/regsvr32/CMakeLists.txt b/reactos/base/system/regsvr32/CMakeLists.txt index c784511eb63..1711f737f4e 100644 --- a/reactos/base/system/regsvr32/CMakeLists.txt +++ b/reactos/base/system/regsvr32/CMakeLists.txt @@ -1,8 +1,5 @@ -add_definitions(-D_DLL -D__USE_CRTIMP) - set_unicode() -include_directories(.) set_rc_compiler() add_executable(regsvr32 regsvr32.c regsvr32.rc) diff --git a/reactos/base/system/subst/CMakeLists.txt b/reactos/base/system/subst/CMakeLists.txt index 4319b5e9b34..6b9c5828f74 100644 --- a/reactos/base/system/subst/CMakeLists.txt +++ b/reactos/base/system/subst/CMakeLists.txt @@ -1,9 +1,6 @@ -include_directories(.) set_rc_compiler() -add_definitions(-D_DLL -D__USE_CRTIMP) - add_executable(subst subst.c subst.rc) set_module_type(subst win32cui) diff --git a/reactos/cmake/CMakeMacros.cmake b/reactos/cmake/CMakeMacros.cmake index bca1385db43..09ea187aa6b 100644 --- a/reactos/cmake/CMakeMacros.cmake +++ b/reactos/cmake/CMakeMacros.cmake @@ -231,6 +231,7 @@ macro(add_importlibs MODULE) add_dependency_node(${MODULE}) foreach(LIB ${ARGN}) if ("${LIB}" MATCHES "msvcrt") + add_definitions(-D_DLL -D__USE_CRTIMP) target_link_libraries(${MODULE} msvcrtex) endif() target_link_libraries(${MODULE} ${CMAKE_BINARY_DIR}/importlibs/lib${LIB}${CMAKE_STATIC_LIBRARY_SUFFIX}) diff --git a/reactos/dll/3rdparty/dxtn/CMakeLists.txt b/reactos/dll/3rdparty/dxtn/CMakeLists.txt index d581cbc516b..d4b2425c039 100644 --- a/reactos/dll/3rdparty/dxtn/CMakeLists.txt +++ b/reactos/dll/3rdparty/dxtn/CMakeLists.txt @@ -1,6 +1,4 @@ -add_definitions(-D_DLL -D__USE_CRTIMP) - spec2def(dxtn.dll dxtn.spec) add_library(dxtn SHARED diff --git a/reactos/dll/3rdparty/libjpeg/CMakeLists.txt b/reactos/dll/3rdparty/libjpeg/CMakeLists.txt index 7805ac5e282..1356e31a0f0 100644 --- a/reactos/dll/3rdparty/libjpeg/CMakeLists.txt +++ b/reactos/dll/3rdparty/libjpeg/CMakeLists.txt @@ -4,8 +4,7 @@ add_definitions( -D_WINDOWS -D_MBCS -DJPEG_DLL - -Dmain=mainptr - -D_DLL -D__USE_CRTIMP) + -Dmain=mainptr) include_directories( ${REACTOS_SOURCE_DIR}/include/reactos/libs/libjpeg @@ -60,9 +59,6 @@ add_library(libjpeg SHARED jmemnobs.c) set_entrypoint(libjpeg 0) - add_importlibs(libjpeg msvcrt kernel32) - add_dependencies(libjpeg psdk) - add_cd_file(TARGET libjpeg DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/3rdparty/libpng/CMakeLists.txt b/reactos/dll/3rdparty/libpng/CMakeLists.txt index 4c5d4ae4793..199e59a1d9e 100644 --- a/reactos/dll/3rdparty/libpng/CMakeLists.txt +++ b/reactos/dll/3rdparty/libpng/CMakeLists.txt @@ -3,8 +3,7 @@ add_definitions( -DWIN32 -DNDEBUG -D_WINDOWS - -DPNG_BUILD_DLL - -D_DLL -D__USE_CRTIMP) + -DPNG_BUILD_DLL) include_directories( ${REACTOS_SOURCE_DIR}/include/reactos/libs/libpng @@ -29,11 +28,7 @@ add_library(libpng SHARED pngwutil.c) set_entrypoint(libpng 0) - target_link_libraries(libpng zlib) - add_importlibs(libpng msvcrt kernel32) - add_dependencies(libpng psdk) - add_cd_file(TARGET libpng DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/3rdparty/libtiff/CMakeLists.txt b/reactos/dll/3rdparty/libtiff/CMakeLists.txt index 2586552d5fe..a83ca57ebd5 100644 --- a/reactos/dll/3rdparty/libtiff/CMakeLists.txt +++ b/reactos/dll/3rdparty/libtiff/CMakeLists.txt @@ -4,8 +4,7 @@ add_definitions( -DNDEBUG -DBUILD_LIBTIFF_DLL -DDLL_EXPORT - -DUSE_WIN32_FILEIO - -D_DLL -D__USE_CRTIMP) + -DUSE_WIN32_FILEIO) include_directories( ${REACTOS_SOURCE_DIR}/include/reactos/libs/libtiff @@ -52,11 +51,7 @@ add_library(libtiff SHARED tif_zip.c) set_entrypoint(libtiff 0) - target_link_libraries(libtiff zlib getopt) - add_importlibs(libtiff user32 msvcrt kernel32) - add_dependencies(libtiff psdk) - add_cd_file(TARGET libtiff DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/3rdparty/libxslt/CMakeLists.txt b/reactos/dll/3rdparty/libxslt/CMakeLists.txt index b56c8b4d1e3..882cef34c3e 100644 --- a/reactos/dll/3rdparty/libxslt/CMakeLists.txt +++ b/reactos/dll/3rdparty/libxslt/CMakeLists.txt @@ -8,8 +8,7 @@ add_definitions( -DHAVE_WIN32_THREADS -D_REENTRANT -D_WINSOCKAPI_ - -DLIBXML_STATIC - -D_DLL -D__USE_CRTIMP) + -DLIBXML_STATIC) add_library(libxslt SHARED attributes.c @@ -33,14 +32,12 @@ add_library(libxslt SHARED xsltutils.c) set_entrypoint(libxslt 0) - target_link_libraries(libxslt libxml2) - add_importlibs(libxslt msvcrt ws2_32 kernel32) + if(MSVC) -add_importlibs(libxslt ntdll) + add_importlibs(libxslt ntdll) endif() add_dependencies(libxslt psdk) - add_cd_file(TARGET libxslt DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/3rdparty/mesa32/CMakeLists.txt b/reactos/dll/3rdparty/mesa32/CMakeLists.txt index 49e25ec7fb1..c69a6cbfeae 100644 --- a/reactos/dll/3rdparty/mesa32/CMakeLists.txt +++ b/reactos/dll/3rdparty/mesa32/CMakeLists.txt @@ -1,22 +1,21 @@ if(NOT MSVC) -add_definitions(-w) + add_compiler_flags(-w) endif() add_definitions( -DUSE_EXTERNAL_DXTN_LIB=1 -DBUILD_GL32 -DWIN32 - -DUSE_3DNOW_ASM - -D_DLL -D__USE_CRTIMP) + -DUSE_3DNOW_ASM) if(ARCH MATCHES i386) -add_definitions( - -DUSE_X86_ASM - -DUSE_MMX_ASM - -DUSE_SSE_ASM) + add_definitions( + -DUSE_X86_ASM + -DUSE_MMX_ASM + -DUSE_SSE_ASM) else() -add_definitions(-DGL_NO_STDCALL) + add_definitions(-DGL_NO_STDCALL) endif(ARCH MATCHES i386) if(NOT MSVC) @@ -229,44 +228,39 @@ list(APPEND SOURCE src/vbo/vbo_split_inplace.c src/drivers/windows/icd/mesa.def) -set_source_files_properties(src/drivers/windows/icd/mesa.def PROPERTIES EXTERNAL_OBJECT TRUE) - if(ARCH MATCHES i386) -list(APPEND SOURCE - src/tnl/t_vertex_sse.c - src/x86/3dnow.c - src/x86/3dnow_normal.S - src/x86/3dnow_xform1.S - src/x86/3dnow_xform2.S - src/x86/3dnow_xform3.S - src/x86/3dnow_xform4.S - src/x86/common_x86.c - src/x86/common_x86_asm.S - src/x86/glapi_x86.S - src/x86/mmx_blend.S - src/x86/read_rgba_span_x86.S - src/x86/sse_normal.S - src/x86/sse_xform1.S - src/x86/sse_xform2.S - src/x86/sse_xform3.S - src/x86/sse_xform4.S - src/x86/sse.c - src/x86/x86.c - src/x86/x86_cliptest.S - src/x86/x86_xform2.S - src/x86/x86_xform3.S - src/x86/x86_xform4.S - src/x86/rtasm/x86sse.c) + list(APPEND SOURCE + src/tnl/t_vertex_sse.c + src/x86/3dnow.c + src/x86/3dnow_normal.S + src/x86/3dnow_xform1.S + src/x86/3dnow_xform2.S + src/x86/3dnow_xform3.S + src/x86/3dnow_xform4.S + src/x86/common_x86.c + src/x86/common_x86_asm.S + src/x86/glapi_x86.S + src/x86/mmx_blend.S + src/x86/read_rgba_span_x86.S + src/x86/sse_normal.S + src/x86/sse_xform1.S + src/x86/sse_xform2.S + src/x86/sse_xform3.S + src/x86/sse_xform4.S + src/x86/sse.c + src/x86/x86.c + src/x86/x86_cliptest.S + src/x86/x86_xform2.S + src/x86/x86_xform3.S + src/x86/x86_xform4.S + src/x86/rtasm/x86sse.c) else() -list(APPEND SOURCE src/x86-64/x86-64.c src/x86-64/xform4.S) -endif(ARCH MATCHES i386) + list(APPEND SOURCE src/x86-64/x86-64.c src/x86-64/xform4.S) +endif() add_library(mesa32 SHARED ${SOURCE}) set_entrypoint(mesa32 0) - add_importlibs(mesa32 gdi32 user32 msvcrt kernel32 ntdll) - add_dependencies(mesa32 psdk) - add_cd_file(TARGET mesa32 DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/cpl/desk/CMakeLists.txt b/reactos/dll/cpl/desk/CMakeLists.txt index 51909fc6525..d7d8d8214a7 100644 --- a/reactos/dll/cpl/desk/CMakeLists.txt +++ b/reactos/dll/cpl/desk/CMakeLists.txt @@ -1,11 +1,9 @@ -set_unicode() - -add_definitions( - -D_WIN32 - -D_DLL -D__USE_CRTIMP) +add_definitions(-D_WIN32) +set_unicode() set_rc_compiler() + spec2def(desk.cpl desk.spec) add_library(desk SHARED diff --git a/reactos/dll/cpl/intl/CMakeLists.txt b/reactos/dll/cpl/intl/CMakeLists.txt index cae9ec0d80e..a1f1aa5ab29 100644 --- a/reactos/dll/cpl/intl/CMakeLists.txt +++ b/reactos/dll/cpl/intl/CMakeLists.txt @@ -2,8 +2,6 @@ set_unicode() set_rc_compiler() -add_definitions(-D_DLL -D__USE_CRTIMP) - spec2def(intl.cpl intl.spec) add_library(intl SHARED diff --git a/reactos/dll/cpl/main/CMakeLists.txt b/reactos/dll/cpl/main/CMakeLists.txt index 0f6a5f56840..e193a61032f 100644 --- a/reactos/dll/cpl/main/CMakeLists.txt +++ b/reactos/dll/cpl/main/CMakeLists.txt @@ -2,8 +2,6 @@ set_unicode() set_rc_compiler() -add_definitions(-D_DLL -D__USE_CRTIMP) - spec2def(main.cpl main.spec) add_library(main SHARED diff --git a/reactos/dll/cpl/mmsys/CMakeLists.txt b/reactos/dll/cpl/mmsys/CMakeLists.txt index f0078e88a03..5206561480f 100644 --- a/reactos/dll/cpl/mmsys/CMakeLists.txt +++ b/reactos/dll/cpl/mmsys/CMakeLists.txt @@ -2,8 +2,6 @@ set_unicode() set_rc_compiler() -add_definitions(-D_DLL -D__USE_CRTIMP) - spec2def(mmsys.cpl mmsys.spec) add_library(mmsys SHARED diff --git a/reactos/dll/directx/dsound/CMakeLists.txt b/reactos/dll/directx/dsound/CMakeLists.txt index c4b7218871a..84f3782c9ff 100644 --- a/reactos/dll/directx/dsound/CMakeLists.txt +++ b/reactos/dll/directx/dsound/CMakeLists.txt @@ -1,8 +1,7 @@ add_definitions( -D_WINE - -D_USE_MATH_DEFINES - -D_DLL -D__USE_CRTIMP) + -D_USE_MATH_DEFINES) include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine) diff --git a/reactos/dll/directx/ksproxy/CMakeLists.txt b/reactos/dll/directx/ksproxy/CMakeLists.txt index 2c3c19ac43f..68b8c6853ac 100644 --- a/reactos/dll/directx/ksproxy/CMakeLists.txt +++ b/reactos/dll/directx/ksproxy/CMakeLists.txt @@ -2,7 +2,6 @@ spec2def(ksproxy.ax ksproxy.spec) add_definitions( - -D_DLL -D__USE_CRTIMP -DNATIVE_CPP_INCLUDE=${REACTOS_SOURCE_DIR}/include/c++ -DNATIVE_C_INCLUDE=${REACTOS_SOURCE_DIR}/include/crt) @@ -37,10 +36,10 @@ else() #FIXME : can't build if this is enabled, check if this is needed #set_target_properties(ksproxy PROPERTIES COMPILE_FLAGS "-fno-exceptions -fno-rtti") target_link_libraries(ksproxy -lsupc++ -lgcc -lmingw32 oldnames) -endif(MSVC) +endif() + +target_link_libraries(ksproxy stlport strmiids) -target_link_libraries(ksproxy stlport strmiids) - add_importlibs(ksproxy advapi32 ole32 diff --git a/reactos/dll/directx/qedit/CMakeLists.txt b/reactos/dll/directx/qedit/CMakeLists.txt index 2d393e1ae44..b088850deb6 100644 --- a/reactos/dll/directx/qedit/CMakeLists.txt +++ b/reactos/dll/directx/qedit/CMakeLists.txt @@ -1,9 +1,7 @@ set_unicode() -add_definitions( - -D__WINESRC__ - -D_DLL -D__USE_CRTIMP) +add_definitions(-D__WINESRC__) remove_definitions(-D_WIN32_WINNT=0x502) add_definitions(-D_WIN32_WINNT=0x600) diff --git a/reactos/dll/directx/quartz/CMakeLists.txt b/reactos/dll/directx/quartz/CMakeLists.txt index 946d73eba30..338fd2e5a97 100644 --- a/reactos/dll/directx/quartz/CMakeLists.txt +++ b/reactos/dll/directx/quartz/CMakeLists.txt @@ -6,9 +6,7 @@ add_definitions( -D__WINESRC__ -DENTRY_PREFIX=QUARTZ_ -DREGISTER_PROXY_DLL - -DPROXY_DELEGATION - -D_DLL - -D__USE_CRTIMP) + -DPROXY_DELEGATION) include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine) diff --git a/reactos/dll/win32/avifil32/CMakeLists.txt b/reactos/dll/win32/avifil32/CMakeLists.txt index 6edb848c253..d1041cbc50b 100644 --- a/reactos/dll/win32/avifil32/CMakeLists.txt +++ b/reactos/dll/win32/avifil32/CMakeLists.txt @@ -1,7 +1,5 @@ -add_definitions( - -D__WINESRC__ - -D_DLL -D__USE_CRTIMP) +add_definitions(-D__WINESRC__) remove_definitions(-D_WIN32_WINNT=0x502) add_definitions(-D_WIN32_WINNT=0x600) diff --git a/reactos/dll/win32/comdlg32/CMakeLists.txt b/reactos/dll/win32/comdlg32/CMakeLists.txt index 83f46ae9056..90918029bb6 100644 --- a/reactos/dll/win32/comdlg32/CMakeLists.txt +++ b/reactos/dll/win32/comdlg32/CMakeLists.txt @@ -1,8 +1,7 @@ add_definitions( -D__WINESRC__ - -D_WINE - -D_DLL -D__USE_CRTIMP) + -D_WINE) include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine) diff --git a/reactos/dll/win32/crypt32/CMakeLists.txt b/reactos/dll/win32/crypt32/CMakeLists.txt index c4492e3019e..e2bae71dea4 100644 --- a/reactos/dll/win32/crypt32/CMakeLists.txt +++ b/reactos/dll/win32/crypt32/CMakeLists.txt @@ -1,8 +1,6 @@ add_definitions( -D__WINESRC__ - -D_DLL - -D__USE_CRTIMP -D_WINE) remove_definitions(-D_WIN32_WINNT=0x502) @@ -54,6 +52,5 @@ target_link_libraries(crypt32 oldnames) add_importlibs(crypt32 user32 advapi32 msvcrt kernel32 ntdll) - add_cd_file(TARGET crypt32 DESTINATION reactos/system32 FOR all) add_importlib_target(crypt32.spec) diff --git a/reactos/dll/win32/dbghelp/CMakeLists.txt b/reactos/dll/win32/dbghelp/CMakeLists.txt index 4b1c073b8a8..59eacd22aba 100644 --- a/reactos/dll/win32/dbghelp/CMakeLists.txt +++ b/reactos/dll/win32/dbghelp/CMakeLists.txt @@ -1,16 +1,14 @@ add_definitions( -D__WINESRC__ - -D_DLL - -D__USE_CRTIMP -D_WINE -DHAVE_REGEX_H -DHAVE_ALLOCA_H -D_IMAGEHLP_SOURCE_) if(ARCH MATCHES amd64) -add_definitions(-DUNW_FLAG_NHANDLER=0 -DUNW_FLAG_EHANDLER=1 -DUNW_FLAG_UHANDLER=2 -DUNW_FLAG_CHAININFO=3) -endif(ARCH MATCHES amd64) + add_definitions(-DUNW_FLAG_NHANDLER=0 -DUNW_FLAG_EHANDLER=1 -DUNW_FLAG_UHANDLER=2 -DUNW_FLAG_CHAININFO=3) +endif() include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine) @@ -49,7 +47,6 @@ list(APPEND SOURCE add_library(dbghelp SHARED ${SOURCE}) set_module_type(dbghelp win32dll) - target_link_libraries(dbghelp wine ${PSEH_LIB} diff --git a/reactos/dll/win32/dnsapi/CMakeLists.txt b/reactos/dll/win32/dnsapi/CMakeLists.txt index ffeea959187..da10aab172c 100644 --- a/reactos/dll/win32/dnsapi/CMakeLists.txt +++ b/reactos/dll/win32/dnsapi/CMakeLists.txt @@ -4,9 +4,7 @@ include_directories( ${REACTOS_SOURCE_DIR}/lib/3rdparty/adns/src ${REACTOS_SOURCE_DIR}/lib/3rdparty/adns/adns_win32) -add_definitions( - -D_DLL -D__USE_CRTIMP - -DADNS_JGAA_WIN32) +add_definitions(-DADNS_JGAA_WIN32) spec2def(dnsapi.dll dnsapi.spec) @@ -24,7 +22,6 @@ list(APPEND SOURCE add_library(dnsapi SHARED ${SOURCE}) set_entrypoint(dnsapi 0) - target_link_libraries(dnsapi adns) add_importlibs(dnsapi user32 ws2_32 iphlpapi msvcrt kernel32 ntdll) add_pch(dnsapi dnsapi/precomp.h) diff --git a/reactos/dll/win32/gdi32/CMakeLists.txt b/reactos/dll/win32/gdi32/CMakeLists.txt index bf11f6a9419..a3aaeb13479 100644 --- a/reactos/dll/win32/gdi32/CMakeLists.txt +++ b/reactos/dll/win32/gdi32/CMakeLists.txt @@ -1,17 +1,15 @@ set_unicode() -add_definitions( - -D_DLL -D__USE_CRTIMP - -DLANGPACK) +add_definitions(-DLANGPACK) include_directories(include) spec2def(gdi32.dll gdi32.spec) if(ARCH MATCHES i386) -list(APPEND SOURCE - objects/efloat.c) + list(APPEND SOURCE + objects/efloat.c) endif() list(APPEND SOURCE diff --git a/reactos/dll/win32/gdiplus/CMakeLists.txt b/reactos/dll/win32/gdiplus/CMakeLists.txt index 696628e6114..a5aed46ee09 100644 --- a/reactos/dll/win32/gdiplus/CMakeLists.txt +++ b/reactos/dll/win32/gdiplus/CMakeLists.txt @@ -1,8 +1,7 @@ add_definitions( -D__WINESRC__ - -D_USE_MATH_DEFINES - -D_DLL -D__USE_CRTIMP) + -D_USE_MATH_DEFINES) include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine) @@ -31,7 +30,6 @@ list(APPEND SOURCE add_library(gdiplus SHARED ${SOURCE}) set_module_type(gdiplus win32dll) - target_link_libraries(gdiplus uuid wine) add_importlibs(gdiplus @@ -46,9 +44,9 @@ add_importlibs(gdiplus ntdll) add_importlib_target(gdiplus.spec) - + if(ARCH MATCHES amd64) -target_link_libraries(gdiplus crt) -endif(ARCH MATCHES amd64) + target_link_libraries(gdiplus crt) +endif() add_cd_file(TARGET gdiplus DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/win32/glu32/CMakeLists.txt b/reactos/dll/win32/glu32/CMakeLists.txt index e4566c2ac88..68a4b03a093 100644 --- a/reactos/dll/win32/glu32/CMakeLists.txt +++ b/reactos/dll/win32/glu32/CMakeLists.txt @@ -2,8 +2,7 @@ add_definitions( -DRESOLVE_3D_TEXTURE_SUPPORT -DBUILD_GL32 - -DLIBRARYBUILD - -D_DLL -D__USE_CRTIMP) + -DLIBRARYBUILD) include_directories( include @@ -110,7 +109,6 @@ list(APPEND SOURCE add_library(glu32 SHARED ${SOURCE}) set_entrypoint(glu32 0) - target_link_libraries(glu32 stlport -lsupc++ -lgcc -lmingw32 oldnames) add_importlibs(glu32 diff --git a/reactos/dll/win32/imaadp32.acm/CMakeLists.txt b/reactos/dll/win32/imaadp32.acm/CMakeLists.txt index 3693cd025ad..772071b846b 100644 --- a/reactos/dll/win32/imaadp32.acm/CMakeLists.txt +++ b/reactos/dll/win32/imaadp32.acm/CMakeLists.txt @@ -1,8 +1,5 @@ -add_definitions( - -D_DLL -D__USE_CRTIMP - -D__WINESRC__) - +add_definitions(-D__WINESRC__) include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine) spec2def(imaadp32.acm imaadp32.acm.spec) @@ -15,9 +12,7 @@ add_library(imaadp32.acm SHARED ${SOURCE}) set_entrypoint(imaadp32.acm 0) set_target_properties(imaadp32.acm PROPERTIES SUFFIX "") - target_link_libraries(imaadp32.acm wine) - add_importlibs(imaadp32.acm winmm user32 msvcrt kernel32 ntdll) add_dependencies(imaadp32.acm psdk) add_cd_file(TARGET imaadp32.acm DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/win32/imagehlp/CMakeLists.txt b/reactos/dll/win32/imagehlp/CMakeLists.txt index 157f91d5923..573098c670e 100644 --- a/reactos/dll/win32/imagehlp/CMakeLists.txt +++ b/reactos/dll/win32/imagehlp/CMakeLists.txt @@ -1,8 +1,5 @@ -add_definitions( - -D_DLL -D__USE_CRTIMP - -D_IMAGEHLP_SOURCE_) - +add_definitions(-D_IMAGEHLP_SOURCE_) include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine) spec2def(imagehlp.dll imagehlp.spec) @@ -19,12 +16,8 @@ list(APPEND SOURCE add_library(imagehlp SHARED ${SOURCE}) set_module_type(imagehlp win32dll) - target_link_libraries(imagehlp wine) - add_importlibs(imagehlp dbghelp msvcrt kernel32 ntdll) add_importlib_target(imagehlp.spec) - add_pch(imagehlp precomp.h) - add_cd_file(TARGET imagehlp DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/win32/inetmib1/CMakeLists.txt b/reactos/dll/win32/inetmib1/CMakeLists.txt index ac98360c7ea..84b92fc5424 100644 --- a/reactos/dll/win32/inetmib1/CMakeLists.txt +++ b/reactos/dll/win32/inetmib1/CMakeLists.txt @@ -1,8 +1,5 @@ -add_definitions( - -D__WINESRC__ - -D_DLL -D__USE_CRTIMP) - +add_definitions(-D__WINESRC__) include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine) spec2def(inetmib1.dll inetmib1.spec) @@ -15,7 +12,6 @@ list(APPEND SOURCE add_library(inetmib1 SHARED ${SOURCE}) set_module_type(inetmib1 win32dll) - target_link_libraries(inetmib1 wine) add_importlibs(inetmib1 diff --git a/reactos/dll/win32/iphlpapi/CMakeLists.txt b/reactos/dll/win32/iphlpapi/CMakeLists.txt index 8bc6ca2132e..c8ae984d34a 100644 --- a/reactos/dll/win32/iphlpapi/CMakeLists.txt +++ b/reactos/dll/win32/iphlpapi/CMakeLists.txt @@ -1,8 +1,6 @@ set_unicode() -add_definitions(-D_DLL -D__USE_CRTIMP) - include_directories( ${REACTOS_SOURCE_DIR}/include/reactos/wine ${REACTOS_SOURCE_DIR}/dll/win32/dhcpcsvc/include diff --git a/reactos/dll/win32/itss/CMakeLists.txt b/reactos/dll/win32/itss/CMakeLists.txt index fd53de89a2b..e790da075ea 100644 --- a/reactos/dll/win32/itss/CMakeLists.txt +++ b/reactos/dll/win32/itss/CMakeLists.txt @@ -1,8 +1,5 @@ -add_definitions( - -D__WINESRC__ - -D_DLL -D__USE_CRTIMP) - +add_definitions(-D__WINESRC__) include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine) set_rc_compiler() @@ -24,7 +21,6 @@ list(APPEND SOURCE add_library(itss SHARED ${SOURCE}) set_module_type(itss win32dll) - target_link_libraries(itss uuid wine) add_importlibs(itss diff --git a/reactos/dll/win32/jscript/CMakeLists.txt b/reactos/dll/win32/jscript/CMakeLists.txt index 08d53fc21e4..27afb3d6f0c 100644 --- a/reactos/dll/win32/jscript/CMakeLists.txt +++ b/reactos/dll/win32/jscript/CMakeLists.txt @@ -1,5 +1,6 @@ add_typelib(jsglobal jsglobal.idl) + add_dependencies(jsglobal stdole2) remove_definitions(-D_WIN32_WINNT=0x502) @@ -8,8 +9,6 @@ add_definitions(-D_WIN32_WINNT=0x600) add_definitions( -D__WINESRC__ -D_USE_MATH_DEFINES - -D_DLL - -D__USE_CRTIMP -Disinf=!_finite -Disnan=_isnan) diff --git a/reactos/dll/win32/mciwave/CMakeLists.txt b/reactos/dll/win32/mciwave/CMakeLists.txt index d425aa422ab..48e6d5af48a 100644 --- a/reactos/dll/win32/mciwave/CMakeLists.txt +++ b/reactos/dll/win32/mciwave/CMakeLists.txt @@ -1,7 +1,6 @@ add_definitions( -D__WINESRC__ - -D_DLL -D__USE_CRTIMP -D_WINE) include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine) diff --git a/reactos/dll/win32/mlang/CMakeLists.txt b/reactos/dll/win32/mlang/CMakeLists.txt index 4808863868f..d30cbcc24de 100644 --- a/reactos/dll/win32/mlang/CMakeLists.txt +++ b/reactos/dll/win32/mlang/CMakeLists.txt @@ -1,7 +1,5 @@ -add_definitions( - -D__WINESRC__ - -D_DLL -D__USE_CRTIMP) +add_definitions(-D__WINESRC__) remove_definitions(-D_WIN32_WINNT=0x502) add_definitions(-D_WIN32_WINNT=0x600) @@ -19,7 +17,6 @@ list(APPEND SOURCE add_library(mlang SHARED ${SOURCE}) set_entrypoint(mlang 0) - target_link_libraries(mlang uuid wine) add_importlibs(mlang diff --git a/reactos/dll/win32/msacm32/CMakeLists.txt b/reactos/dll/win32/msacm32/CMakeLists.txt index c163adb51a2..8eb85ac3eb1 100644 --- a/reactos/dll/win32/msacm32/CMakeLists.txt +++ b/reactos/dll/win32/msacm32/CMakeLists.txt @@ -1,7 +1,6 @@ set_unicode() -add_definitions(-D_DLL -D__USE_CRTIMP) include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine) set_rc_compiler() diff --git a/reactos/dll/win32/msadp32.acm/CMakeLists.txt b/reactos/dll/win32/msadp32.acm/CMakeLists.txt index 1c73fd654b1..6a2f55874c3 100644 --- a/reactos/dll/win32/msadp32.acm/CMakeLists.txt +++ b/reactos/dll/win32/msadp32.acm/CMakeLists.txt @@ -1,8 +1,5 @@ -add_definitions( - -D_DLL -D__USE_CRTIMP - -D__WINESRC__) - +add_definitions(-D__WINESRC__) include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine) spec2def(msadp32.acm msadp32.acm.spec) diff --git a/reactos/dll/win32/msctf/CMakeLists.txt b/reactos/dll/win32/msctf/CMakeLists.txt index 634e00dde1c..b4ec9dfdc3b 100644 --- a/reactos/dll/win32/msctf/CMakeLists.txt +++ b/reactos/dll/win32/msctf/CMakeLists.txt @@ -1,7 +1,5 @@ -add_definitions( - -D__WINESRC__ - -D_DLL -D__USE_CRTIMP) +add_definitions(-D__WINESRC__) remove_definitions(-D_WIN32_WINNT=0x502) add_definitions(-D_WIN32_WINNT=0x600) @@ -31,7 +29,6 @@ list(APPEND SOURCE add_library(msctf SHARED ${SOURCE}) set_module_type(msctf win32dll) - target_link_libraries(msctf uuid wine) add_importlibs(msctf ole32 oleaut32 user32 advapi32 msvcrt kernel32 ntdll) add_cd_file(TARGET msctf DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/win32/msg711.acm/CMakeLists.txt b/reactos/dll/win32/msg711.acm/CMakeLists.txt index 6f6deeb3192..4ffcd516a7c 100644 --- a/reactos/dll/win32/msg711.acm/CMakeLists.txt +++ b/reactos/dll/win32/msg711.acm/CMakeLists.txt @@ -1,8 +1,5 @@ -add_definitions( - -D_DLL -D__USE_CRTIMP - -D__WINESRC__) - +add_definitions(-D__WINESRC__) include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine) spec2def(msg711.acm msg711.acm.spec) @@ -15,7 +12,6 @@ add_library(msg711.acm SHARED ${SOURCE}) set_entrypoint(msg711.acm 0) set_target_properties(msg711.acm PROPERTIES SUFFIX "") - target_link_libraries(msg711.acm wine) add_importlibs(msg711.acm winmm user32 msvcrt kernel32 ntdll) add_dependencies(msg711.acm psdk) diff --git a/reactos/dll/win32/msgsm32.acm/CMakeLists.txt b/reactos/dll/win32/msgsm32.acm/CMakeLists.txt index 1de7b02958c..d5fadf4b1c2 100644 --- a/reactos/dll/win32/msgsm32.acm/CMakeLists.txt +++ b/reactos/dll/win32/msgsm32.acm/CMakeLists.txt @@ -1,8 +1,5 @@ -add_definitions( - -D_DLL -D__USE_CRTIMP - -D__WINESRC__) - +add_definitions(-D__WINESRC__) include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine) spec2def(msgsm32.acm msgsm32.acm.spec) @@ -15,9 +12,7 @@ add_library(msgsm32.acm SHARED ${SOURCE}) set_entrypoint(msgsm32.acm 0) set_target_properties(msgsm32.acm PROPERTIES SUFFIX "") - target_link_libraries(msgsm32.acm wine) - add_importlibs(msgsm32.acm winmm user32 msvcrt kernel32 ntdll) add_dependencies(msgsm32.acm psdk) add_cd_file(TARGET msgsm32.acm DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/win32/mshtml/CMakeLists.txt b/reactos/dll/win32/mshtml/CMakeLists.txt index 4f174ee0bca..d91ec8a769f 100644 --- a/reactos/dll/win32/mshtml/CMakeLists.txt +++ b/reactos/dll/win32/mshtml/CMakeLists.txt @@ -2,11 +2,7 @@ remove_definitions(-D_WIN32_WINNT=0x502) add_definitions(-D_WIN32_WINNT=0x600) -add_definitions( - -D__WINESRC__ - -D_DLL - -D__USE_CRTIMP) - +add_definitions(-D__WINESRC__) include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine) add_idl_Headers(mshtml_nsiface_header nsiface.idl) diff --git a/reactos/dll/win32/msi/CMakeLists.txt b/reactos/dll/win32/msi/CMakeLists.txt index c7d217c2906..607b8e8c7c7 100644 --- a/reactos/dll/win32/msi/CMakeLists.txt +++ b/reactos/dll/win32/msi/CMakeLists.txt @@ -14,7 +14,7 @@ list(APPEND SOURCE action.c alter.c appsearch.c - assembly.c + assembly.c automation.c classes.c cond.tab.c @@ -68,13 +68,9 @@ endif() add_library(msi SHARED ${SOURCE}) add_idl_Headers(msi_idlheader msiserver.idl) - add_typelib(msi_tlb msiserver.idl) - set_module_type(msi win32dll) - target_link_libraries(msi uuid ${PSEH_LIB} wine) - add_dependencies(msi msi_idlheader msi_tlb) add_importlibs(msi diff --git a/reactos/dll/win32/msrle32/CMakeLists.txt b/reactos/dll/win32/msrle32/CMakeLists.txt index 9aedf677b8f..b79aa8bd5f8 100644 --- a/reactos/dll/win32/msrle32/CMakeLists.txt +++ b/reactos/dll/win32/msrle32/CMakeLists.txt @@ -1,8 +1,5 @@ -add_definitions( - -D__WINESRC__ - -D_DLL -D__USE_CRTIMP) - +add_definitions(-D__WINESRC__) include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine) set_rc_compiler() diff --git a/reactos/dll/win32/msxml3/CMakeLists.txt b/reactos/dll/win32/msxml3/CMakeLists.txt index 40052a11d9e..0959e4a2ddb 100644 --- a/reactos/dll/win32/msxml3/CMakeLists.txt +++ b/reactos/dll/win32/msxml3/CMakeLists.txt @@ -8,17 +8,16 @@ add_definitions(-D_WIN32_WINNT=0x601) add_definitions( -D__WINESRC__ -D_WINE - -DLIBXML_STATIC - -D_DLL - -D__USE_CRTIMP) + -DLIBXML_STATIC) if(MSVC) -add_definitions(/FIwine/typeof.h) + add_compiler_flags(/FIwine/typeof.h) endif(MSVC) include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine) set_rc_compiler() + spec2def(msxml3.dll msxml3.spec) list(APPEND SOURCE diff --git a/reactos/dll/win32/odbc32/CMakeLists.txt b/reactos/dll/win32/odbc32/CMakeLists.txt index 84aeb39ce6d..da84e343c27 100644 --- a/reactos/dll/win32/odbc32/CMakeLists.txt +++ b/reactos/dll/win32/odbc32/CMakeLists.txt @@ -1,6 +1,5 @@ add_definitions(-D__WINESRC__) -add_definitions(-D_DLL -D__USE_CRTIMP) include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine) @@ -23,5 +22,4 @@ add_importlibs(odbc32 kernel32 ntdll) - add_cd_file(TARGET odbc32 DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/win32/odbccp32/CMakeLists.txt b/reactos/dll/win32/odbccp32/CMakeLists.txt index 3eb259b7afe..16e60613f59 100644 --- a/reactos/dll/win32/odbccp32/CMakeLists.txt +++ b/reactos/dll/win32/odbccp32/CMakeLists.txt @@ -1,8 +1,5 @@ -add_definitions( - -D__WINESRC__ - -D_DLL -D__USE_CRTIMP) - +add_definitions(-D__WINESRC__) include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine) spec2def(odbccp32.dll odbccp32.spec) @@ -13,8 +10,8 @@ list(APPEND SOURCE ${CMAKE_CURRENT_BINARY_DIR}/odbccp32.def) add_library(odbccp32 SHARED ${SOURCE}) -set_entrypoint(odbccp32 0) +set_entrypoint(odbccp32 0) target_link_libraries(odbccp32 uuid wine) add_importlibs(odbccp32 diff --git a/reactos/dll/win32/opengl32/CMakeLists.txt b/reactos/dll/win32/opengl32/CMakeLists.txt index 5b98cdc1aca..bdf1e4f1ec2 100644 --- a/reactos/dll/win32/opengl32/CMakeLists.txt +++ b/reactos/dll/win32/opengl32/CMakeLists.txt @@ -1,8 +1,6 @@ set_unicode() -add_definitions(-D_DLL -D__USE_CRTIMP) - spec2def(opengl32.dll opengl32.spec) list(APPEND SOURCE diff --git a/reactos/dll/win32/riched20/CMakeLists.txt b/reactos/dll/win32/riched20/CMakeLists.txt index 60362843d05..cf636b6f0c7 100644 --- a/reactos/dll/win32/riched20/CMakeLists.txt +++ b/reactos/dll/win32/riched20/CMakeLists.txt @@ -1,11 +1,9 @@ -add_definitions( - -D__WINESRC__ - -D_DLL -D__USE_CRTIMP) - +add_definitions(-D__WINESRC__) include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine) spec2def(riched20.dll riched20.spec) + set_rc_compiler() list(APPEND SOURCE @@ -51,5 +49,4 @@ add_importlibs(riched20 ntdll) add_importlib_target(riched20.spec) - add_cd_file(TARGET riched20 DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/win32/rsaenh/CMakeLists.txt b/reactos/dll/win32/rsaenh/CMakeLists.txt index 50904526195..49434499d74 100644 --- a/reactos/dll/win32/rsaenh/CMakeLists.txt +++ b/reactos/dll/win32/rsaenh/CMakeLists.txt @@ -1,8 +1,5 @@ -add_definitions( - -D__WINESRC__ - -D_DLL -D__USE_CRTIMP) - +add_definitions(-D__WINESRC__) include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine) spec2def(rsaenh.dll rsaenh.spec) diff --git a/reactos/dll/win32/setupapi/CMakeLists.txt b/reactos/dll/win32/setupapi/CMakeLists.txt index 0858278e369..4cd101c30ec 100644 --- a/reactos/dll/win32/setupapi/CMakeLists.txt +++ b/reactos/dll/win32/setupapi/CMakeLists.txt @@ -2,8 +2,6 @@ set_unicode() add_definitions( - -D_DLL - -D__USE_CRTIMP -D_SETUPAPI_ -D_CFGMGR32_ -Dwcsnicmp=_wcsnicmp) @@ -13,6 +11,7 @@ include_directories( ${REACTOS_BINARY_DIR}/include/reactos/idl) set_rc_compiler() + spec2def(setupapi.dll setupapi.spec) list(APPEND SOURCE @@ -58,6 +57,5 @@ add_importlibs(setupapi kernel32 ntdll) - add_cd_file(TARGET setupapi DESTINATION reactos/system32 FOR all) add_importlib_target(setupapi.spec) diff --git a/reactos/dll/win32/syssetup/CMakeLists.txt b/reactos/dll/win32/syssetup/CMakeLists.txt index 9f8ac236bd0..433fb648119 100644 --- a/reactos/dll/win32/syssetup/CMakeLists.txt +++ b/reactos/dll/win32/syssetup/CMakeLists.txt @@ -1,8 +1,7 @@ -set_unicode() - -add_definitions(-D_DLL -D__USE_CRTIMP) +set_unicode() set_rc_compiler() + spec2def(syssetup.dll syssetup.spec) list(APPEND SOURCE @@ -19,9 +18,7 @@ add_library(syssetup SHARED ${SOURCE}) set_module_type(syssetup win32dll) -target_link_libraries(syssetup - uuid - ${PSEH_LIB}) +target_link_libraries(syssetup uuid ${PSEH_LIB}) add_importlibs(syssetup msvcrt @@ -38,5 +35,4 @@ add_importlibs(syssetup kernel32 ntdll) - add_cd_file(TARGET syssetup DESTINATION reactos/system32 FOR all) diff --git a/reactos/dll/win32/twain_32/CMakeLists.txt b/reactos/dll/win32/twain_32/CMakeLists.txt index 5eb3ac68cf3..597903e8867 100644 --- a/reactos/dll/win32/twain_32/CMakeLists.txt +++ b/reactos/dll/win32/twain_32/CMakeLists.txt @@ -1,6 +1,4 @@ -add_definitions(-D_DLL -D__USE_CRTIMP) - spec2def(twain_32.dll twain_32.spec) list(APPEND SOURCE diff --git a/reactos/dll/win32/user32/CMakeLists.txt b/reactos/dll/win32/user32/CMakeLists.txt index a0f76cc04f1..9ce008ae14e 100644 --- a/reactos/dll/win32/user32/CMakeLists.txt +++ b/reactos/dll/win32/user32/CMakeLists.txt @@ -3,8 +3,6 @@ set_unicode() spec2def(user32.dll user32.spec) -add_definitions(-D_DLL -D__USE_CRTIMP) - include_directories( BEFORE ${REACTOS_SOURCE_DIR}/include/reactos/wine ${REACTOS_SOURCE_DIR}/include/reactos/subsys diff --git a/reactos/dll/win32/winemp3.acm/CMakeLists.txt b/reactos/dll/win32/winemp3.acm/CMakeLists.txt index e948366308d..d1c966ad692 100644 --- a/reactos/dll/win32/winemp3.acm/CMakeLists.txt +++ b/reactos/dll/win32/winemp3.acm/CMakeLists.txt @@ -1,6 +1,5 @@ add_definitions( - -D_DLL -D__USE_CRTIMP -D__WINESRC__ -DWIN32) @@ -16,18 +15,14 @@ add_library(winemp3.acm SHARED set_entrypoint(winemp3.acm 0) set_target_properties(winemp3.acm PROPERTIES SUFFIX "") - -target_link_libraries(winemp3.acm - wine - libmpg123) +target_link_libraries(winemp3.acm wine libmpg123) add_importlibs(winemp3.acm - msvcrt winmm user32 + msvcrt kernel32 ntdll) add_dependencies(winemp3.acm psdk) - -add_cd_file(TARGET winemp3.acm DESTINATION reactos/system32 FOR all) \ No newline at end of file +add_cd_file(TARGET winemp3.acm DESTINATION reactos/system32 FOR all) diff --git a/reactos/lib/3rdparty/libxml2/CMakeLists.txt b/reactos/lib/3rdparty/libxml2/CMakeLists.txt index e8c3ea20a95..39ed9e74ab1 100644 --- a/reactos/lib/3rdparty/libxml2/CMakeLists.txt +++ b/reactos/lib/3rdparty/libxml2/CMakeLists.txt @@ -1,7 +1,5 @@ -include_directories( - . - include) +include_directories(include) add_definitions( -D__MINGW32__ diff --git a/reactos/lib/newinflib/CMakeLists.txt b/reactos/lib/newinflib/CMakeLists.txt index 901bd996132..c33821f335a 100644 --- a/reactos/lib/newinflib/CMakeLists.txt +++ b/reactos/lib/newinflib/CMakeLists.txt @@ -21,7 +21,7 @@ else() add_definitions(-DWINE_UNICODE_API= -D__NO_CTYPE_INLINES -DINFLIB_HOST -DUSE_HOST_WCSFUNCS) if(NOT MSVC) - add_definitions(-Wpointer-arith -Wwrite-strings) + add_compiler_flags(-Wpointer-arith -Wwrite-strings) endif() add_library(inflibhost ${GLOBAL_FILES} ${SOURCE}) target_link_libraries(inflibhost unicode) diff --git a/reactos/lib/smlib/CMakeLists.txt b/reactos/lib/smlib/CMakeLists.txt index 1151b92dde7..ca5c16de4cd 100644 --- a/reactos/lib/smlib/CMakeLists.txt +++ b/reactos/lib/smlib/CMakeLists.txt @@ -1,6 +1,4 @@ -add_definitions(-D_DLL -D__USE_CRTIMP) - include_directories(${REACTOS_SOURCE_DIR}/include/reactos/subsys) list(APPEND SOURCE diff --git a/reactos/subsystems/win32/csrss/win32csr/CMakeLists.txt b/reactos/subsystems/win32/csrss/win32csr/CMakeLists.txt index e42665df0b2..8b694222473 100644 --- a/reactos/subsystems/win32/csrss/win32csr/CMakeLists.txt +++ b/reactos/subsystems/win32/csrss/win32csr/CMakeLists.txt @@ -1,4 +1,3 @@ -add_definitions(-D_DLL -D__USE_CRTIMP) include_directories( BEFORE . @@ -19,7 +18,7 @@ list(APPEND SOURCE desktopbg.c dllmain.c exitros.c - file.c + file.c guiconsole.c handle.c harderror.c