Windows fixes

This commit is contained in:
Jack Andersen 2017-11-13 17:33:31 -10:00
parent 3f24b7f33e
commit 30391f3352
5 changed files with 4 additions and 6 deletions

View File

@ -90,7 +90,6 @@ if(WIN32)
endif() endif()
# ATDNA target # ATDNA target
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
include_directories(${LLVM_INCLUDE_DIRS}) include_directories(${LLVM_INCLUDE_DIRS})
link_directories(${LLVM_LIBRARY_DIRS}) link_directories(${LLVM_LIBRARY_DIRS})
add_executable(atdna main.cpp test.hpp ${PLAT_SRCS}) add_executable(atdna main.cpp test.hpp ${PLAT_SRCS})
@ -102,8 +101,7 @@ set_target_properties(atdna PROPERTIES
COMPILE_FLAGS "/GR-") COMPILE_FLAGS "/GR-")
else() else()
set_target_properties(atdna PROPERTIES set_target_properties(atdna PROPERTIES
COMPILE_FLAGS "-std=c++11 -fno-rtti -Wno-unused-parameter" COMPILE_FLAGS "-fno-rtti -Wno-unused-parameter")
LINK_FLAGS -std=c++11)
endif() endif()
# Define installs # Define installs

View File

@ -2431,4 +2431,3 @@ int main(int argc, const char** argv)
return 0; return 0;
} }

View File

@ -2,6 +2,7 @@
#define __UTILITY_H__ #define __UTILITY_H__
#include <string> #include <string>
#include <string_view>
#include <vector> #include <vector>
#include <stdarg.h> #include <stdarg.h>
#include <string.h> #include <string.h>

View File

@ -5,6 +5,6 @@ libdir=${prefix}/lib
Name: libAthena Name: libAthena
Description: Basic cross platform IO library Description: Basic cross platform IO library
Version: @ATHENA_VERSION@ Version: @ATHENA_VERSION@
Cflags: -I${includedir}/Athena -std=c++11 Cflags: -I${includedir}/Athena
Libs: -L${libdir} -lathena-core -lathena-sakura -lathena-zelda -lathena-wiiSave Libs: -L${libdir} -lathena-core -lathena-sakura -lathena-zelda -lathena-wiiSave
Requires: zlib Requires: zlib

View File

@ -70,7 +70,7 @@ bool Dir::touch()
bool Dir::mkdir(std::string_view dir, mode_t mode) bool Dir::mkdir(std::string_view dir, mode_t mode)
{ {
#if _WIN32 #if _WIN32
return !(::_mkdir(dir.c_str()) < 0); return !(::_mkdir(dir.data()) < 0);
#else #else
return !(::mkdir(dir.data(), mode) < 0); return !(::mkdir(dir.data(), mode) < 0);
#endif #endif