summaryrefslogtreecommitdiff
path: root/win
diff options
context:
space:
mode:
Diffstat (limited to 'win')
-rw-r--r--win/.gitignore3
-rw-r--r--win/CMakeLists.txt3
-rw-r--r--win/config.h.cmake (renamed from win/inspircd_config.h.cmake)10
-rw-r--r--win/inspircd_memory_functions.cpp1
-rw-r--r--win/inspircd_version.h.cmake4
-rw-r--r--win/inspircd_win32wrapper.cpp3
-rw-r--r--win/inspircd_win32wrapper.h9
-rw-r--r--win/win32service.cpp2
-rw-r--r--win/win32service.h2
9 files changed, 16 insertions, 21 deletions
diff --git a/win/.gitignore b/win/.gitignore
index f53ca0701..4b875ca61 100644
--- a/win/.gitignore
+++ b/win/.gitignore
@@ -1,3 +1,2 @@
-inspircd_version.h
-inspircd_config.h
+config.h
inspircd.rc
diff --git a/win/CMakeLists.txt b/win/CMakeLists.txt
index f26b9a6c7..827ef1c90 100644
--- a/win/CMakeLists.txt
+++ b/win/CMakeLists.txt
@@ -56,8 +56,7 @@ if(MSVC)
endif(MSVC)
configure_file("${INSPIRCD_BASE}/win/inspircd.rc.cmake" "${INSPIRCD_BASE}/win/inspircd.rc")
-configure_file("${INSPIRCD_BASE}/win/inspircd_version.h.cmake" "${INSPIRCD_BASE}/win/inspircd_version.h")
-configure_file("${INSPIRCD_BASE}/win/inspircd_config.h.cmake" "${INSPIRCD_BASE}/win/inspircd_config.h")
+configure_file("${INSPIRCD_BASE}/win/config.h.cmake" "${INSPIRCD_BASE}/win/config.h")
add_executable(inspircd ${INSPIRCD_SOURCES} "${INSPIRCD_BASE}/win/inspircd.rc")
target_link_libraries(inspircd win32_memory)
diff --git a/win/inspircd_config.h.cmake b/win/config.h.cmake
index f98cd391e..05c3ce2f9 100644
--- a/win/inspircd_config.h.cmake
+++ b/win/config.h.cmake
@@ -1,5 +1,9 @@
-#ifndef INSPIRCD_CONFIG_H
-#define INSPIRCD_CONFIG_H
+#pragma once
+
+#define BRANCH "@MAJOR_VERSION@.@MINOR_VERSION@"
+#define VERSION "@FULL_VERSION@"
+#define REVISION "0"
+#define SYSTEM "@CMAKE_SYSTEM@"
#define CONFIG_PATH "@CONF_PATH@"
#define MOD_PATH "@MODULE_PATH@"
@@ -9,5 +13,3 @@
#include "inspircd_win32wrapper.h"
#include "threadengines/threadengine_win32.h"
-
-#endif \ No newline at end of file
diff --git a/win/inspircd_memory_functions.cpp b/win/inspircd_memory_functions.cpp
index 398708317..2093bf3a8 100644
--- a/win/inspircd_memory_functions.cpp
+++ b/win/inspircd_memory_functions.cpp
@@ -16,6 +16,7 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
+
#include <windows.h>
#include <exception>
#include <new>
diff --git a/win/inspircd_version.h.cmake b/win/inspircd_version.h.cmake
deleted file mode 100644
index 1aec12b24..000000000
--- a/win/inspircd_version.h.cmake
+++ /dev/null
@@ -1,4 +0,0 @@
-#define BRANCH "@MAJOR_VERSION@.@MINOR_VERSION@"
-#define VERSION "@FULL_VERSION@"
-#define REVISION "0"
-#define SYSTEM "@CMAKE_SYSTEM@" \ No newline at end of file
diff --git a/win/inspircd_win32wrapper.cpp b/win/inspircd_win32wrapper.cpp
index ebc498529..7a07868f9 100644
--- a/win/inspircd_win32wrapper.cpp
+++ b/win/inspircd_win32wrapper.cpp
@@ -22,6 +22,7 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
+
#include "inspircd_win32wrapper.h"
#include "inspircd.h"
#include "configreader.h"
@@ -203,7 +204,7 @@ DWORD CWin32Exception::GetErrorCode()
}
#include "../src/modules/m_spanningtree/link.h"
-#include "../src/modules/ssl.h"
+#include "modules/ssl.h"
template class reference<Link>;
template class reference<Autoconnect>;
template class reference<ssl_cert>;
diff --git a/win/inspircd_win32wrapper.h b/win/inspircd_win32wrapper.h
index 75404ef8b..9b18715cd 100644
--- a/win/inspircd_win32wrapper.h
+++ b/win/inspircd_win32wrapper.h
@@ -19,13 +19,11 @@
*/
+#pragma once
+
/* Windows Port
Wrapper Functions/Definitions
By Burlex */
-
-#ifndef INSPIRCD_WIN32WRAPPER_H
-#define INSPIRCD_WIN32WRAPPER_H
-
/*
* Starting with PSAPI version 2 for Windows 7 and Windows Server 2008 R2, this function is defined as K32GetProcessMemoryInfo in Psapi.h and exported
* in Kernel32.lib and Kernel32.dll. However, you should always call this function as GetProcessMemoryInfo. To ensure correct resolution of symbols
@@ -200,6 +198,3 @@ private:
char szErrorString[500];
DWORD dwErrorCode;
};
-
-#endif
-
diff --git a/win/win32service.cpp b/win/win32service.cpp
index c34e9957d..d06ad1838 100644
--- a/win/win32service.cpp
+++ b/win/win32service.cpp
@@ -17,7 +17,7 @@
*/
-#include "inspircd_config.h"
+#include "config.h"
#include "inspircd.h"
#include "exitcodes.h"
#include <windows.h>
diff --git a/win/win32service.h b/win/win32service.h
index e4500be13..d8177eabc 100644
--- a/win/win32service.h
+++ b/win/win32service.h
@@ -15,7 +15,9 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
+
#pragma once
+
#ifdef _WIN32
/* Hook for win32service.cpp to exit properly with the service specific error code */