[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [tor-messenger-build/master] Add projects/macosx-toolchain



commit b7828231d4479250be99f9172ffd97536aa1b055
Author: Nicolas Vigier <boklm@xxxxxxxxxxxxxx>
Date:   Fri Jun 12 17:45:02 2015 +0200

    Add projects/macosx-toolchain
---
 projects/macosx-toolchain/build  |   15 +++++++++++++++
 projects/macosx-toolchain/config |   31 +++++++++++++++++++++++++++++++
 rbm.conf                         |    3 +++
 3 files changed, 49 insertions(+)

diff --git a/projects/macosx-toolchain/build b/projects/macosx-toolchain/build
new file mode 100644
index 0000000..44e51ec
--- /dev/null
+++ b/projects/macosx-toolchain/build
@@ -0,0 +1,15 @@
+#!/bin/sh
+set -e
+rootdir=$(pwd)
+distdir="$rootdir/dist/[% project %]"
+mkdir -p "$distdir"
+ar vx [% c('input_files_by_name/SDK') %]
+tar xzf data.tar.gz
+mv usr/lib/apple/SDKs "$distdir/SDK"
+tar xf [% c('input_files_by_name/clang') %]
+mv x-tools "$distdir"
+cd "$rootdir/dist"
+[% c('tar', {
+   tar_src => [ project ],
+   tar_args => '-czf ' _ dest_dir _ '/' _ c('filename'),
+}) %]
diff --git a/projects/macosx-toolchain/config b/projects/macosx-toolchain/config
new file mode 100644
index 0000000..5e9dcb2
--- /dev/null
+++ b/projects/macosx-toolchain/config
@@ -0,0 +1,31 @@
+# vim: filetype=yaml sw=2
+filename: '[% project %]-[% c("version") %].tar.gz'
+version: 1
+var:
+  setup: |
+    mkdir -p /var/tmp/dist
+    tar -C /var/tmp/dist -xf [% c("compiler_tarfile") %]
+    sysrootdir=/var/tmp/dist/[% project %]/SDK/MacOSX10.6.sdk/
+    ccbindir=/var/tmp/dist/[% project %]/x-tools/x86_64-apple-darwin10/bin
+    export PATH="$ccbindir:$PATH"
+    FLAGS="-arch x86_64 -isysroot $sysrootdir"
+    CC="$ccbindir/x86_64-apple-darwin10-clang $FLAGS"
+    CXX="$ccbindir/x86_64-apple-darwin10-clang++ $FLAGS"
+    RANLIB=$ccbindir/x86_64-apple-darwin10-ranlib
+    AR=$ccbindir/x86_64-apple-darwin10-ar
+    AS=$ccbindir/x86_64-apple-darwin10-as
+    LD=$ccbindir/x86_64-apple-darwin10-ld
+    STRIP=$ccbindir/x86_64-apple-darwin10-strip
+
+lsb_release:
+  id: Ubuntu
+  release: 12.04
+  codename: precise
+
+input_files:
+  - name: clang
+    URL: https://people.torproject.org/~mikeperry/mirrors/sources/x86_64-apple-darwin10.tar.xz
+    sha256sum: 7b71bfe02820409b994c5c33a7eab81a81c72550f5da85ff7af70da3da244645
+  - name: SDK
+    URL: https://launchpad.net/~flosoft/+archive/cross-apple/+files/apple-uni-sdk-10.6_20110407-0.flosoft1_i386.deb
+    sha256sum: 6602d8d5ddb371fbc02e2a5967d9bd0cd7358d46f9417753c8234b923f2ea6fc
diff --git a/rbm.conf b/rbm.conf
index c5334fb..1208318 100644
--- a/rbm.conf
+++ b/rbm.conf
@@ -68,6 +68,9 @@ targets:
     var:
       osx: 1
       osname: osx-x86_64
+      compiler: 'macosx-toolchain'
+      configure_opt: '--host=x86_64-apple-darwin10 CC="x86_64-apple-darwin10-clang [% c("var/CLANG_FLAGS") %]" CXX="x86_64-apple-darwin10-clang++ [% c("var/CLANG_FLAGS") %]"'
+      CLANG_FLAGS: '-arch x86_64 -isysroot /var/tmp/dist/macosx-toolchain/SDK/MacOSX10.6.sdk'
 
   tor-messenger:
       var:

_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits