Skip to content

Commit

Permalink
Port src/Common on Linux
Browse files Browse the repository at this point in the history
  • Loading branch information
q4a committed Oct 7, 2018
1 parent aa1bf00 commit 6c2ab81
Show file tree
Hide file tree
Showing 9 changed files with 777 additions and 93 deletions.
10 changes: 6 additions & 4 deletions src/Common/Common.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,12 @@
#include "Common/FSMacros.hpp"
#include "Include/xrAPI/xrAPI.h"

#if __has_include(<SDL.h>)
#include <SDL.h>
#if defined(WINDOWS)
#if __has_include("SDL.h")
#include "SDL.h"
#endif

#if __has_include(<SDL_syswm.h>)
#include <SDL_syswm.h>
#if __has_include("SDL_syswm.h")
#include "SDL_syswm.h"
#endif
#endif
8 changes: 8 additions & 0 deletions src/Common/FSMacros.hpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
#pragma once

#if defined(LINUX)
#define _DELIMITER '/' //for looking
#define DELIMITER "/" // for insert
#elif defined(WINDOWS)
#define _DELIMITER '\\' //for looking
#define DELIMITER "\\" // for insert
#endif

// game path definition
#define _game_data_ "$game_data$"
#define _game_textures_ "$game_textures$"
Expand Down
Loading

0 comments on commit 6c2ab81

Please sign in to comment.