[ROSAPPS] put -Wno-unused-but-set-variable between a if(NOT MSVC) to really make...
authorDaniel Reimer <reimer.daniel@freenet.de>
Sun, 26 Apr 2015 17:08:34 +0000 (17:08 +0000)
committerDaniel Reimer <reimer.daniel@freenet.de>
Sun, 26 Apr 2015 17:08:34 +0000 (17:08 +0000)
svn path=/trunk/; revision=67439

12 files changed:
rosapps/applications/devutils/symdump/CMakeLists.txt
rosapps/applications/net/ncftp/CMakeLists.txt
rosapps/applications/net/ncftp/libncftp/syshdrs.h
rosapps/applications/net/ncftp/ncftp/cmds.c
rosapps/applications/net/ncftp/ncftp/syshdrs.h
rosapps/applications/net/ncftp/sio/syshdrs.h
rosapps/applications/sysutils/logevent/CMakeLists.txt
rosapps/applications/sysutils/pedump/CMakeLists.txt
rosapps/applications/sysutils/utils/CMakeLists.txt
rosapps/applications/sysutils/utils/rosperf/CMakeLists.txt
rosapps/applications/sysutils/utils/rosperf/rosperf.c
rosapps/templates/dialog/CMakeLists.txt

index fde9713..ffaddf0 100644 (file)
@@ -4,5 +4,7 @@ add_executable(symdump symdump.c)
 set_module_type(symdump win32cui)
 target_link_libraries(symdump wine)
 add_importlibs(symdump dbghelp shlwapi msvcrt kernel32)
-add_compile_flags("-Wno-unused-but-set-variable")
+if(NOT MSVC)
+    add_target_compile_flags(symdump "-Wno-unused-but-set-variable")
+endif()
 add_cd_file(TARGET symdump DESTINATION reactos/system32 FOR all)
index d3f3a13..58e794c 100644 (file)
@@ -70,6 +70,10 @@ list(APPEND SOURCE
 
 add_executable(ncftp ${SOURCE} ncftp.rc)
 set_module_type(ncftp win32cui)
-add_target_compile_flags(ncftp "-Wno-unused-but-set-variable -Wno-implicit-function-declaration -Wno-format-extra-args")
+if(NOT MSVC)
+    add_target_compile_flags(ncftp "-DHAVE_UTIME_H -DHAVE_UNISTD_H -Wno-unused-but-set-variable")
+else()
+    add_target_compile_flags(ncftp "-DHAVE_UTIME_H -DHAVE_UNISTD_H")
+endif()
 add_importlibs(ncftp advapi32 user32 ws2_32 msvcrt kernel32)
 add_cd_file(TARGET ncftp DESTINATION reactos/system32 FOR all)
index 344db2e..e3d29b7 100644 (file)
@@ -50,8 +50,6 @@
 #              define lstat _stat
 #              define fstat _fstat
 #              define dup _dup
-#              define utime _utime
-#              define utimbuf _utimbuf
 #      endif
 #      ifndef unlink
 #              define unlink remove
index d90e897..e3ec848 100644 (file)
@@ -1211,7 +1211,7 @@ RunBookmarkEditor(char *selectedBmName, size_t dsize)
                SysPerror("CreateMailslot");
                (void) fprintf(stderr, "Could not create communication channel with %s.\n", "ncftpbookmarks.exe");
                (void) fprintf(stderr, "%s", "This means if you select a bookmark to connect to that NcFTP\n");
-               (void) fprintf(stderr, "%s", "will not get the message from %s.\n", "ncftpbookmarks.exe");
+               (void) fprintf(stderr, "%s", "will not get the message from %s.\n");
        }
 
        winExecResult = WinExec(prog, SW_SHOWNORMAL);
index 3a4d639..c8b1d84 100644 (file)
@@ -44,6 +44,8 @@
 #      include <fcntl.h>
 #      include <signal.h>
 #      include <assert.h>
+#      include <utime.h>
+#      include <direct.h>
 #      undef strcasecmp
 #      define strcasecmp stricmp
 #      undef strncasecmp
index d9c6513..5279757 100644 (file)
@@ -13,6 +13,7 @@
        /* Include "wincfg.h" in place of "config.h" */
 #      include "wincfg.h"
 #      include <winsock2.h>    /* includes <windows.h> */
+#      include <io.h>
 #      define _POSIX_ 1
 #      ifdef HAVE_UNISTD_H
 #              include <unistd.h>
@@ -28,7 +29,6 @@
 #      include <ctype.h>
 #      include <stdarg.h>
 #      include <time.h>
-#      include <io.h>
 #      include <sys/types.h>
 #      include <sys/stat.h>
 #      include <fcntl.h>
index 2dfeca5..b737ad2 100644 (file)
@@ -1,6 +1,8 @@
 
 add_executable(logevent logevent.c logevent.rc)
 set_module_type(logevent win32cui)
-add_target_compile_flags(logevent "-Wno-unused-but-set-variable")
+if(NOT MSVC)
+    add_target_compile_flags(logevent "-Wno-unused-but-set-variable")
+endif()
 add_importlibs(logevent advapi32 msvcrt kernel32)
 add_cd_file(TARGET logevent DESTINATION reactos/system32 FOR all)
index 1acb8b4..b2805cb 100644 (file)
@@ -1,6 +1,8 @@
 
 add_executable(pedump pedump.c pedump.rc)
 set_module_type(pedump win32cui)
-add_target_compile_flags(pedump "-Wno-unused-but-set-variable")
+if(NOT MSVC)
+    add_target_compile_flags(pedump "-Wno-unused-but-set-variable")
+endif()
 add_importlibs(pedump msvcrt kernel32 ntdll)
 add_cd_file(TARGET pedump DESTINATION reactos/system32 FOR all)
index d8d987a..928d21e 100644 (file)
@@ -6,6 +6,6 @@ add_subdirectory(nts2w32err)
 add_subdirectory(objdir)
 add_subdirectory(partinfo)
 add_subdirectory(ps)
-#add_subdirectory(rosperf)
+add_subdirectory(rosperf)
 add_subdirectory(stats)
 add_subdirectory(tickcount)
index 0bda350..92d9621 100644 (file)
@@ -11,6 +11,8 @@ list(APPEND SOURCE
 
 add_executable(rosperf ${SOURCE} rosperf.rc)
 set_module_type(rosperf win32cui UNICODE)
-add_target_compile_flags(rosperf "-Wno-unused-but-set-variable")
+if(NOT MSVC)
+    add_target_compile_flags(rosperf "-Wno-unused-but-set-variable")
+endif()
 add_importlibs(rosperf version msimg32 gdi32 shell32 advapi32 user32 ntdll msvcrt kernel32)
 add_cd_file(TARGET rosperf DESTINATION reactos/system32 FOR all)
index 77148a8..8f9acf4 100644 (file)
@@ -858,9 +858,9 @@ ProcessCommandLine(PPERF_INFO PerfInfo, unsigned *TestCount, PTEST *Tests)
 }
 
 int WINAPI
-WinMain(HINSTANCE hInstance,
+wWinMain(HINSTANCE hInstance,
        HINSTANCE hPrevInstance,
-       LPSTR lpszCmdLine,
+       LPWSTR lpszCmdLine,
        int nCmdShow)
 {
   PTEST Tests;
index f209f00..6102bb4 100644 (file)
@@ -9,6 +9,8 @@ list(APPEND SOURCE
 
 add_executable(template_dialog ${SOURCE} dialog.rc)
 set_module_type(template_dialog win32cui)
-add_target_compile_flags(template_dialog "-Wno-unused-but-set-variable")
+if(NOT MSVC)
+    add_target_compile_flags(template_dialog "-Wno-unused-but-set-variable")
+endif()
 add_importlibs(template_dialog user32 gdi32 comctl32 msvcrt kernel32 ntdll)
 add_cd_file(TARGET template_dialog DESTINATION reactos/system32 FOR all)