blob: e877640cdb0c4ea57b003d41a59fce237058b2cb (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
|
#!/bin/bash
# =================================================================================================
# ADOBE SYSTEMS INCORPORATED
# Copyright 2013 Adobe Systems Incorporated
# All Rights Reserved
#
# NOTICE: Adobe permits you to use, modify, and distribute this file in accordance with the terms
# of the Adobe license agreement accompanying it.
# =================================================================================================
clear
# Get the absolut path of the script
abspath=$(cd ${0%/*} && echo $PWD/${0##*/})
clean()
{
echo "Cleaning..."
if [ -e xcode ]
then
rm -rf xcode
fi
if [ -e ../XMPCore/build/xcode ]
then
rm -rf ../XMPCore/build/xcode
fi
if [ -e ../XMPFiles/build/xcode ]
then
rm -rf ../XMPFiles/build/xcode
fi
if [ -e ../public/libraries/macintosh ]
then
rm -rf ../public/libraries/macintosh
fi
if [ -e ../public/libraries/ios ]
then
rm -rf ../public/libraries/ios
fi
echo "Done"
exit 0;
}
Generate()
{
cd "`dirname \"$abspath\"`" >/dev/null
./cmake.command $BITS $BUILD_TYPE WarningAsError $TOOLCHAIN
if [ $? -ne 0 ]
then
echo "ERROR: CMAKE tool failed"
exit 1
else
echo "Xcode project created successfully"
fi
}
SDKDynamic32()
{
#create dynamic 32bit Xcode Project
BUILD_TYPE="Dynamic"
BITS="32"
TOOLCHAIN="ToolchainLLVM.cmake"
Generate
}
SDKStatic32()
{
#create static 32bit Xcode Project
BUILD_TYPE="Static"
BITS="32"
TOOLCHAIN="ToolchainLLVM.cmake"
Generate
}
SDKDynamic64()
{
#create dynamic 64bit Xcode Project
BUILD_TYPE="Dynamic"
BITS="64"
TOOLCHAIN="ToolchainLLVM.cmake"
Generate
}
SDKStatic64()
{
#create static 64bit Xcode Project
BUILD_TYPE="Static"
BITS="64"
TOOLCHAIN="ToolchainLLVM.cmake"
Generate
}
SDKStaticIos()
{
#create static ios Xcode Project
BUILD_TYPE="Static"
BITS="32"
TOOLCHAIN="Toolchain_ios.cmake"
Generate
}
echo "1. Clean All"
echo "2. Generate XMPToolkitSDK Dynamic 64"
echo "3. Generate XMPToolkitSDK Static 64"
echo "4. Generate XMPToolkitSDK Static iOS"
echo "5. Generate All"
read -p "Enter your choice: " choice
case $choice in
1) clean;;
2) SDKDynamic64;;
3) SDKStatic64;;
4) SDKStaticIos;;
5) SDKDynamic64; SDKStatic64; SDKStaticIos;;
*) echo "ERROR: Invalid Choice, Exiting"; exit 1;;
esac
exit 0
|