summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
73aa420)
This changes __RELFILE__ to always be relative and not rely on a GCC extension, since __FILE__ is *always* relative to the root.
include(sdk/cmake/compilerflags.cmake)
add_definitions(-D__REACTOS__)
include(sdk/cmake/compilerflags.cmake)
add_definitions(-D__REACTOS__)
+add_definitions(-DREACTOS_SOURCE_DIR="\\"${REACTOS_SOURCE_DIR}\\"")
+add_definitions(-DREACTOS_BINARY_DIR="\\"${REACTOS_BINARY_DIR}\\"")
+add_compile_flags(-D__RELFILE__="&__FILE__[sizeof REACTOS_SOURCE_DIR]")
if(MSVC_IDE)
add_compile_flags("/MP")
if(MSVC_IDE)
add_compile_flags("/MP")
+++ /dev/null
-/* Do not edit - Machine generated */
-
-#pragma once
-
-#define REACTOS_SOURCE_DIR "@REACTOS_SOURCE_DIR@"
-#define REACTOS_BINARY_DIR "@REACTOS_BINARY_DIR@"
-
-#if defined(__GNUC__)
-#define __RELFILE__ \
- (!__builtin_strncmp(__FILE__, REACTOS_SOURCE_DIR, sizeof(REACTOS_SOURCE_DIR) - 1) \
- ? __FILE__ + sizeof(REACTOS_SOURCE_DIR) : __FILE__)
-#else
-#define __RELFILE__ __FILE__
-#endif
-
-/* EOF */
+#ifndef __RELFILE__
+#define __RELFILE__ __FILE__
+#endif
/* Define DbgPrint/DbgPrintEx/RtlAssert unless the NDK is used */
#if !defined(_RTLFUNCS_H) && !defined(_NTDDK_)
/* Define DbgPrint/DbgPrintEx/RtlAssert unless the NDK is used */
#if !defined(_RTLFUNCS_H) && !defined(_NTDDK_)
configure_file(sdk/include/reactos/version.h.cmake ${REACTOS_BINARY_DIR}/sdk/include/reactos/version.h)
configure_file(sdk/include/reactos/buildno.h.cmake ${REACTOS_BINARY_DIR}/sdk/include/reactos/buildno.h)
configure_file(sdk/include/reactos/version.h.cmake ${REACTOS_BINARY_DIR}/sdk/include/reactos/version.h)
configure_file(sdk/include/reactos/buildno.h.cmake ${REACTOS_BINARY_DIR}/sdk/include/reactos/buildno.h)
-configure_file(sdk/include/reactos/builddir.h.cmake ${REACTOS_BINARY_DIR}/sdk/include/reactos/builddir.h)
#include <guiddef.h>
#endif
#include <guiddef.h>
#endif
+#ifndef __RELFILE__
+#define __RELFILE__ __FILE__
+#endif
#ifdef __WINE_WINE_TEST_H
#error This file should not be used in Wine tests
#ifdef __WINE_WINE_TEST_H
#error This file should not be used in Wine tests
- #include <builddir.h>
-
#if !defined(__RELFILE__)
#define __RELFILE__ __FILE__
#endif
#if !defined(__RELFILE__)
#define __RELFILE__ __FILE__
#endif