From 46553ff00c15414f4087ba9195fed7eba340fc13 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20Ka=CC=88fer?= Date: Mon, 26 Jan 2015 07:17:24 -0800 Subject: [PATCH] rework linux gyp files --- gyp/mbgl-core.gypi | 4 ++-- gyp/mbgl-headless.gypi | 22 +++++----------------- gyp/mbgl-linux.gypi | 7 ++----- gyp/mbgl-storage-curl.gypi | 7 +++++-- linux/mapboxgl-app.gyp | 4 ++-- 5 files changed, 16 insertions(+), 28 deletions(-) diff --git a/gyp/mbgl-core.gypi b/gyp/mbgl-core.gypi index cf33b4ae1..35a535dd5 100644 --- a/gyp/mbgl-core.gypi +++ b/gyp/mbgl-core.gypi @@ -56,12 +56,12 @@ ], 'link_settings': { - 'libraries': [ '<@(libraries)' ], 'conditions': [ ['OS == "mac"', { + 'libraries': [ '<@(libraries)' ], 'xcode_settings': { 'OTHER_LDFLAGS': [ '<@(ldflags)' ] } }, { - 'ldflags': [ '<@(ldflags)' ], + 'libraries': [ '<@(libraries)', '<@(ldflags)' ], }] ], }, diff --git a/gyp/mbgl-headless.gypi b/gyp/mbgl-headless.gypi index e2d4e010c..df91e7169 100644 --- a/gyp/mbgl-headless.gypi +++ b/gyp/mbgl-headless.gypi @@ -4,27 +4,15 @@ 'product_name': 'mbgl-headless', 'type': 'static_library', 'standalone_static_library': 1, - 'variables': { - 'cflags_cc': [ - '<@(uv_cflags)', - ], - }, - 'include_dirs': [ - '../include', - ], - 'conditions': [ - ['OS == "mac"', { - 'xcode_settings': { - 'OTHER_CPLUSPLUSFLAGS': [ '<@(cflags_cc)' ], - } - }, { - 'cflags_cc': [ '<@(cflags_cc)' ], - }] - ], + 'sources': [ '../platform/default/headless_view.cpp', '../platform/default/headless_display.cpp', ], + + 'include_dirs': [ + '../include', + ], }, ], } diff --git a/gyp/mbgl-linux.gypi b/gyp/mbgl-linux.gypi index 85fc4a512..930cd6fb1 100644 --- a/gyp/mbgl-linux.gypi +++ b/gyp/mbgl-linux.gypi @@ -12,8 +12,6 @@ 'sources': [ '../platform/default/log_stderr.cpp', '../platform/default/string_stdlib.cpp', - '../platform/default/http_request_curl.cpp', - '../platform/default/asset_request_libuv.cpp', '../platform/default/application_root.cpp', '../platform/default/image.cpp', '../platform/default/image_reader.cpp', @@ -33,7 +31,6 @@ '<@(png_ldflags)', '<@(jpeg_ldflags)', '<@(uv_ldflags)', - '<@(curl_ldflags)', '<@(nu_ldflags)', ], 'libraries': [ @@ -60,12 +57,12 @@ ], 'link_settings': { - 'libraries': [ '<@(libraries)' ], 'conditions': [ ['OS == "mac"', { + 'libraries': [ '<@(libraries)' ], 'xcode_settings': { 'OTHER_LDFLAGS': [ '<@(ldflags)' ] } }, { - 'ldflags': [ '<@(ldflags)' ], + 'libraries': [ '<@(libraries)', '<@(ldflags)' ], }] ], }, diff --git a/gyp/mbgl-storage-curl.gypi b/gyp/mbgl-storage-curl.gypi index c47f2232d..f500d813e 100644 --- a/gyp/mbgl-storage-curl.gypi +++ b/gyp/mbgl-storage-curl.gypi @@ -25,16 +25,19 @@ 'cflags_cc': [ '<@(uv_cflags)', '<@(sqlite3_cflags)', + '<@(curl_cflags)', '-I<(boost_root)/include', ], 'ldflags': [ '<@(uv_ldflags)', '<@(sqlite3_ldflags)', + '<@(curl_ldflags)', '<@(zlib_ldflags)', ], 'libraries': [ '<@(uv_static_libs)', '<@(sqlite3_static_libs)', + '<@(curl_static_libs)', '<@(zlib_static_libs)', ], }, @@ -50,12 +53,12 @@ ], 'link_settings': { - 'libraries': [ '<@(libraries)' ], 'conditions': [ ['OS == "mac"', { + 'libraries': [ '<@(libraries)' ], 'xcode_settings': { 'OTHER_LDFLAGS': [ '<@(ldflags)' ] } }, { - 'ldflags': [ '<@(ldflags)' ], + 'libraries': [ '<@(libraries)', '<@(ldflags)' ], }] ], }, diff --git a/linux/mapboxgl-app.gyp b/linux/mapboxgl-app.gyp index abc3db6ad..ce066ef5e 100644 --- a/linux/mapboxgl-app.gyp +++ b/linux/mapboxgl-app.gyp @@ -34,16 +34,16 @@ ], }, - 'libraries': [ '<@(libraries)' ], 'conditions': [ ['OS == "mac"', { + 'libraries': [ '<@(libraries)' ], 'xcode_settings': { 'OTHER_CPLUSPLUSFLAGS': [ '<@(cflags_cc)' ], 'OTHER_LDFLAGS': [ '<@(ldflags)' ], } }, { 'cflags_cc': [ '<@(cflags_cc)' ], - 'ldflags': [ '<@(ldflags)' ], + 'libraries': [ '<@(libraries)', '<@(ldflags)' ], }] ],