File tree Expand file tree Collapse file tree 6 files changed +259
-4
lines changed
Expand file tree Collapse file tree 6 files changed +259
-4
lines changed Original file line number Diff line number Diff line change 1- language : cpp
1+ language : android
2+ jdk : oraclejdk7
3+
4+ android :
5+ components :
6+ - build-tools-19.1.0
7+ - android-19
8+ - extra
29
3- compiler :
4- - gcc
510before_script :
611 - sudo apt-get update
12+ - sudo apt-get install gcc-4.6 g++-4.6
713 - sudo apt-get install tree cmake gcc-4.6-arm-linux-gnueabi g++-4.6-arm-linux-gnueabi libc6-dev-i386 lib32stdc++6 g++-multilib g++-4.6-multilib
814 - mkdir build
915 - cd build
@@ -28,4 +34,17 @@ before_script:
2834 - cp ./cgi-getcookie ../dest/arm/
2935 - cp ./cgi-getfield ../dest/arm/
3036 - rm -rf *
31- script : tree ../dest/
37+
38+ # build for android
39+ - cd ../tools
40+ - ./install_android_ndk.sh
41+ - cd ../android/native/jni/
42+ - ../../../android-ndk/ndk-build
43+ - cd ../../
44+ # build apk
45+ - gradlew build --stacktrace
46+ - cp -r build/outputs/apk ../dest/android/
47+ - cd ..
48+ script :
49+ - tree dest/
50+ - tar -cvzf tnyweb.tar.gz ./dest/
Original file line number Diff line number Diff line change 1+ buildscript {
2+ repositories {
3+ jcenter()
4+ }
5+
6+ dependencies {
7+ classpath ' com.android.tools.build:gradle:1.1.3'
8+ }
9+ }
10+
11+ apply plugin : ' android'
12+ ext. multiarch= true
13+ android {
14+
15+ sourceSets {
16+ main {
17+ manifest. srcFile ' AndroidManifest.xml'
18+ java. srcDirs = [' src' ]
19+ resources. srcDirs = [' src' ]
20+ aidl. srcDirs = [' src' ]
21+ renderscript. srcDirs = [' src' ]
22+ res. srcDirs = [' res' ]
23+ assets. srcDirs = [' assets' ]
24+ }
25+ }
26+ compileSdkVersion 19
27+ buildToolsVersion " 19.1.0"
28+
29+ if (multiarch) {
30+ productFlavors {
31+ armv7 {
32+ ndk {
33+ abiFilters " armeabi-v7a" , " "
34+ }
35+ }
36+ x86 {
37+ ndk {
38+ abiFilters " x86" , " "
39+ }
40+ }
41+ all {
42+ ndk {
43+ abiFilters " all" , " "
44+ }
45+ }
46+ }
47+ }
48+
49+ compileOptions {
50+ sourceCompatibility JavaVersion . VERSION_1_7
51+ targetCompatibility JavaVersion . VERSION_1_7
52+ }
53+
54+ lintOptions {
55+ abortOnError false
56+ }
57+ }
Original file line number Diff line number Diff line change 1+ # Wed Apr 10 15:27:10 PDT 2013
2+ distributionBase =GRADLE_USER_HOME
3+ distributionPath =wrapper/dists
4+ zipStoreBase =GRADLE_USER_HOME
5+ zipStorePath =wrapper/dists
6+ distributionUrl =https\://services.gradle.org/distributions/gradle-2.2.1-all.zip
Original file line number Diff line number Diff line change 1+ #! /usr/bin/env sh
2+
3+ wget http://dl.google.com/android/ndk/android-ndk-r10e-linux-x86_64.bin
4+
5+ chmod a+x android-ndk-r10e-linux-x86_64.bin
6+
7+ ./android-ndk-r10e-linux-x86_64.bin > /dev/null 2>&1
8+
9+ mv android-ndk-r10e ../android-ndk
You can’t perform that action at this time.
0 commit comments