commit 96192e4256e777241dc0404c16793ccb972ba8a3
parent dbdf43bea2c394d854ad7d0212aecd0e34c7b822
Author: Kyle Milz <kyle@windows.krwm.net>
Date: Thu, 5 Jan 2017 22:25:28 -0800
configure: use / instead of \ for config paths
Diffstat:
3 files changed, 11 insertions(+), 8 deletions(-)
diff --git a/Jamfile b/Jamfile
@@ -114,8 +114,8 @@ Stringize lib_h.h : lib.h ;
ObjectC++Flags $(INST_SRCS) : $(INST_CFLAGS) ;
ObjectDefines $(INST_SRCS) :
- CITRUN_COMPILERS=R\\\"($(CITRUN_COMPILERS))\\\"
- CITRUN_LIB=R\\\"($(CITRUN_LIB))\\\" ;
+ CITRUN_COMPILERS=$(CITRUN_COMPILERS)
+ CITRUN_LIB=$(CITRUN_LIB) ;
LINKFLAGS on citrun_inst$(SUFEXE) = $(LINKFLAGS) $(INST_LDFLAGS) ;
LINKLIBS on citrun_inst$(SUFEXE) += $(INST_LIBS) ;
diff --git a/configure.bat b/configure.bat
@@ -56,8 +56,8 @@ DEL Jamrules 2>nul
>> Jamrules ECHO.
>> Jamrules ECHO FONT_PATH = "C:\Windows\Fonts\consola.ttf" ;
->> Jamrules ECHO CITRUN_COMPILERS = %CD:\=\\%\\compilers ;
->> Jamrules ECHO CITRUN_LIB = %CD:\=\\%\\libcitrun.lib ;
+>> Jamrules ECHO CITRUN_COMPILERS = %CD:\=/%/compilers ;
+>> Jamrules ECHO CITRUN_LIB = %CD:\=/%/libcitrun.lib ;
>> Jamrules ECHO.
REM GL_CFLAGS = `pkg-config --cflags glfw3 glew freetype2` ;
diff --git a/inst_frontend.cc b/inst_frontend.cc
@@ -42,6 +42,9 @@
#define PATH_SEP ':'
#endif // _WIN32
+#define xstr(x) make_str(x)
+#define make_str(x) #x
+
static llvm::cl::OptionCategory ToolingCategory("citrun_inst options");
@@ -67,7 +70,7 @@ InstFrontend::InstFrontend(int argc, char *argv[], bool is_citrun_inst) :
{
log_identity();
- m_log << "CITRUN_COMPILERS = '" << CITRUN_COMPILERS << "'" << std::endl;
+ m_log << "CITRUN_COMPILERS = '" << xstr(CITRUN_COMPILERS) << "'" << std::endl;
#ifndef _WIN32
// Sometimes we're not called as citrun_inst so force that here.
@@ -119,7 +122,7 @@ InstFrontend::clean_PATH()
bool found_citrun_path = 0;
while (std::getline(path_ss, component, PATH_SEP)) {
- if (component.compare(CITRUN_COMPILERS) == 0) {
+ if (component.compare(xstr(CITRUN_COMPILERS)) == 0) {
found_citrun_path = 1;
continue;
}
@@ -250,9 +253,9 @@ InstFrontend::if_link_add_runtime(bool object_arg, bool compile_arg)
return;
#endif // _WIN32
- m_log << "Link detected, adding '"<< CITRUN_LIB
+ m_log << "Link detected, adding '"<< xstr(CITRUN_LIB)
<< "' to command line." << std::endl;
- m_args.push_back(const_cast<char *>(CITRUN_LIB));
+ m_args.push_back(const_cast<char *>(xstr(CITRUN_LIB)));
}
//