Changeset - 84d1dc97559a
[Not reviewed]
0 2 0
HanzZ - 13 years ago 2012-09-04 17:32:23
hanzz.k@gmail.com
Comment out SpectrumService
2 files changed with 12 insertions and 11 deletions:
0 comments (0 inline, 0 general)
spectrum/src/CMakeLists.txt
Show inline comments
 
cmake_minimum_required(VERSION 2.6)
 
FILE(GLOB SRC *.cpp)
 
 
if (WIN32)
 
FILE(GLOB WIN_SRC win32/*.cpp)
 
include_directories(win32)
 
ADD_EXECUTABLE(spectrum2 ${SRC} ${WIN_SRC})
 
else()
 
# if (WIN32)
 
# FILE(GLOB WIN_SRC win32/*.cpp)
 
# include_directories(win32)
 
# ADD_EXECUTABLE(spectrum2 ${SRC} ${WIN_SRC})
 
# else()
 
ADD_EXECUTABLE(spectrum2 ${SRC})
 
endif()
 
# endif()
 
 
 
 
ADD_DEPENDENCIES(spectrum2 spectrum2_libpurple_backend)
 
ADD_DEPENDENCIES(spectrum2 spectrum2_libircclient-qt_backend)
 
spectrum/src/main.cpp
Show inline comments
 
@@ -27,13 +27,13 @@
 
#include <sys/resource.h>
 
#include "libgen.h"
 
#include <malloc.h>
 
#else
 
#include <process.h>
 
#define getpid _getpid
 
#include "win32/SpectrumService.h"
 
// #include "win32/SpectrumService.h"
 
#endif
 
#include <sys/stat.h>
 

	
 
using namespace Transport;
 
using namespace Transport::Util;
 

	
 
@@ -152,15 +152,15 @@ int main(int argc, char **argv)
 
		("no-debug,d", "Create coredumps on crash")
 
		("jid,j", boost::program_options::value<std::string>(&jid)->default_value(""), "Specify JID of transport manually")
 
		("config", boost::program_options::value<std::string>(&config_file)->default_value(""), "Config file")
 
		("version,v", "Shows Spectrum version")
 
		;
 
#ifdef WIN32
 
	desc.add_options()
 
		("install-service,i", "Install spectrum as Windows service")
 
		("uninstall-service,u", "Uninstall Windows service");
 
// 	desc.add_options()
 
// 		("install-service,i", "Install spectrum as Windows service")
 
// 		("uninstall-service,u", "Uninstall Windows service");
 
#endif
 
	try
 
	{
 
		boost::program_options::positional_options_description p;
 
		p.add("config", -1);
 
		boost::program_options::store(boost::program_options::command_line_parser(argc, argv).
 
@@ -184,12 +184,13 @@ int main(int argc, char **argv)
 
		}
 

	
 
		if(vm.count("no-daemonize")) {
 
			no_daemon = true;
 
		}
 
#ifdef WIN32
 
#if 0
 
		if (vm.count("install-service")) {
 
			SpectrumService ntservice;
 
			if (!ntservice.IsInstalled()) {
 
					// determine the name of the currently executing file
 
				char szFilePath[MAX_PATH];
 
				GetModuleFileName(NULL, szFilePath, sizeof(szFilePath));
 
@@ -221,13 +222,13 @@ int main(int argc, char **argv)
 
				}                               				
 
			} else {
 
				std::cout << "Service not installed" << std::endl;
 
				return 1;
 
			}
 
		}
 

	
 
#endif
 
#endif
 
	}
 
	catch (std::runtime_error& e)
 
	{
 
		std::cout << desc << "\n";
 
		return 1;
0 comments (0 inline, 0 general)