Checkers: newlib

git-svn-id: svn://kolibrios.org@8501 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
maxcodehack 2021-01-02 18:12:08 +00:00
parent 0d2bbcbde7
commit c52de00a32
2 changed files with 4 additions and 2 deletions

View File

@ -1,12 +1,14 @@
if tup.getconfig("NO_GCC") ~= "" then return end
HELPERDIR = (tup.getconfig("HELPERDIR") == "") and "../../.." or tup.getconfig("HELPERDIR")
tup.include(HELPERDIR .. "/use_gcc.lua")
tup.include(HELPERDIR .. "/use_menuetlibc.lua")
tup.include(HELPERDIR .. "/use_newlib.lua")
if tup.getconfig("LANG") == "ru"
then C_LANG = "LANG_RUS"
else C_LANG = "LANG_ENG" -- this includes default case without config
end
LIBS = "-lsupc++ -lstdc++ " .. LIBS
LDFLAGS = LDFLAGS .. " --subsystem native"
CFLAGS = CFLAGS .. " -D_KOLIBRI -DAUTOBUILD -D" .. C_LANG .. " -DNO_FILES -fwhole-program"
compile_gcc{"checkers.cpp"}

View File

@ -9,7 +9,7 @@
inline long GetProcessId() {return 0;}
inline long DuplicateProcess() {return -1;}
inline int random(int m) {return ((unsigned long)rand()) % m;}
inline void randomize() {srand(__menuet__getsystemclock());}
inline void randomize() {srand(time(0));}
#elif defined __GNUC__
# include <unistd.h>
# define DIR_SEPARATOR ('/')