[rkward-cvs] SF.net SVN: rkward-code:[4619] trunk/rkward/rkward/wrapper

tfry at users.sf.net tfry at users.sf.net
Fri Mar 22 12:03:48 UTC 2013


Revision: 4619
          http://sourceforge.net/p/rkward/code/4619
Author:   tfry
Date:     2013-03-22 12:03:46 +0000 (Fri, 22 Mar 2013)
Log Message:
-----------
Make wrapper compile on Windows

Modified Paths:
--------------
    trunk/rkward/rkward/wrapper/CMakeLists.txt
    trunk/rkward/rkward/wrapper/rkward_startup_wrapper.cpp
    trunk/rkward/rkward/wrapper/rkward_windows_icon.rc

Modified: trunk/rkward/rkward/wrapper/CMakeLists.txt
===================================================================
--- trunk/rkward/rkward/wrapper/CMakeLists.txt	2013-03-22 11:11:59 UTC (rev 4618)
+++ trunk/rkward/rkward/wrapper/CMakeLists.txt	2013-03-22 12:03:46 UTC (rev 4619)
@@ -1,9 +1,12 @@
 IF (WIN32)
 	SET (CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -static")
 ENDIF (WIN32)
-ADD_EXECUTABLE (rkward rkward_startup_wrapper.cpp rkward_windows_icon.rc)
+ADD_CUSTOM_COMMAND (OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/rkward.ico"
+			COMMAND cmake -E copy "${CMAKE_CURRENT_SOURCE_DIR}/../icons/app-icon/rkward.ico"
+			"${CMAKE_CURRENT_BINARY_DIR}/rkward.ico")
+ADD_EXECUTABLE (rkward rkward_startup_wrapper.cpp rkward_windows_icon.rc rkward.ico)
 add_definitions ("-DR_EXECUTABLE=\\\"${R_EXECUTABLE}\\\"")
-TARGET_LINK_LIBRARIES(rkward ${QT_QTGUI_LIBRARY})
+TARGET_LINK_LIBRARIES(rkward ${QT_QTGUI_LIBRARY} ${QT_QTCORE_LIBRARY})
 IF (WIN32)	# NOTE: On other platforms, currently in conflict with shell wrapper script
 	INSTALL(TARGETS rkward DESTINATION ${BIN_INSTALL_DIR})
 ENDIF (WIN32)

Modified: trunk/rkward/rkward/wrapper/rkward_startup_wrapper.cpp
===================================================================
--- trunk/rkward/rkward/wrapper/rkward_startup_wrapper.cpp	2013-03-22 11:11:59 UTC (rev 4618)
+++ trunk/rkward/rkward/wrapper/rkward_startup_wrapper.cpp	2013-03-22 12:03:46 UTC (rev 4619)
@@ -27,8 +27,6 @@
 #include <QProcess>
 #include <QSettings>
 
-#include <stdlib.h>
-
 #ifndef RKWARD_REL_INSTALL_PATH
 #	define RKWARD_REL_INSTALL_PATH ""
 #endif
@@ -77,8 +75,8 @@
 		kdeinit4_exe = findExeAtPath ("kdeinit4", kde_dir.path ());
 #endif
 		// important if RKWard is not in KDEPREFIX/bin but e.g. KDEPREFIX/lib/libexec
-		setenv ("RKWARD_ENSURE_PREFIX", kde_dir.path().toLocal8Bit (), 1);
-
+		qputenv ("RKWARD_ENSURE_PREFIX", kde_dir.path().toLocal8Bit ());
+	
 		rkward_frontend_exe = findRKWardAtPath (kde_dir.absoluteFilePath ("bin"));
 		if (rkward_frontend_exe.isNull ()) rkward_frontend_exe = findRKWardAtPath (kde_dir.absoluteFilePath ("../lib/libexec"));
 		if (rkward_frontend_exe.isNull ()) rkward_frontend_exe = findRKWardAtPath (kde_dir.absoluteFilePath (RKWARD_REL_INSTALL_PATH));

Modified: trunk/rkward/rkward/wrapper/rkward_windows_icon.rc
===================================================================
--- trunk/rkward/rkward/wrapper/rkward_windows_icon.rc	2013-03-22 11:11:59 UTC (rev 4618)
+++ trunk/rkward/rkward/wrapper/rkward_windows_icon.rc	2013-03-22 12:03:46 UTC (rev 4619)
@@ -1,2 +1,2 @@
-DI_ICON1               ICON    DISCARDABLE     "../icons/rkward.ico"
+DI_ICON1               ICON    DISCARDABLE     "rkward.ico"
 





More information about the rkward-tracker mailing list