summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMinh Nguyễn <mxn@1ec5.org>2015-12-02 13:17:02 -0800
committerMinh Nguyễn <mxn@1ec5.org>2015-12-13 17:26:53 -0800
commit47fb5e820b7759bcd783cffba80bc27ac7743ee4 (patch)
treec885103ff478f9f102890a5be70a05bf260ca376
parent1598330a9384de7c89c8e3cac55a8333e6b97c75 (diff)
downloadqtlocation-mapboxgl-47fb5e820b7759bcd783cffba80bc27ac7743ee4.tar.gz
[osx] Moved Mapbox.{h,m} into framework proper; set version variables
-rw-r--r--gyp/platform-osx.gypi1
-rw-r--r--include/mbgl/osx/Mapbox.h15
-rw-r--r--platform/osx/sdk/Mapbox.h23
-rw-r--r--platform/osx/sdk/Mapbox.m2
-rw-r--r--platform/osx/sdk/framework-osx.gypi2
-rwxr-xr-xscripts/osx/package.sh17
6 files changed, 28 insertions, 32 deletions
diff --git a/gyp/platform-osx.gypi b/gyp/platform-osx.gypi
index 66eef43277..964046b4fe 100644
--- a/gyp/platform-osx.gypi
+++ b/gyp/platform-osx.gypi
@@ -43,7 +43,6 @@
'../platform/darwin/MGLPolyline.mm',
'../include/mbgl/darwin/MGLPolygon.h',
'../platform/darwin/MGLPolygon.mm',
- '../include/mbgl/osx/Mapbox.h',
'../include/mbgl/osx/MGLAccountManager.h',
'../platform/osx/src/MGLAccountManager_Private.h',
'../platform/osx/src/MGLAccountManager.m',
diff --git a/include/mbgl/osx/Mapbox.h b/include/mbgl/osx/Mapbox.h
deleted file mode 100644
index 57d11bcaa9..0000000000
--- a/include/mbgl/osx/Mapbox.h
+++ /dev/null
@@ -1,15 +0,0 @@
-#import "MGLAccountManager.h"
-#import "MGLAnnotation.h"
-#import "MGLAnnotationImage.h"
-#import "MGLGeometry.h"
-#import "MGLMapView.h"
-#import "MGLMapView+IBAdditions.h"
-#import "MGLMapViewDelegate.h"
-#import "MGLMultiPoint.h"
-#import "MGLOverlay.h"
-#import "MGLPointAnnotation.h"
-#import "MGLPolygon.h"
-#import "MGLPolyline.h"
-#import "MGLShape.h"
-#import "MGLStyle.h"
-#import "MGLTypes.h"
diff --git a/platform/osx/sdk/Mapbox.h b/platform/osx/sdk/Mapbox.h
new file mode 100644
index 0000000000..fdc667b56a
--- /dev/null
+++ b/platform/osx/sdk/Mapbox.h
@@ -0,0 +1,23 @@
+#import <Cocoa/Cocoa.h>
+
+/// Project version number for Mapbox.
+FOUNDATION_EXPORT double MapboxVersionNumber;
+
+/// Project version string for Mapbox.
+FOUNDATION_EXPORT const unsigned char MapboxVersionString[];
+
+#import <Mapbox/MGLAccountManager.h>
+#import <Mapbox/MGLAnnotation.h>
+#import <Mapbox/MGLAnnotationImage.h>
+#import <Mapbox/MGLGeometry.h>
+#import <Mapbox/MGLMapView.h>
+#import <Mapbox/MGLMapView+IBAdditions.h>
+#import <Mapbox/MGLMapViewDelegate.h>
+#import <Mapbox/MGLMultiPoint.h>
+#import <Mapbox/MGLOverlay.h>
+#import <Mapbox/MGLPointAnnotation.h>
+#import <Mapbox/MGLPolygon.h>
+#import <Mapbox/MGLPolyline.h>
+#import <Mapbox/MGLShape.h>
+#import <Mapbox/MGLStyle.h>
+#import <Mapbox/MGLTypes.h>
diff --git a/platform/osx/sdk/Mapbox.m b/platform/osx/sdk/Mapbox.m
index 08d12579fe..661795a87b 100644
--- a/platform/osx/sdk/Mapbox.m
+++ b/platform/osx/sdk/Mapbox.m
@@ -1,4 +1,4 @@
-#import <mbgl/osx/Mapbox.h>
+#import <Mapbox/Mapbox.h>
#import "../src/NSBundle+MGLAdditions.h"
#import "../src/NSProcessInfo+MGLAdditions.h"
diff --git a/platform/osx/sdk/framework-osx.gypi b/platform/osx/sdk/framework-osx.gypi
index 0c7c89d3ec..f4c7ed70b1 100644
--- a/platform/osx/sdk/framework-osx.gypi
+++ b/platform/osx/sdk/framework-osx.gypi
@@ -28,10 +28,12 @@
},
'mac_framework_headers': [
+ './Mapbox.h',
'<!@(find ../include/mbgl/{darwin,osx} -type f \! -name \'.*\')',
],
'sources': [
+ './Mapbox.h',
'./Mapbox.m',
],
diff --git a/scripts/osx/package.sh b/scripts/osx/package.sh
index 79ab3f1377..d017ccb3d3 100755
--- a/scripts/osx/package.sh
+++ b/scripts/osx/package.sh
@@ -21,31 +21,18 @@ function step { >&2 echo -e "\033[1m\033[36m* $@\033[0m"; }
function finish { >&2 echo -en "\033[0m"; }
trap finish EXIT
-
-rm -rf ${OUTPUT}
-mkdir -p "${OUTPUT}"/shared
-
-
-step "Recording library version..."
-VERSION="${OUTPUT}"/shared/version.txt
-echo -n "https://github.com/mapbox/mapbox-gl-native/commit/" > ${VERSION}
-HASH=`git log | head -1 | awk '{ print $2 }' | cut -c 1-10` && true
-echo -n "mapbox-gl-native "
-echo ${HASH}
-echo ${HASH} >> ${VERSION}
-
-
step "Creating build files..."
export MASON_PLATFORM=osx
export BUILDTYPE=${BUILDTYPE:-Release}
export HOST=osx
make Xcode/osx
-step "Building OS X targets..."
+step "Building OS X framework (build ${TRAVIS_JOB_NUMBER:-${BITRISE_BUILD_NUMBER:-0}})..."
xcodebuild -sdk macosx${OSX_SDK_VERSION} \
ARCHS="x86_64" \
ONLY_ACTIVE_ARCH=NO \
GCC_GENERATE_DEBUGGING_SYMBOLS=${GCC_GENERATE_DEBUGGING_SYMBOLS} \
+ CURRENT_PROJECT_VERSION=${TRAVIS_JOB_NUMBER:-${BITRISE_BUILD_NUMBER:-0}} \
-project ./build/osx-x86_64/gyp/osx.xcodeproj \
-configuration ${BUILDTYPE} \
-target osxsdk \