summaryrefslogtreecommitdiff
path: root/xmake/scripts/platform
diff options
context:
space:
mode:
authorruki <[email protected]>2015-07-10 16:59:16 +0800
committerruki <[email protected]>2015-07-10 16:59:16 +0800
commite2b2d08d459dc0c3459befb443c9c76520bcf61d (patch)
tree5a031da80823f8aade87c7d9896170d6202310c0 /xmake/scripts/platform
parentebd3cf08de2fea05bbf32d095f5a5c5a3c38a4f1 (diff)
add install for macosx
Diffstat (limited to 'xmake/scripts/platform')
-rw-r--r--xmake/scripts/platform/macosx/install.lua77
1 files changed, 77 insertions, 0 deletions
diff --git a/xmake/scripts/platform/macosx/install.lua b/xmake/scripts/platform/macosx/install.lua
new file mode 100644
index 000000000..0f8b981eb
--- /dev/null
+++ b/xmake/scripts/platform/macosx/install.lua
@@ -0,0 +1,77 @@
+--!The Automatic Cross-platform Build Tool
+--
+-- XMake is free software; you can redistribute it and/or modify
+-- it under the terms of the GNU Lesser General Public License as published by
+-- the Free Software Foundation; either version 2.1 of the License, or
+-- (at your option) any later version.
+--
+-- XMake is distributed in the hope that it will be useful,
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+-- GNU Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public License
+-- along with XMake;
+-- If not, see <a href="http://www.gnu.org/licenses/"> http://www.gnu.org/licenses/</a>
+--
+-- Copyright (C) 2009 - 2015, ruki All rights reserved.
+--
+-- @author ruki
+-- @file install.lua
+--
+
+-- define module: install
+local install = install or {}
+
+-- load modules
+local os = require("base/os")
+local path = require("base/path")
+local rule = require("base/rule")
+local utils = require("base/utils")
+local string = require("base/string")
+local platform = require("platform/platform")
+
+-- install target for the library file
+function install._done_library(target)
+
+ -- dump
+ utils.dump(target)
+
+ -- ok
+ return 1
+end
+
+-- install target for the binary file
+function install._done_binary(target)
+
+ -- dump
+ utils.dump(target)
+
+ -- ok
+ return 1
+end
+
+-- install target
+function install.main(target)
+
+ -- check
+ assert(target and target.kind)
+
+ -- the install scripts
+ local installscripts =
+ {
+ static = install._done_library
+ , shared = install._done_library
+ , binary = install._done_binary
+ }
+
+ -- install it
+ local installscript = installscripts[target.kind]
+ if installscript then return installscript(target) end
+
+ -- continue
+ return 0
+end
+
+-- return module: install
+return install