summaryrefslogtreecommitdiff
path: root/gyp/core.gypi
diff options
context:
space:
mode:
Diffstat (limited to 'gyp/core.gypi')
-rw-r--r--gyp/core.gypi76
1 files changed, 76 insertions, 0 deletions
diff --git a/gyp/core.gypi b/gyp/core.gypi
new file mode 100644
index 0000000000..0adcaa766f
--- /dev/null
+++ b/gyp/core.gypi
@@ -0,0 +1,76 @@
+{
+ 'targets': [
+ { 'target_name': 'core',
+ 'product_name': 'mbgl-core',
+ 'type': 'static_library',
+ 'standalone_static_library': 1,
+ 'hard_dependency': 1,
+ 'dependencies': [
+ 'shaders',
+ 'version',
+ ],
+
+ 'sources': [
+ '<!@(find src -name "*.hpp")',
+ '<!@(find src -name "*.cpp")',
+ '<!@(find src -name "*.c")',
+ '<!@(find src -name "*.h")',
+ '<!@(find include -name "*.hpp")',
+ '<!@(find include -name "*.h")',
+ '<!@(find src -name "*.glsl")',
+ 'bin/style.json'
+ ],
+
+ 'include_dirs': [
+ '../include',
+ '../src',
+ ],
+
+ 'variables': {
+ 'cflags_cc': [
+ '<@(uv_cflags)',
+ '-I<(boost_root)/include',
+ ],
+ 'cflags': [
+ '<@(uv_cflags)',
+ '-fPIC'
+ ],
+ 'ldflags': [
+ '<@(uv_ldflags)',
+ ],
+ 'libraries': [
+ '<@(uv_static_libs)',
+ ],
+ },
+
+ 'conditions': [
+ ['OS == "mac"', {
+ 'xcode_settings': {
+ 'OTHER_CPLUSPLUSFLAGS': [ '<@(cflags_cc)' ],
+ 'OTHER_CFLAGS': [ '<@(cflags)' ],
+ },
+ }, {
+ 'cflags_cc': [ '<@(cflags_cc)' ],
+ 'cflags': [ '<@(cflags)' ],
+ }]
+ ],
+
+ 'link_settings': {
+ 'conditions': [
+ ['OS == "mac"', {
+ 'libraries': [ '<@(libraries)' ],
+ 'xcode_settings': { 'OTHER_LDFLAGS': [ '<@(ldflags)' ] }
+ }, {
+ 'libraries': [ '<@(libraries)', '<@(ldflags)' ],
+ }]
+ ],
+ },
+
+ 'direct_dependent_settings': {
+ 'include_dirs': [
+ '../include',
+ ],
+ },
+ },
+ ]
+}