summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorruki <[email protected]>2016-07-04 12:57:45 +0800
committerruki <[email protected]>2016-07-04 12:57:45 +0800
commitaeac87bc575300a4a81fbb30b983ff111d1425be (patch)
treeaafff4f2fe83a016d92baa0b4c7e85bb8e4cd8b2
parent12f317a44669fb8f0ca48a18359e9499c9d9eee0 (diff)
fix package and compile template project failed for linux
-rwxr-xr-xcore/pkg/tbox.pkg/inc/linux/x64/tbox.config.h4
-rwxr-xr-xcore/pkg/tbox.pkg/inc/linux/x86/tbox.config.h4
-rwxr-xr-xxmake/actions/package/main.lua18
3 files changed, 6 insertions, 20 deletions
diff --git a/core/pkg/tbox.pkg/inc/linux/x64/tbox.config.h b/core/pkg/tbox.pkg/inc/linux/x64/tbox.config.h
index 85653b029..e2e1ed72c 100755
--- a/core/pkg/tbox.pkg/inc/linux/x64/tbox.config.h
+++ b/core/pkg/tbox.pkg/inc/linux/x64/tbox.config.h
@@ -6,10 +6,12 @@
#define TB_CONFIG_VERSION_MAJOR 1
#define TB_CONFIG_VERSION_MINOR 5
#define TB_CONFIG_VERSION_ALTER 3
-#define TB_CONFIG_VERSION_BUILD 201607031545
+#define TB_CONFIG_VERSION_BUILD 201607041154
// defines
#define TB_CONFIG_OS_LINUX 1
+#define _GNU_SOURCE 1
+#define _REENTRANT 1
#define TB_CONFIG_SMALL 1
#define TB_CONFIG_TYPE_HAVE_FLOAT 1
#define TB_CONFIG_POSIX_HAVE_POSIX_SPAWNP 1
diff --git a/core/pkg/tbox.pkg/inc/linux/x86/tbox.config.h b/core/pkg/tbox.pkg/inc/linux/x86/tbox.config.h
index 85653b029..e2e1ed72c 100755
--- a/core/pkg/tbox.pkg/inc/linux/x86/tbox.config.h
+++ b/core/pkg/tbox.pkg/inc/linux/x86/tbox.config.h
@@ -6,10 +6,12 @@
#define TB_CONFIG_VERSION_MAJOR 1
#define TB_CONFIG_VERSION_MINOR 5
#define TB_CONFIG_VERSION_ALTER 3
-#define TB_CONFIG_VERSION_BUILD 201607031545
+#define TB_CONFIG_VERSION_BUILD 201607041154
// defines
#define TB_CONFIG_OS_LINUX 1
+#define _GNU_SOURCE 1
+#define _REENTRANT 1
#define TB_CONFIG_SMALL 1
#define TB_CONFIG_TYPE_HAVE_FLOAT 1
#define TB_CONFIG_POSIX_HAVE_POSIX_SPAWNP 1
diff --git a/xmake/actions/package/main.lua b/xmake/actions/package/main.lua
index 44a74cb15..986d28d17 100755
--- a/xmake/actions/package/main.lua
+++ b/xmake/actions/package/main.lua
@@ -99,24 +99,6 @@ option("[targetname]")
-- save file
file:write((content:gsub("%[targetname%]", targetname):gsub("%[TARGETNAME%]", targetname:upper())))
- -- get all defines from the target
- local defines = nil
- for _, define in ipairs(target:get("defines")) do
- if defines then
- defines = defines .. ", "
- else
- defines = ""
- end
- defines = defines .. "\"" .. define .. "\""
- end
-
- -- append defines to the package
- if defines then
- file:print("")
- file:print(" -- add defines")
- file:print(" add_defines(%s)", defines)
- end
-
-- exit file
file:close()
end