Compare commits
39 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 5b3816b121 | |||
| c373dc32e0 | |||
| c679de1af7 | |||
| bdcee571bb | |||
| 00233e707d | |||
| c658b6af61 | |||
| 740a290a71 | |||
| 9627fe43c3 | |||
| df6dd51b7d | |||
| 6b8f83b9ff | |||
| 50c91e58be | |||
| 14ffa7ee35 | |||
| 23948da2de | |||
| 56621fbffb | |||
| 3c398cb8a0 | |||
| dac231cad3 | |||
| 080906ea0d | |||
| 13fed8c537 | |||
| 105126acef | |||
| 99dc774b34 | |||
| 554e714b37 | |||
| 10a464220f | |||
| 080bb47c28 | |||
| c2b44c40eb | |||
| 95be9fac95 | |||
| b1ca8f4841 | |||
| 2dbfad6915 | |||
| 5a7fba3574 | |||
| b84faa479d | |||
| bdcd943c94 | |||
| 915a8e1e2b | |||
| e29aa828d6 | |||
| 99a6f18f5f | |||
| 8af793fccb | |||
| e5f9f72038 | |||
| 0baff685d7 | |||
| 6d5cb88d0a | |||
| 6fc1ed06c6 | |||
| 4c86999458 |
+8
-8
@@ -38,13 +38,13 @@ jobs:
|
||||
- extra-google-m2repository
|
||||
- extra-android-m2repository
|
||||
install:
|
||||
- echo y | sdkmanager "ndk-bundle"
|
||||
- echo y | sdkmanager "ndk;21.0.6113669"
|
||||
- echo y | sdkmanager "cmake;3.10.2.4988404"
|
||||
- echo y | sdkmanager "lldb;3.1"
|
||||
before_install:
|
||||
- touch $HOME/.android/repositories.cfg
|
||||
before_script:
|
||||
- export ANDROID_NDK_ROOT=$ANDROID_HOME/ndk-bundle
|
||||
- export ANDROID_NDK_ROOT=$ANDROID_HOME/ndk/21.0.6113669
|
||||
- rm -f ./build.log
|
||||
after_success:
|
||||
- grep -e INFO ./build.log | grep build
|
||||
@@ -52,7 +52,7 @@ jobs:
|
||||
- tail -30 ./build.log
|
||||
- tail -30 ./src/ffmpeg/ffbuild/config.log
|
||||
script:
|
||||
- bash ./android.sh --no-output-redirection
|
||||
- bash ./android.sh --no-output-redirection -d
|
||||
- name: "Android LTS Build"
|
||||
language: android
|
||||
os: linux
|
||||
@@ -86,13 +86,13 @@ jobs:
|
||||
- extra-google-m2repository
|
||||
- extra-android-m2repository
|
||||
install:
|
||||
- echo y | sdkmanager "ndk-bundle"
|
||||
- echo y | sdkmanager "ndk;21.0.6113669"
|
||||
- echo y | sdkmanager "cmake;3.10.2.4988404"
|
||||
- echo y | sdkmanager "lldb;3.1"
|
||||
before_install:
|
||||
- touch $HOME/.android/repositories.cfg
|
||||
before_script:
|
||||
- export ANDROID_NDK_ROOT=$ANDROID_HOME/ndk-bundle
|
||||
- export ANDROID_NDK_ROOT=$ANDROID_HOME/ndk/21.0.6113669
|
||||
- rm -f ./build.log
|
||||
after_success:
|
||||
- grep -e INFO ./build.log | grep build
|
||||
@@ -100,7 +100,7 @@ jobs:
|
||||
- tail -30 ./build.log
|
||||
- tail -30 ./src/ffmpeg/ffbuild/config.log
|
||||
script:
|
||||
- bash ./android.sh --lts --no-output-redirection
|
||||
- bash ./android.sh --lts --no-output-redirection -d
|
||||
- name: "iOS Main Build"
|
||||
language: objective-c
|
||||
os: osx
|
||||
@@ -118,7 +118,7 @@ jobs:
|
||||
- tail -30 ./build.log
|
||||
- tail -30 ./src/ffmpeg/ffbuild/config.log
|
||||
script:
|
||||
- bash ./ios.sh --no-output-redirection
|
||||
- bash ./ios.sh --no-output-redirection --disable-arm64e
|
||||
- name: "iOS LTS Build"
|
||||
language: objective-c
|
||||
osx_image: xcode7.3
|
||||
@@ -136,7 +136,7 @@ jobs:
|
||||
- tail -30 ./build.log
|
||||
- tail -30 ./src/ffmpeg/ffbuild/config.log
|
||||
script:
|
||||
- bash ./ios.sh --lts --no-output-redirection
|
||||
- bash ./ios.sh --lts --no-output-redirection --disable-armv7 --disable-armv7s --disable-i386
|
||||
- name: "tvOS Main Build"
|
||||
language: objective-c
|
||||
os: osx
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# MobileFFmpeg [](https://opencollective.com/mobile-ffmpeg)    [](https://travis-ci.org/tanersener/mobile-ffmpeg)
|
||||
# MobileFFmpeg [](https://opencollective.com/mobile-ffmpeg)    [](https://travis-ci.org/tanersener/mobile-ffmpeg)
|
||||
|
||||
FFmpeg for Android, iOS and tvOS
|
||||
|
||||
@@ -14,16 +14,16 @@ FFmpeg for Android, iOS and tvOS
|
||||
|
||||
`chromaprint`, `fontconfig`, `freetype`, `fribidi`, `gmp`, `gnutls`, `kvazaar`, `lame`, `libaom`, `libass`, `libiconv`, `libilbc`, `libtheora`, `libvorbis`, `libvpx`, `libwebp`, `libxml2`, `opencore-amr`, `openh264`, `opus`, `sdl`, `shine`, `snappy`, `soxr`, `speex`, `tesseract`, `twolame`, `wavpack`
|
||||
|
||||
- 4 external libraries with GPL license
|
||||
- 5 external libraries with GPL license
|
||||
|
||||
`vid.stab`, `x264`, `x265`, `xvidcore`
|
||||
`rubberband`, `vid.stab`, `x264`, `x265`, `xvidcore`
|
||||
|
||||
- Concurrent execution
|
||||
|
||||
- Exposes both FFmpeg library and MobileFFmpeg wrapper library capabilities
|
||||
- Includes cross-compile instructions for 44 open-source libraries
|
||||
- Includes cross-compile instructions for 46 open-source libraries
|
||||
|
||||
`chromaprint`, `expat`, `ffmpeg`, `fontconfig`, `freetype`, `fribidi`, `giflib`, `gmp`, `gnutls`, `kvazaar`, `lame`, `leptonica`, `libaom`, `libass`, `libiconv`, `libilbc`, `libjpeg`, `libjpeg-turbo`, `libogg`, `libpng`, `libsndfile`, `libtheora`, `libuuid`, `libvorbis`, `libvpx`, `libwebp`, `libxml2`, `nettle`, `opencore-amr`, `openh264`, `opus`, `sdl`, `shine`, `snappy`, `soxr`, `speex`, `tesseract`, `tiff`, `twolame`, `vid.stab`, `wavpack`, `x264`, `x265`, `xvidcore`
|
||||
`chromaprint`, `expat`, `ffmpeg`, `fontconfig`, `freetype`, `fribidi`, `giflib`, `gmp`, `gnutls`, `kvazaar`, `lame`, `leptonica`, `libaom`, `libass`, `libiconv`, `libilbc`, `libjpeg`, `libjpeg-turbo`, `libogg`, `libpng`, `libsamplerate`, `libsndfile`, `libtheora`, `libuuid`, `libvorbis`, `libvpx`, `libwebp`, `libxml2`, `nettle`, `opencore-amr`, `openh264`, `opus`, `rubberband`, `sdl`, `shine`, `snappy`, `soxr`, `speex`, `tesseract`, `tiff`, `twolame`, `vid.stab`, `wavpack`, `x264`, `x265`, `xvidcore`
|
||||
|
||||
- Licensed under LGPL 3.0, can be customized to support GPL v3.0
|
||||
|
||||
@@ -42,16 +42,16 @@ FFmpeg for Android, iOS and tvOS
|
||||
- Camera access
|
||||
- `ARC` enabled library
|
||||
- Built with `-fembed-bitcode` flag
|
||||
- Creates static framework and static universal (fat) library (.a)
|
||||
- Creates static frameworks, static xcframeworks and static universal (fat) libraries (.a)
|
||||
- Supports `iOS SDK 9.3` or later
|
||||
|
||||
#### 1.3 tvOS
|
||||
- Builds `arm64` and `x86_64` architectures
|
||||
- Supports `bzip2`, `zlib`, `iconv` system libraries and `AudioToolbox`, `CoreImage`, `VideoToolbox` system frameworks
|
||||
- Supports `bzip2`, `iconv`, `libuuid`, `zlib` system libraries and `AudioToolbox`, `CoreImage`, `VideoToolbox` system frameworks
|
||||
- Objective-C API
|
||||
- `ARC` enabled library
|
||||
- Built with `-fembed-bitcode` flag
|
||||
- Creates static framework and static universal (fat) library (.a)
|
||||
- Creates static frameworks and static universal (fat) libraries (.a)
|
||||
- Supports `tvOS SDK 9.2` or later
|
||||
|
||||
### 2. Using
|
||||
@@ -120,7 +120,7 @@ Please remember that some parts of `FFmpeg` are licensed under the `GPL` and onl
|
||||
1. Add MobileFFmpeg dependency to your `build.gradle` in `mobile-ffmpeg-<package name>` format
|
||||
```
|
||||
dependencies {
|
||||
implementation 'com.arthenica:mobile-ffmpeg-full:4.3.1'
|
||||
implementation 'com.arthenica:mobile-ffmpeg-full:4.3.2'
|
||||
}
|
||||
```
|
||||
|
||||
@@ -223,12 +223,12 @@ Please remember that some parts of `FFmpeg` are licensed under the `GPL` and onl
|
||||
|
||||
- iOS
|
||||
```
|
||||
pod 'mobile-ffmpeg-full', '~> 4.3.1'
|
||||
pod 'mobile-ffmpeg-full', '~> 4.3.2'
|
||||
```
|
||||
|
||||
- tvOS
|
||||
```
|
||||
pod 'mobile-ffmpeg-tvos-full', '~> 4.3.1'
|
||||
pod 'mobile-ffmpeg-tvos-full', '~> 4.3.2'
|
||||
```
|
||||
|
||||
2. Execute FFmpeg commands.
|
||||
@@ -362,6 +362,7 @@ Exact version number is obtained using `git describe --tags`.
|
||||
|
||||
| MobileFFmpeg Version | FFmpeg Version | Release Date |
|
||||
| :----: | :----: |:----: |
|
||||
| [4.3.2](https://github.com/tanersener/mobile-ffmpeg/releases/tag/v4.3.2) | 4.3-dev-2955 | Apr 15, 2020 |
|
||||
| [4.3.1](https://github.com/tanersener/mobile-ffmpeg/releases/tag/v4.3.1) | 4.3-dev-1944 | Jan 25, 2020 |
|
||||
| [4.3.1.LTS](https://github.com/tanersener/mobile-ffmpeg/releases/tag/v4.3.1.LTS) | 4.3-dev-1944 | Jan 25, 2020 |
|
||||
| [4.3](https://github.com/tanersener/mobile-ffmpeg/releases/tag/v4.3) | 4.3-dev-1181 | Oct 27, 2019 |
|
||||
@@ -397,10 +398,14 @@ This table shows the differences between two variants.
|
||||
| Android Architectures | arm-v7a-neon<br/>arm64-v8a<br/>x86<br/>x86-64 | arm-v7a<br/>arm-v7a-neon<br/>arm64-v8a<br/>x86<br/>x86-64 |
|
||||
| Xcode Support | 10.1 | 7.3.1 |
|
||||
| iOS SDK | 12.1 | 9.3 |
|
||||
| iOS Architectures | arm64<br/>arm64e<br/>x86-64 | armv7<br/>arm64<br/>i386<br/>x86-64 |
|
||||
| iOS Architectures | arm64<br/>arm64e<sup>1</sup><br/>x86-64<br/>x86-64-mac-catalyst<sup>2</sup> | armv7<br/>arm64<br/>i386<br/>x86-64 |
|
||||
| tvOS SDK | 10.2 | 9.2 |
|
||||
| tvOS Architectures | arm64<br/>x86-64 | arm64<br/>x86-64 |
|
||||
|
||||
<sup>1</sup> - Included until `v4.3.2`
|
||||
|
||||
<sup>2</sup> - Included since `v4.3.2`
|
||||
|
||||
### 5. Building
|
||||
|
||||
Build scripts from `master` and `development` branches are tested periodically. See the latest status from the table below.
|
||||
@@ -424,7 +429,7 @@ Please visit [Android Prerequisites](https://github.com/tanersener/mobile-ffmpeg
|
||||
|
||||
2. Android builds require these additional packages.
|
||||
- **Android SDK 4.1 Jelly Bean (API Level 16)** or later
|
||||
- **Android NDK r20** or later with LLDB and CMake
|
||||
- **Android NDK r21** or later with LLDB and CMake
|
||||
|
||||
3. iOS builds need these extra packages and tools.
|
||||
- **Xcode 7.3.1** or later
|
||||
@@ -478,14 +483,16 @@ All libraries created by the top level build scripts (`android.sh`, `ios.sh` and
|
||||
the `prebuilt` directory.
|
||||
|
||||
- `Android` archive (.aar file) is located under the `android-aar` folder
|
||||
- `iOS` frameworks are located under the `ios-framework`folder
|
||||
- `iOS` universal binaries are located under the `ios-universal`folder
|
||||
- `tvOS` frameworks are located under the `tvos-framework`folder
|
||||
- `tvOS` universal binaries are located under the `tvos-universal`folder
|
||||
- `iOS` frameworks are located under the `ios-framework` folder
|
||||
- `iOS` xcframeworks are located under the `ios-xcframework` folder
|
||||
- `iOS` universal binaries are located under the `ios-universal` folder
|
||||
- `tvOS` frameworks are located under the `tvos-framework` folder
|
||||
- `tvOS` universal binaries are located under the `tvos-universal` folder
|
||||
|
||||
#### 5.4 GPL Support
|
||||
It is possible to enable GPL licensed libraries `x264`, `xvidcore` since `v1.1` and `vid.stab`, `x265` since `v2.1`
|
||||
from the top level build scripts. Their source code is not included in the repository and downloaded when enabled.
|
||||
It is possible to enable GPL licensed libraries `x264`, `xvidcore` since `v1.1`; `vid.stab`, `x265` since `v2.1` and
|
||||
`rubberband` since `v4.3.2` from the top level build scripts. Their source code is not included in the repository and
|
||||
downloaded when enabled.
|
||||
|
||||
#### 5.5 External Libraries
|
||||
`build` directory includes build scripts of all external libraries. Two scripts exist for each external library,
|
||||
@@ -549,7 +556,11 @@ Please visit [License](https://github.com/tanersener/mobile-ffmpeg/wiki/License)
|
||||
|
||||
### 9. Contributing
|
||||
|
||||
If you have any recommendations or ideas to improve it, please feel free to submit issues or pull requests. Any help is appreciated.
|
||||
Feel free to submit issues or pull requests.
|
||||
|
||||
Please note that `master` branch includes only the latest released source code. Changes planned for the next release
|
||||
are implemented under the `development` branch. So, if you want to create a pull request, please open it against the
|
||||
`development`.
|
||||
|
||||
### 10. See Also
|
||||
|
||||
|
||||
+560
-564
File diff suppressed because it is too large
Load Diff
@@ -38,7 +38,7 @@ PROJECT_NAME = "MobileFFmpeg Android API"
|
||||
# could be handy for archiving the generated documentation or if some version
|
||||
# control system is used.
|
||||
|
||||
PROJECT_NUMBER = 4.3.1
|
||||
PROJECT_NUMBER = 4.3.2
|
||||
|
||||
# Using the PROJECT_BRIEF tag one can provide an optional one line description
|
||||
# for a project that appears at the top of each page and should give viewer a
|
||||
|
||||
@@ -2,12 +2,13 @@ apply plugin: 'com.android.library'
|
||||
|
||||
android {
|
||||
compileSdkVersion 29
|
||||
ndkVersion "21.0.6113669"
|
||||
|
||||
defaultConfig {
|
||||
minSdkVersion 24
|
||||
targetSdkVersion 29
|
||||
versionCode 240431
|
||||
versionName "4.3.1"
|
||||
versionCode 240432
|
||||
versionName "4.3.2"
|
||||
project.archivesBaseName = "mobile-ffmpeg"
|
||||
consumerProguardFiles 'proguard-rules.pro'
|
||||
}
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
#include "libavutil/ffversion.h"
|
||||
|
||||
/** Library version string */
|
||||
#define MOBILE_FFMPEG_VERSION "4.3.1"
|
||||
#define MOBILE_FFMPEG_VERSION "4.3.2"
|
||||
|
||||
/** Defines tag used for Android logging. */
|
||||
#define LIB_NAME "mobile-ffmpeg"
|
||||
|
||||
@@ -85,7 +85,7 @@ public class Config {
|
||||
/* LOAD NOT-LOADED LIBRARIES ON API < 21 */
|
||||
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.LOLLIPOP) {
|
||||
final List<String> externalLibrariesEnabled = getExternalLibraries();
|
||||
if (externalLibrariesEnabled.contains("tesseract") || externalLibrariesEnabled.contains("x265") || externalLibrariesEnabled.contains("snappy") || externalLibrariesEnabled.contains("openh264")) {
|
||||
if (externalLibrariesEnabled.contains("tesseract") || externalLibrariesEnabled.contains("x265") || externalLibrariesEnabled.contains("snappy") || externalLibrariesEnabled.contains("openh264") || externalLibrariesEnabled.contains("rubberband")) {
|
||||
// libc++_shared.so included only when tesseract or x265 is enabled
|
||||
System.loadLibrary("c++_shared");
|
||||
}
|
||||
|
||||
@@ -54,6 +54,7 @@ class Packages {
|
||||
supportedExternalLibraries.add("opencore-amr");
|
||||
supportedExternalLibraries.add("openh264");
|
||||
supportedExternalLibraries.add("opus");
|
||||
supportedExternalLibraries.add("rubberband");
|
||||
supportedExternalLibraries.add("sdl2");
|
||||
supportedExternalLibraries.add("shine");
|
||||
supportedExternalLibraries.add("snappy");
|
||||
|
||||
@@ -6,7 +6,7 @@ buildscript {
|
||||
jcenter()
|
||||
}
|
||||
dependencies {
|
||||
classpath 'com.android.tools.build:gradle:3.5.3'
|
||||
classpath 'com.android.tools.build:gradle:3.6.2'
|
||||
|
||||
// NOTE: Do not place your application dependencies here; they belong
|
||||
// in the individual module build.gradle files
|
||||
|
||||
@@ -14,8 +14,8 @@ android {
|
||||
applicationId "com.arthenica.mobileffmpeg.test"
|
||||
minSdkVersion 24
|
||||
targetSdkVersion 29
|
||||
versionCode 240431
|
||||
versionName "4.3.1"
|
||||
versionCode 240432
|
||||
versionName "4.3.2"
|
||||
}
|
||||
buildTypes {
|
||||
debug {
|
||||
@@ -52,7 +52,8 @@ android.applicationVariants.all { variant ->
|
||||
|
||||
dependencies {
|
||||
// implementation project(':app')
|
||||
implementation 'com.arthenica:mobile-ffmpeg-full:4.3.1'
|
||||
implementation 'com.arthenica:mobile-ffmpeg-full:4.3.2'
|
||||
implementation 'com.arthenica:smart-exception-java:0.1.0'
|
||||
implementation 'androidx.appcompat:appcompat:1.1.0'
|
||||
implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
|
||||
}
|
||||
|
||||
@@ -36,6 +36,7 @@ import com.arthenica.mobileffmpeg.Config;
|
||||
import com.arthenica.mobileffmpeg.util.AsyncSingleFFmpegExecuteTask;
|
||||
import com.arthenica.mobileffmpeg.util.ResourcesUtil;
|
||||
import com.arthenica.mobileffmpeg.util.SingleExecuteCallback;
|
||||
import com.arthenica.smartexception.java.Exceptions;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
@@ -56,6 +57,10 @@ public class MainActivity extends AppCompatActivity {
|
||||
Manifest.permission.CAMERA
|
||||
};
|
||||
|
||||
static {
|
||||
Exceptions.registerRootPackage("com.arthenica");
|
||||
}
|
||||
|
||||
protected static final Queue<Callable> actionQueue = new ConcurrentLinkedQueue<>();
|
||||
|
||||
protected static final Handler handler = new Handler();
|
||||
@@ -72,7 +77,7 @@ public class MainActivity extends AppCompatActivity {
|
||||
try {
|
||||
callable.call();
|
||||
} catch (final Exception e) {
|
||||
android.util.Log.e(MainActivity.TAG, "Running UI action received error.", e);
|
||||
android.util.Log.e(TAG, String.format("Running UI action received error.%s", Exceptions.getStackTraceString(e)));
|
||||
}
|
||||
}
|
||||
} while (callable != null);
|
||||
@@ -123,7 +128,7 @@ public class MainActivity extends AppCompatActivity {
|
||||
registerAppFont();
|
||||
Log.d(TAG, "Application fonts registered.");
|
||||
} catch (final IOException e) {
|
||||
Log.e(TAG, "Font registration failed.", e);
|
||||
Log.e(TAG, String.format("Font registration failed.%s", Exceptions.getStackTraceString(e)));
|
||||
}
|
||||
|
||||
Log.d(TAG, "Listing supported camera ids.");
|
||||
|
||||
@@ -43,6 +43,7 @@ import com.arthenica.mobileffmpeg.util.AsyncCatImageTask;
|
||||
import com.arthenica.mobileffmpeg.util.DialogUtil;
|
||||
import com.arthenica.mobileffmpeg.util.ResourcesUtil;
|
||||
import com.arthenica.mobileffmpeg.util.SingleExecuteCallback;
|
||||
import com.arthenica.smartexception.java.Exceptions;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
@@ -188,7 +189,7 @@ public class PipeTabFragment extends Fragment {
|
||||
startAsyncCatImageProcess(image3File.getAbsolutePath(), pipe3);
|
||||
|
||||
} catch (IOException e) {
|
||||
Log.e(TAG, "Create video failed", e);
|
||||
Log.e(TAG, String.format("Create video failed %s", Exceptions.getStackTraceString(e)));
|
||||
Popup.show(requireContext(), "Create video failed");
|
||||
}
|
||||
}
|
||||
|
||||
+3
-2
@@ -42,6 +42,7 @@ import com.arthenica.mobileffmpeg.StatisticsCallback;
|
||||
import com.arthenica.mobileffmpeg.util.DialogUtil;
|
||||
import com.arthenica.mobileffmpeg.util.ResourcesUtil;
|
||||
import com.arthenica.mobileffmpeg.util.SingleExecuteCallback;
|
||||
import com.arthenica.smartexception.java.Exceptions;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
@@ -103,7 +104,7 @@ public class SubtitleTabFragment extends Fragment {
|
||||
|
||||
@Override
|
||||
public void apply(LogMessage message) {
|
||||
android.util.Log.d(MainActivity.TAG, message.getText());
|
||||
Log.d(MainActivity.TAG, message.getText());
|
||||
}
|
||||
});
|
||||
}
|
||||
@@ -229,7 +230,7 @@ public class SubtitleTabFragment extends Fragment {
|
||||
}, ffmpegCommand);
|
||||
|
||||
} catch (IOException e) {
|
||||
Log.e(TAG, "Burn subtitles failed", e);
|
||||
Log.e(TAG, String.format("Burn subtitles failed %s", Exceptions.getStackTraceString(e)));
|
||||
Popup.show(requireContext(), "Burn subtitles failed");
|
||||
}
|
||||
}
|
||||
|
||||
+15
-14
@@ -38,6 +38,7 @@ import com.arthenica.mobileffmpeg.LogMessage;
|
||||
import com.arthenica.mobileffmpeg.util.DialogUtil;
|
||||
import com.arthenica.mobileffmpeg.util.ResourcesUtil;
|
||||
import com.arthenica.mobileffmpeg.util.SingleExecuteCallback;
|
||||
import com.arthenica.smartexception.java.Exceptions;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
@@ -92,7 +93,7 @@ public class VidStabTabFragment extends Fragment {
|
||||
|
||||
@Override
|
||||
public void apply(LogMessage message) {
|
||||
android.util.Log.d(MainActivity.TAG, message.getText());
|
||||
Log.d(MainActivity.TAG, message.getText());
|
||||
}
|
||||
});
|
||||
}
|
||||
@@ -121,7 +122,7 @@ public class VidStabTabFragment extends Fragment {
|
||||
stabilizedVideoFile.delete();
|
||||
}
|
||||
|
||||
android.util.Log.d(TAG, "Testing VID.STAB");
|
||||
Log.d(TAG, "Testing VID.STAB");
|
||||
|
||||
showCreateProgressDialog();
|
||||
|
||||
@@ -131,13 +132,13 @@ public class VidStabTabFragment extends Fragment {
|
||||
|
||||
final String ffmpegCommand = Video.generateShakingVideoScript(image1File.getAbsolutePath(), image2File.getAbsolutePath(), image3File.getAbsolutePath(), videoFile.getAbsolutePath());
|
||||
|
||||
android.util.Log.d(TAG, String.format("FFmpeg process started with arguments\n'%s'", ffmpegCommand));
|
||||
Log.d(TAG, String.format("FFmpeg process started with arguments\n'%s'", ffmpegCommand));
|
||||
|
||||
MainActivity.executeAsync(new SingleExecuteCallback() {
|
||||
|
||||
@Override
|
||||
public void apply(final int returnCode, final String commandOutput) {
|
||||
android.util.Log.d(TAG, String.format("FFmpeg process exited with rc %d", returnCode));
|
||||
Log.d(TAG, String.format("FFmpeg process exited with rc %d", returnCode));
|
||||
|
||||
hideCreateProgressDialog();
|
||||
|
||||
@@ -147,30 +148,30 @@ public class VidStabTabFragment extends Fragment {
|
||||
public Object call() {
|
||||
if (returnCode == RETURN_CODE_SUCCESS) {
|
||||
|
||||
android.util.Log.d(TAG, "Create completed successfully; stabilizing video.");
|
||||
Log.d(TAG, "Create completed successfully; stabilizing video.");
|
||||
|
||||
final String analyzeVideoCommand = String.format("-y -i %s -vf vidstabdetect=shakiness=10:accuracy=15:result=%s -f null -", videoFile.getAbsolutePath(), shakeResultsFile.getAbsolutePath());
|
||||
|
||||
showStabilizeProgressDialog();
|
||||
|
||||
android.util.Log.d(TAG, String.format("FFmpeg process started with arguments\n'%s'", analyzeVideoCommand));
|
||||
Log.d(TAG, String.format("FFmpeg process started with arguments\n'%s'", analyzeVideoCommand));
|
||||
|
||||
MainActivity.executeAsync(new SingleExecuteCallback() {
|
||||
|
||||
@Override
|
||||
public void apply(final int returnCode, final String commandOutput) {
|
||||
android.util.Log.d(TAG, String.format("FFmpeg process exited with rc %d", returnCode));
|
||||
Log.d(TAG, String.format("FFmpeg process exited with rc %d", returnCode));
|
||||
|
||||
if (returnCode == RETURN_CODE_SUCCESS) {
|
||||
final String stabilizeVideoCommand = String.format("-y -i %s -vf vidstabtransform=smoothing=30:input=%s -c:v mpeg4 %s", videoFile.getAbsolutePath(), shakeResultsFile.getAbsolutePath(), stabilizedVideoFile.getAbsolutePath());
|
||||
|
||||
android.util.Log.d(TAG, String.format("FFmpeg process started with arguments\n'%s'", stabilizeVideoCommand));
|
||||
Log.d(TAG, String.format("FFmpeg process started with arguments\n'%s'", stabilizeVideoCommand));
|
||||
|
||||
MainActivity.executeAsync(new SingleExecuteCallback() {
|
||||
|
||||
@Override
|
||||
public void apply(final int returnCode, final String commandOutput) {
|
||||
android.util.Log.d(TAG, String.format("FFmpeg process exited with rc %d", returnCode));
|
||||
Log.d(TAG, String.format("FFmpeg process exited with rc %d", returnCode));
|
||||
|
||||
hideStabilizeProgressDialog();
|
||||
|
||||
@@ -179,12 +180,12 @@ public class VidStabTabFragment extends Fragment {
|
||||
@Override
|
||||
public Object call() {
|
||||
if (returnCode == RETURN_CODE_SUCCESS) {
|
||||
android.util.Log.d(TAG, "Stabilize video completed successfully; playing videos.");
|
||||
Log.d(TAG, "Stabilize video completed successfully; playing videos.");
|
||||
playVideo();
|
||||
playStabilizedVideo();
|
||||
} else {
|
||||
Popup.show(requireContext(), "Stabilize video failed. Please check log for the details.");
|
||||
android.util.Log.d(TAG, String.format("Stabilize video failed with rc=%d", returnCode));
|
||||
Log.d(TAG, String.format("Stabilize video failed with rc=%d", returnCode));
|
||||
}
|
||||
|
||||
return null;
|
||||
@@ -196,14 +197,14 @@ public class VidStabTabFragment extends Fragment {
|
||||
} else {
|
||||
hideStabilizeProgressDialog();
|
||||
Popup.show(requireContext(), "Stabilize video failed. Please check log for the details.");
|
||||
android.util.Log.d(TAG, String.format("Stabilize video failed with rc=%d", returnCode));
|
||||
Log.d(TAG, String.format("Stabilize video failed with rc=%d", returnCode));
|
||||
}
|
||||
}
|
||||
}, analyzeVideoCommand);
|
||||
|
||||
} else {
|
||||
Popup.show(requireContext(), "Create video failed. Please check log for the details.");
|
||||
android.util.Log.d(TAG, String.format("Create failed with rc=%d", returnCode));
|
||||
Log.d(TAG, String.format("Create failed with rc=%d", returnCode));
|
||||
}
|
||||
|
||||
return null;
|
||||
@@ -213,7 +214,7 @@ public class VidStabTabFragment extends Fragment {
|
||||
}, ffmpegCommand);
|
||||
|
||||
} catch (IOException e) {
|
||||
android.util.Log.e(TAG, "Stabilize video failed", e);
|
||||
Log.e(TAG, String.format("Stabilize video failed %s", Exceptions.getStackTraceString(e)));
|
||||
Popup.show(requireContext(), "Stabilize video failed");
|
||||
}
|
||||
}
|
||||
|
||||
+3
-2
@@ -46,6 +46,7 @@ import com.arthenica.mobileffmpeg.StatisticsCallback;
|
||||
import com.arthenica.mobileffmpeg.util.DialogUtil;
|
||||
import com.arthenica.mobileffmpeg.util.ResourcesUtil;
|
||||
import com.arthenica.mobileffmpeg.util.SingleExecuteCallback;
|
||||
import com.arthenica.smartexception.java.Exceptions;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
@@ -206,7 +207,7 @@ public class VideoTabFragment extends Fragment implements AdapterView.OnItemSele
|
||||
}, ffmpegCommand);
|
||||
|
||||
} catch (IOException e) {
|
||||
Log.e(TAG, "Encode video failed", e);
|
||||
Log.e(TAG, String.format("Encode video failed %s", Exceptions.getStackTraceString(e)));
|
||||
Popup.show(requireContext(), "Encode video failed");
|
||||
}
|
||||
}
|
||||
@@ -228,7 +229,7 @@ public class VideoTabFragment extends Fragment implements AdapterView.OnItemSele
|
||||
|
||||
Log.d(TAG, String.format("FFmpeg process exited with rc %d", returnCode));
|
||||
} catch (IOException e) {
|
||||
Log.e(TAG, "Encode webp failed", e);
|
||||
Log.e(TAG, String.format("Encode webp failed %s", Exceptions.getStackTraceString(e)));
|
||||
Popup.show(requireContext(), "Encode webp failed");
|
||||
}
|
||||
}
|
||||
|
||||
+3
-1
@@ -22,6 +22,8 @@ package com.arthenica.mobileffmpeg.util;
|
||||
import android.os.AsyncTask;
|
||||
import android.util.Log;
|
||||
|
||||
import com.arthenica.smartexception.java.Exceptions;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
import static com.arthenica.mobileffmpeg.test.MainActivity.TAG;
|
||||
@@ -41,7 +43,7 @@ public class AsyncCatImageTask extends AsyncTask<String, Integer, Integer> {
|
||||
|
||||
return rc;
|
||||
} catch (final IOException | InterruptedException e) {
|
||||
Log.e(TAG, String.format("Async cat image command failed for %s.", inputs[0]), e);
|
||||
Log.e(TAG, String.format("Async cat image command failed for %s.%s", inputs[0], Exceptions.getStackTraceString(e)));
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -25,12 +25,15 @@ import android.graphics.BitmapFactory;
|
||||
import android.util.Log;
|
||||
|
||||
import com.arthenica.mobileffmpeg.test.MainActivity;
|
||||
import com.arthenica.smartexception.java.Exceptions;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.FileOutputStream;
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
|
||||
import static com.arthenica.mobileffmpeg.test.MainActivity.TAG;
|
||||
|
||||
public class ResourcesUtil {
|
||||
public static void resourceToFile(Resources resources, final int resourceId, final File file) throws IOException {
|
||||
Bitmap bitmap = BitmapFactory.decodeResource(resources, resourceId);
|
||||
@@ -60,7 +63,7 @@ public class ResourcesUtil {
|
||||
outputStream.write(buffer, 0, readSize);
|
||||
}
|
||||
} catch (final IOException e) {
|
||||
Log.e(MainActivity.TAG, "Saving raw resource failed.", e);
|
||||
Log.e(TAG, String.format("Saving raw resource failed.%s", Exceptions.getStackTraceString(e)));
|
||||
} finally {
|
||||
inputStream.close();
|
||||
outputStream.flush();
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="chromaprint"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
|
||||
+48
-54
@@ -40,28 +40,30 @@ get_library_name() {
|
||||
19) echo "xvidcore" ;;
|
||||
20) echo "x265" ;;
|
||||
21) echo "libvidstab" ;;
|
||||
22) echo "libilbc" ;;
|
||||
23) echo "opus" ;;
|
||||
24) echo "snappy" ;;
|
||||
25) echo "soxr" ;;
|
||||
26) echo "libaom" ;;
|
||||
27) echo "chromaprint" ;;
|
||||
28) echo "twolame" ;;
|
||||
29) echo "sdl" ;;
|
||||
30) echo "tesseract" ;;
|
||||
31) echo "openh264" ;;
|
||||
32) echo "giflib" ;;
|
||||
33) echo "jpeg" ;;
|
||||
34) echo "libogg" ;;
|
||||
35) echo "libpng" ;;
|
||||
36) echo "libuuid" ;;
|
||||
37) echo "nettle" ;;
|
||||
38) echo "tiff" ;;
|
||||
39) echo "expat" ;;
|
||||
40) echo "libsndfile" ;;
|
||||
41) echo "leptonica" ;;
|
||||
42) echo "android-zlib" ;;
|
||||
43) echo "android-media-codec" ;;
|
||||
22) echo "rubberband" ;;
|
||||
23) echo "libilbc" ;;
|
||||
24) echo "opus" ;;
|
||||
25) echo "snappy" ;;
|
||||
26) echo "soxr" ;;
|
||||
27) echo "libaom" ;;
|
||||
28) echo "chromaprint" ;;
|
||||
29) echo "twolame" ;;
|
||||
30) echo "sdl" ;;
|
||||
31) echo "tesseract" ;;
|
||||
32) echo "openh264" ;;
|
||||
33) echo "giflib" ;;
|
||||
34) echo "jpeg" ;;
|
||||
35) echo "libogg" ;;
|
||||
36) echo "libpng" ;;
|
||||
37) echo "libuuid" ;;
|
||||
38) echo "nettle" ;;
|
||||
39) echo "tiff" ;;
|
||||
40) echo "expat" ;;
|
||||
41) echo "libsndfile" ;;
|
||||
42) echo "leptonica" ;;
|
||||
43) echo "libsamplerate" ;;
|
||||
44) echo "android-zlib" ;;
|
||||
45) echo "android-media-codec" ;;
|
||||
esac
|
||||
}
|
||||
|
||||
@@ -204,7 +206,7 @@ get_android_arch() {
|
||||
}
|
||||
|
||||
get_common_includes() {
|
||||
echo "-I${ANDROID_NDK_ROOT}/toolchains/llvm/prebuilt/${TOOLCHAIN}/sysroot/usr/include -I${ANDROID_NDK_ROOT}/toolchains/llvm/prebuilt/${TOOLCHAIN}/sysroot/usr/local/include"
|
||||
echo ""
|
||||
}
|
||||
|
||||
get_common_cflags() {
|
||||
@@ -282,7 +284,6 @@ get_size_optimization_cflags() {
|
||||
}
|
||||
|
||||
get_app_specific_cflags() {
|
||||
|
||||
local APP_FLAGS=""
|
||||
case $1 in
|
||||
xvidcore)
|
||||
@@ -291,15 +292,18 @@ get_app_specific_cflags() {
|
||||
ffmpeg)
|
||||
APP_FLAGS="-Wno-unused-function -DBIONIC_IOCTL_NO_SIGNEDNESS_OVERLOAD"
|
||||
;;
|
||||
kvazaar)
|
||||
APP_FLAGS="-std=gnu99 -Wno-unused-function"
|
||||
;;
|
||||
rubberband)
|
||||
APP_FLAGS="-std=c99 -Wno-unused-function"
|
||||
;;
|
||||
shine)
|
||||
APP_FLAGS="-Wno-unused-function"
|
||||
;;
|
||||
soxr | snappy | libwebp)
|
||||
APP_FLAGS="-std=gnu99 -Wno-unused-function -DPIC"
|
||||
;;
|
||||
kvazaar)
|
||||
APP_FLAGS="-std=gnu99 -Wno-unused-function"
|
||||
;;
|
||||
*)
|
||||
APP_FLAGS="-std=c99 -Wno-unused-function"
|
||||
;;
|
||||
@@ -352,6 +356,9 @@ get_cxxflags() {
|
||||
x265)
|
||||
echo "-std=c++11 -fno-exceptions ${OPTIMIZATION_FLAGS}"
|
||||
;;
|
||||
rubberband)
|
||||
echo "-std=c++11 ${OPTIMIZATION_FLAGS}"
|
||||
;;
|
||||
*)
|
||||
echo "-std=c++11 -fno-exceptions -fno-rtti ${OPTIMIZATION_FLAGS}"
|
||||
;;
|
||||
@@ -674,25 +681,6 @@ Cflags: -I\${includedir}
|
||||
EOF
|
||||
}
|
||||
|
||||
create_libwebp_package_config() {
|
||||
local LIB_WEBP_VERSION="$1"
|
||||
|
||||
cat > "${INSTALL_PKG_CONFIG_DIR}/libwebp.pc" << EOF
|
||||
prefix=${BASEDIR}/prebuilt/android-$(get_target_build)/libwebp
|
||||
exec_prefix=\${prefix}
|
||||
libdir=\${prefix}/lib
|
||||
includedir=\${prefix}/include
|
||||
|
||||
Name: libwebp
|
||||
Description: webp codec library
|
||||
Version: ${LIB_WEBP_VERSION}
|
||||
|
||||
Requires:
|
||||
Libs: -L\${libdir} -lwebp -lwebpdecoder -lwebpdemux
|
||||
Cflags: -I\${includedir}
|
||||
EOF
|
||||
}
|
||||
|
||||
create_libxml2_package_config() {
|
||||
local LIBXML2_VERSION="$1"
|
||||
|
||||
@@ -831,7 +819,7 @@ Cflags: -I\${includedir}
|
||||
EOF
|
||||
}
|
||||
|
||||
create_zlib_package_config() {
|
||||
create_zlib_system_package_config() {
|
||||
ZLIB_VERSION=$(grep '#define ZLIB_VERSION' ${ANDROID_NDK_ROOT}/toolchains/llvm/prebuilt/${TOOLCHAIN}/sysroot/usr/include/zlib.h | grep -Eo '\".*\"' | sed -e 's/\"//g')
|
||||
|
||||
cat > "${INSTALL_PKG_CONFIG_DIR}/zlib.pc" << EOF
|
||||
@@ -913,15 +901,15 @@ download_gpl_library_source() {
|
||||
GPL_LIB_DEST_DIR="libvidstab"
|
||||
;;
|
||||
x264)
|
||||
GPL_LIB_URL="https://code.videolan.org/videolan/x264/-/archive/1771b556ee45207f8711744ccbd5d42a3949b14c/x264-1771b556ee45207f8711744ccbd5d42a3949b14c.tar.bz2"
|
||||
GPL_LIB_FILE="x264-1771b556ee45207f8711744ccbd5d42a3949b14c.tar.bz2"
|
||||
GPL_LIB_ORIG_DIR="x264-1771b556ee45207f8711744ccbd5d42a3949b14c"
|
||||
GPL_LIB_URL="https://code.videolan.org/videolan/x264/-/archive/296494a4011f58f32adc54304a2654627558c59a/x264-296494a4011f58f32adc54304a2654627558c59a.tar.bz2"
|
||||
GPL_LIB_FILE="x264-296494a4011f58f32adc54304a2654627558c59a.tar.bz2"
|
||||
GPL_LIB_ORIG_DIR="x264-296494a4011f58f32adc54304a2654627558c59a"
|
||||
GPL_LIB_DEST_DIR="x264"
|
||||
;;
|
||||
x265)
|
||||
GPL_LIB_URL="https://bitbucket.org/multicoreware/x265/downloads/x265_3.2.1.tar.gz"
|
||||
GPL_LIB_FILE="x265-3.2.1.tar.gz"
|
||||
GPL_LIB_ORIG_DIR="x265_3.2.1"
|
||||
GPL_LIB_URL="https://bitbucket.org/multicoreware/x265/downloads/x265_3.3.tar.gz"
|
||||
GPL_LIB_FILE="x265_3.3.tar.gz"
|
||||
GPL_LIB_ORIG_DIR="x265_3.3"
|
||||
GPL_LIB_DEST_DIR="x265"
|
||||
;;
|
||||
xvidcore)
|
||||
@@ -930,6 +918,12 @@ download_gpl_library_source() {
|
||||
GPL_LIB_ORIG_DIR="xvidcore"
|
||||
GPL_LIB_DEST_DIR="xvidcore"
|
||||
;;
|
||||
rubberband)
|
||||
GPL_LIB_URL="https://breakfastquay.com/files/releases/rubberband-1.8.2.tar.bz2"
|
||||
GPL_LIB_FILE="rubberband-1.8.2.tar.bz2"
|
||||
GPL_LIB_ORIG_DIR="rubberband-1.8.2"
|
||||
GPL_LIB_DEST_DIR="rubberband"
|
||||
;;
|
||||
esac
|
||||
|
||||
local GPL_LIB_SOURCE_PATH="${BASEDIR}/src/${GPL_LIB_DEST_DIR}"
|
||||
@@ -1033,7 +1027,7 @@ set_toolchain_clang_paths() {
|
||||
fi
|
||||
|
||||
if [ ! -f ${ZLIB_PACKAGE_CONFIG_PATH} ]; then
|
||||
create_zlib_package_config
|
||||
create_zlib_system_package_config
|
||||
fi
|
||||
|
||||
prepare_inline_sed
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="expat"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -37,7 +37,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_expat} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
+10
-11
@@ -29,7 +29,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="ffmpeg"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -76,7 +76,7 @@ esac
|
||||
CONFIGURE_POSTFIX=""
|
||||
HIGH_PRIORITY_INCLUDES=""
|
||||
|
||||
for library in {1..44}
|
||||
for library in {1..46}
|
||||
do
|
||||
if [[ ${!library} -eq 1 ]]; then
|
||||
ENABLED_LIBRARY=$(get_library_name $((library - 1)))
|
||||
@@ -194,6 +194,11 @@ do
|
||||
LDFLAGS+=" $(pkg-config --libs --static opus)"
|
||||
CONFIGURE_POSTFIX+=" --enable-libopus"
|
||||
;;
|
||||
rubberband)
|
||||
CFLAGS+=" $(pkg-config --cflags rubberband)"
|
||||
LDFLAGS+=" $(pkg-config --libs --static rubberband)"
|
||||
CONFIGURE_POSTFIX+=" --enable-librubberband --enable-gpl"
|
||||
;;
|
||||
shine)
|
||||
CFLAGS+=" $(pkg-config --cflags shine)"
|
||||
LDFLAGS+=" $(pkg-config --libs --static shine)"
|
||||
@@ -285,9 +290,9 @@ do
|
||||
else
|
||||
|
||||
# THE FOLLOWING LIBRARIES SHOULD BE EXPLICITLY DISABLED TO PREVENT AUTODETECT
|
||||
if [[ ${library} -eq 30 ]]; then
|
||||
if [[ ${library} -eq 31 ]]; then
|
||||
CONFIGURE_POSTFIX+=" --disable-sdl2"
|
||||
elif [[ ${library} -eq 43 ]]; then
|
||||
elif [[ ${library} -eq 45 ]]; then
|
||||
CONFIGURE_POSTFIX+=" --disable-zlib"
|
||||
fi
|
||||
fi
|
||||
@@ -336,10 +341,6 @@ export LDFLAGS="${LDFLAGS}"
|
||||
# USE HIGHER LIMITS FOR FFMPEG LINKING
|
||||
ulimit -n 2048 1>>${BASEDIR}/build.log 2>&1
|
||||
|
||||
# Workaround for issue #328
|
||||
rm -f ${BASEDIR}/src/${LIB_NAME}/libswscale/aarch64/hscale.S 1>>${BASEDIR}/build.log 2>&1
|
||||
cp ${BASEDIR}/tools/make/ffmpeg/libswscale/aarch64/hscale.S ${BASEDIR}/src/${LIB_NAME}/libswscale/aarch64/hscale.S 1>>${BASEDIR}/build.log 2>&1
|
||||
|
||||
./configure \
|
||||
--cross-prefix="${BUILD_HOST}-" \
|
||||
--sysroot="${ANDROID_NDK_ROOT}/toolchains/llvm/prebuilt/${TOOLCHAIN}/sysroot" \
|
||||
@@ -358,10 +359,8 @@ cp ${BASEDIR}/tools/make/ffmpeg/libswscale/aarch64/hscale.S ${BASEDIR}/src/${LIB
|
||||
--enable-optimizations \
|
||||
--enable-swscale \
|
||||
--enable-shared \
|
||||
--disable-v4l2-m2m \
|
||||
--disable-outdev=v4l2 \
|
||||
--enable-v4l2-m2m \
|
||||
--disable-outdev=fbdev \
|
||||
--disable-indev=v4l2 \
|
||||
--disable-indev=fbdev \
|
||||
${SIZE_OPTIONS} \
|
||||
--disable-openssl \
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="fontconfig"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -38,7 +38,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_fontconfig} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="freetype"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="fribidi"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -38,7 +38,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_fribidi} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="giflib"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -38,7 +38,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_giflib} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="gmp"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -37,7 +37,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_gmp} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
@@ -56,6 +56,6 @@ fi
|
||||
make -j$(get_cpu_count) || exit 1
|
||||
|
||||
# CREATE PACKAGE CONFIG MANUALLY
|
||||
create_gmp_package_config "6.1.2"
|
||||
create_gmp_package_config "6.2.0"
|
||||
|
||||
make install || exit 1
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="gnutls"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -58,7 +58,7 @@ esac
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_gnutls} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
@@ -88,6 +88,6 @@ fi
|
||||
make -j$(get_cpu_count) || exit 1
|
||||
|
||||
# CREATE PACKAGE CONFIG MANUALLY
|
||||
create_gnutls_package_config "3.6.11.1"
|
||||
create_gnutls_package_config "3.6.13"
|
||||
|
||||
make install || exit 1
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="jpeg"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="kvazaar"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -40,7 +40,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_kvazaar} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="lame"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -38,7 +38,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_lame} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="leptonica"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -54,7 +54,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_leptonica} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libaom"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libass"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -38,7 +38,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_libass} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libiconv"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -37,7 +37,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_libiconv} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libilbc"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -37,7 +37,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_libilbc} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libogg"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -37,7 +37,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_libogg} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libpng"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -33,19 +33,19 @@ export CFLAGS=$(get_cflags ${LIB_NAME})
|
||||
export CXXFLAGS=$(get_cxxflags ${LIB_NAME})
|
||||
export LDFLAGS=$(get_ldflags ${LIB_NAME})
|
||||
|
||||
CPU_SPECIFIC_OPTIONS=""
|
||||
ARCH_OPTIONS=""
|
||||
case ${ARCH} in
|
||||
x86 | x86-64)
|
||||
CPU_SPECIFIC_OPTIONS="--enable-hardware-optimizations --enable-intel-sse=yes"
|
||||
ARCH_OPTIONS="--enable-hardware-optimizations --enable-intel-sse=yes"
|
||||
;;
|
||||
arm-v7a-neon | arm64-v8a)
|
||||
CPU_SPECIFIC_OPTIONS="--enable-hardware-optimizations --enable-arm-neon=yes"
|
||||
ARCH_OPTIONS="--enable-hardware-optimizations --enable-arm-neon=yes"
|
||||
;;
|
||||
arm-v7a)
|
||||
# hardware-optimizations not enabled because
|
||||
# when --enable-hardware-optimizations is added
|
||||
# make tries to build arm-neon specific instructions, which breaks compilation
|
||||
CPU_SPECIFIC_OPTIONS="--enable-arm-neon=no"
|
||||
ARCH_OPTIONS="--enable-arm-neon=no"
|
||||
;;
|
||||
esac
|
||||
|
||||
@@ -53,7 +53,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_libpng} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
@@ -67,7 +67,7 @@ fi
|
||||
--disable-fast-install \
|
||||
--disable-unversioned-libpng-pc \
|
||||
--disable-unversioned-libpng-config \
|
||||
${CPU_SPECIFIC_OPTIONS} \
|
||||
${ARCH_OPTIONS} \
|
||||
--host=${BUILD_HOST} || exit 1
|
||||
|
||||
make -j$(get_cpu_count) || exit 1
|
||||
|
||||
Executable
+64
@@ -0,0 +1,64 @@
|
||||
#!/bin/bash
|
||||
|
||||
if [[ -z ${ANDROID_NDK_ROOT} ]]; then
|
||||
echo -e "(*) ANDROID_NDK_ROOT not defined\n"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [[ -z ${ARCH} ]]; then
|
||||
echo -e "(*) ARCH not defined\n"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [[ -z ${API} ]]; then
|
||||
echo -e "(*) API not defined\n"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [[ -z ${BASEDIR} ]]; then
|
||||
echo -e "(*) BASEDIR not defined\n"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libsamplerate"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
# PREPARING FLAGS
|
||||
BUILD_HOST=$(get_build_host)
|
||||
export CFLAGS=$(get_cflags ${LIB_NAME})
|
||||
export CXXFLAGS=$(get_cxxflags ${LIB_NAME})
|
||||
export LDFLAGS=$(get_ldflags ${LIB_NAME})
|
||||
export PKG_CONFIG_LIBDIR="${INSTALL_PKG_CONFIG_DIR}"
|
||||
|
||||
cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_libsamplerate} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
./configure \
|
||||
--prefix=${BASEDIR}/prebuilt/android-$(get_target_build)/${LIB_NAME} \
|
||||
--with-pic \
|
||||
--with-sysroot=${ANDROID_NDK_ROOT}/toolchains/llvm/prebuilt/${TOOLCHAIN}/sysroot \
|
||||
--enable-static \
|
||||
--disable-fftw \
|
||||
--disable-shared \
|
||||
--disable-fast-install \
|
||||
--host=${BUILD_HOST} || exit 1
|
||||
|
||||
# DISABLE building of examples manually
|
||||
${SED_INLINE} 's/examples tests//g' ${BASEDIR}/src/${LIB_NAME}/Makefile
|
||||
|
||||
make -j$(get_cpu_count) || exit 1
|
||||
|
||||
# MANUALLY COPY PKG-CONFIG FILES
|
||||
cp ./*.pc ${INSTALL_PKG_CONFIG_DIR} || exit 1
|
||||
|
||||
make install || exit 1
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libsndfile"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libtheora"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -38,7 +38,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_libtheora} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libuuid"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -37,7 +37,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_libuuid} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libvidstab"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libvorbis"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libvpx"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
|
||||
+34
-58
@@ -23,85 +23,61 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libwebp"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
# PREPARING FLAGS
|
||||
BUILD_HOST=$(get_build_host)
|
||||
CFLAGS=$(get_cflags ${LIB_NAME})
|
||||
CXXFLAGS=$(get_cxxflags ${LIB_NAME})
|
||||
LDFLAGS=$(get_ldflags ${LIB_NAME})
|
||||
export CFLAGS=$(get_cflags ${LIB_NAME})
|
||||
export CXXFLAGS=$(get_cxxflags ${LIB_NAME})
|
||||
export LDFLAGS=$(get_ldflags ${LIB_NAME})
|
||||
export PKG_CONFIG_LIBDIR="${INSTALL_PKG_CONFIG_DIR}"
|
||||
|
||||
ARCH_OPTIONS=""
|
||||
case ${ARCH} in
|
||||
arm-v7a)
|
||||
ARCH_OPTIONS="-DWEBP_ENABLE_SIMD=OFF"
|
||||
ARCH_OPTIONS="--disable-neon --disable-neon-rtcd"
|
||||
;;
|
||||
arm-v7a-neon | arm64-v8a)
|
||||
ARCH_OPTIONS="--enable-neon --enable-neon-rtcd"
|
||||
;;
|
||||
*)
|
||||
ARCH_OPTIONS="-DWEBP_ENABLE_SIMD=ON"
|
||||
ARCH_OPTIONS="--enable-sse2 --enable-sse4.1"
|
||||
;;
|
||||
esac
|
||||
|
||||
cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
if [ -d "build" ]; then
|
||||
rm -rf build
|
||||
fi
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
mkdir build;
|
||||
cd build
|
||||
# ALWAYS RECONFIGURE
|
||||
autoreconf_library ${LIB_NAME}
|
||||
|
||||
# OVERRIDING INCLUDE PATH ORDER
|
||||
CFLAGS="-I${BASEDIR}/prebuilt/android-$(get_target_build)/giflib/include \
|
||||
-I${BASEDIR}/prebuilt/android-$(get_target_build)/jpeg/include \
|
||||
-I${BASEDIR}/prebuilt/android-$(get_target_build)/libpng/include \
|
||||
-I${BASEDIR}/prebuilt/android-$(get_target_build)/tiff/include $CFLAGS"
|
||||
|
||||
cmake -Wno-dev \
|
||||
-DCMAKE_VERBOSE_MAKEFILE=0 \
|
||||
-DCMAKE_C_FLAGS="${CFLAGS}" \
|
||||
-DCMAKE_CXX_FLAGS="${CXXFLAGS}" \
|
||||
-DCMAKE_EXE_LINKER_FLAGS="${LDFLAGS}" \
|
||||
-DCMAKE_SYSROOT="${ANDROID_NDK_ROOT}/toolchains/llvm/prebuilt/${TOOLCHAIN}/sysroot" \
|
||||
-DCMAKE_FIND_ROOT_PATH="${ANDROID_NDK_ROOT}/toolchains/llvm/prebuilt/${TOOLCHAIN}/sysroot" \
|
||||
-DCMAKE_BUILD_TYPE=Release \
|
||||
-DCMAKE_INSTALL_PREFIX="${BASEDIR}/prebuilt/android-$(get_target_build)/${LIB_NAME}" \
|
||||
-DCMAKE_SYSTEM_NAME=Generic \
|
||||
-DCMAKE_C_COMPILER="${ANDROID_NDK_ROOT}/toolchains/llvm/prebuilt/${TOOLCHAIN}/bin/$CC" \
|
||||
-DCMAKE_LINKER="${ANDROID_NDK_ROOT}/toolchains/llvm/prebuilt/${TOOLCHAIN}/bin/$LD" \
|
||||
-DCMAKE_AR="${ANDROID_NDK_ROOT}/toolchains/llvm/prebuilt/${TOOLCHAIN}/bin/$AR" \
|
||||
-DCMAKE_AS="${ANDROID_NDK_ROOT}/toolchains/llvm/prebuilt/${TOOLCHAIN}/bin/$AS" \
|
||||
-DGIF_INCLUDE_DIR="${BASEDIR}/prebuilt/android-$(get_target_build)/giflib/include" \
|
||||
-DJPEG_INCLUDE_DIR="${BASEDIR}/prebuilt/android-$(get_target_build)/jpeg/include" \
|
||||
-DJPEG_LIBRARY="${BASEDIR}/prebuilt/android-$(get_target_build)/jpeg/lib" \
|
||||
-DPNG_PNG_INCLUDE_DIR="${BASEDIR}/prebuilt/android-$(get_target_build)/libpng/include" \
|
||||
-DPNG_LIBRARY="${BASEDIR}/prebuilt/android-$(get_target_build)/libpng/lib" \
|
||||
-DTIFF_INCLUDE_DIR="${BASEDIR}/prebuilt/android-$(get_target_build)/tiff/include" \
|
||||
-DTIFF_LIBRARY="${BASEDIR}/prebuilt/android-$(get_target_build)/tiff/lib" \
|
||||
-DZLIB_INCLUDE_DIR="${ANDROID_NDK_ROOT}/toolchains/llvm/prebuilt/${TOOLCHAIN}/sysroot/usr/include" \
|
||||
-DZLIB_LIBRARY="${ANDROID_NDK_ROOT}/platform/android-${API}/arch-$(get_target_build)/usr/lib" \
|
||||
-DCMAKE_POSITION_INDEPENDENT_CODE=1 \
|
||||
-DGLUT_INCLUDE_DIR= \
|
||||
-DGLUT_cocoa_LIBRARY= \
|
||||
-DGLUT_glut_LIBRARY= \
|
||||
-DOPENGL_INCLUDE_DIR= \
|
||||
-DSDLMAIN_LIBRARY= \
|
||||
-DSDL_INCLUDE_DIR= \
|
||||
-DWEBP_BUILD_CWEBP=0 \
|
||||
-DWEBP_BUILD_DWEBP=0 \
|
||||
-DWEBP_BUILD_EXTRAS=0 \
|
||||
-DWEBP_BUILD_GIF2WEBP=0 \
|
||||
-DWEBP_BUILD_IMG2WEBP=0 \
|
||||
-DWEBP_BUILD_WEBPMUX=0 \
|
||||
-DWEBP_BUILD_WEBPINFO=0 \
|
||||
./configure \
|
||||
--prefix=${BASEDIR}/prebuilt/android-$(get_target_build)/${LIB_NAME} \
|
||||
--with-pic \
|
||||
--with-sysroot=${ANDROID_NDK_ROOT}/toolchains/llvm/prebuilt/${TOOLCHAIN}/sysroot \
|
||||
--enable-static \
|
||||
--disable-shared \
|
||||
--disable-dependency-tracking \
|
||||
--enable-libwebpmux \
|
||||
${ARCH_OPTIONS} \
|
||||
-DCMAKE_SYSTEM_PROCESSOR=$(get_cmake_target_processor) \
|
||||
-DBUILD_SHARED_LIBS=0 .. || exit 1
|
||||
--with-pngincludedir="${BASEDIR}/prebuilt/android-$(get_target_build)/libpng/include" \
|
||||
--with-pnglibdir="${BASEDIR}/prebuilt/android-$(get_target_build)/libpng/lib" \
|
||||
--with-jpegincludedir="${BASEDIR}/prebuilt/android-$(get_target_build)/jpeg/include" \
|
||||
--with-jpeglibdir="${BASEDIR}/prebuilt/android-$(get_target_build)/jpeg/lib" \
|
||||
--with-gifincludedir="${BASEDIR}/prebuilt/android-$(get_target_build)/giflib/include" \
|
||||
--with-giflibdir="${BASEDIR}/prebuilt/android-$(get_target_build)/giflib/lib" \
|
||||
--with-tiffincludedir="${BASEDIR}/prebuilt/android-$(get_target_build)/tiff/include" \
|
||||
--with-tifflibdir="${BASEDIR}/prebuilt/android-$(get_target_build)/tiff/lib" \
|
||||
--host=${BUILD_HOST} || exit 1
|
||||
|
||||
make -j$(get_cpu_count) || exit 1
|
||||
|
||||
# CREATE PACKAGE CONFIG MANUALLY
|
||||
create_libwebp_package_config "1.1.0"
|
||||
# MANUALLY COPY PKG-CONFIG FILES
|
||||
cp ${BASEDIR}/src/${LIB_NAME}/src/*.pc ${INSTALL_PKG_CONFIG_DIR} || exit 1
|
||||
cp ${BASEDIR}/src/${LIB_NAME}/src/demux/*.pc ${INSTALL_PKG_CONFIG_DIR} || exit 1
|
||||
cp ${BASEDIR}/src/${LIB_NAME}/src/mux/*.pc ${INSTALL_PKG_CONFIG_DIR} || exit 1
|
||||
|
||||
make install || exit 1
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libxml2"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -44,7 +44,7 @@ make distclean 2>/dev/null 1>/dev/null
|
||||
# #error "LONG_BIT definition appears wrong for platform (bad gcc/glibc config?)."
|
||||
#
|
||||
|
||||
# ALWAYS RECONFIGURED
|
||||
# ALWAYS RECONFIGURE
|
||||
autoreconf_library ${LIB_NAME}
|
||||
|
||||
./configure \
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="nettle"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -47,7 +47,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_nettle} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="opencore-amr"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -37,7 +37,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_opencore_amr} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
+13
-17
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="openh264"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -35,39 +35,33 @@ LDFLAGS=$(get_ldflags ${LIB_NAME})
|
||||
|
||||
case ${ARCH} in
|
||||
arm-v7a-neon)
|
||||
ASM_ARCH=arm
|
||||
# Enabling NEON causes undefined symbol error for WelsCopy8x8_neon
|
||||
# CFLAGS+=" -DHAVE_NEON"
|
||||
;;
|
||||
arm64-v8a)
|
||||
ASM_ARCH=arm64
|
||||
CFLAGS+=" -DHAVE_NEON_AARCH64"
|
||||
;;
|
||||
x86*)
|
||||
ASM_ARCH=x86
|
||||
CFLAGS+=" -DHAVE_AVX2"
|
||||
;;
|
||||
esac
|
||||
|
||||
cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
# MAKE SURE THAT ASM IS ENABLED FOR ALL IOS ARCHITECTURES
|
||||
${SED_INLINE} 's/arm64 aarch64/arm64% aarch64/g' ${BASEDIR}/src/${LIB_NAME}/build/arch.mk
|
||||
${SED_INLINE} 's/%86 x86_64,/%86 x86_64 x86-64,/g' ${BASEDIR}/src/${LIB_NAME}/build/arch.mk
|
||||
${SED_INLINE} 's/filter-out arm64,/filter-out arm64%,/g' ${BASEDIR}/src/${LIB_NAME}/build/arch.mk
|
||||
${SED_INLINE} 's/CFLAGS += -DHAVE_NEON/#CFLAGS += -DHAVE_NEON/g' ${BASEDIR}/src/${LIB_NAME}/build/arch.mk
|
||||
${SED_INLINE} 's/ifeq (\$(ASM_ARCH), arm64)/ifneq (\$(filter arm64%, \$(ASM_ARCH)),)/g' ${BASEDIR}/src/${LIB_NAME}/codec/common/targets.mk
|
||||
${SED_INLINE} 's/ifeq (\$(ASM_ARCH), x86)/ifneq (\$(filter %86 x86-64, \$(ASM_ARCH)),)/g' ${BASEDIR}/src/${LIB_NAME}/codec/common/targets.mk
|
||||
${SED_INLINE} 's/ifeq (\$(ASM_ARCH), arm)/ifneq (\$(filter armv%, \$(ASM_ARCH)),)/g' ${BASEDIR}/src/${LIB_NAME}/codec/common/targets.mk
|
||||
|
||||
# DO NOT USE DEFAULT ANDROID ARCH FLAGS
|
||||
${SED_INLINE} 's/ CFLAGS +=/ #CFLAGS +=/g' ${BASEDIR}/src/${LIB_NAME}/build/platform-android.mk
|
||||
${SED_INLINE} 's/ LDFLAGS +=/ #LDFLAGS +=/g' ${BASEDIR}/src/${LIB_NAME}/build/platform-android.mk
|
||||
|
||||
make clean 2>/dev/null 1>/dev/null
|
||||
|
||||
# revert ios changes
|
||||
git checkout ${BASEDIR}/src/${LIB_NAME}/build 1>>${BASEDIR}/build.log 2>&1
|
||||
git checkout ${BASEDIR}/src/${LIB_NAME}/codec 1>>${BASEDIR}/build.log 2>&1
|
||||
|
||||
make -j$(get_cpu_count) \
|
||||
ARCH="$(get_toolchain_arch)" \
|
||||
CC="${ANDROID_NDK_ROOT}/toolchains/llvm/prebuilt/${TOOLCHAIN}/bin/${CC}" \
|
||||
CC="$CC" \
|
||||
CFLAGS="$CFLAGS" \
|
||||
CXX="${ANDROID_NDK_ROOT}/toolchains/llvm/prebuilt/${TOOLCHAIN}/bin/${CXX}" \
|
||||
CXX="$CXX" \
|
||||
CXXFLAGS="${CXXFLAGS}" \
|
||||
LDFLAGS="$LDFLAGS" \
|
||||
OS=android \
|
||||
@@ -75,8 +69,10 @@ PREFIX="${BASEDIR}/prebuilt/android-$(get_target_build)/${LIB_NAME}" \
|
||||
NDKLEVEL="${API}" \
|
||||
NDKROOT="${ANDROID_NDK_ROOT}" \
|
||||
NDK_TOOLCHAIN_VERSION=clang \
|
||||
AR="$AR" \
|
||||
ASM_ARCH=${ASM_ARCH} \
|
||||
TARGET="android-${API}" \
|
||||
install-static || exit 1
|
||||
|
||||
# MANUALLY COPY PKG-CONFIG FILES
|
||||
cp ${BASEDIR}/src/${LIB_NAME}/openh264-static.pc ${INSTALL_PKG_CONFIG_DIR}/openh264.pc || exit 1
|
||||
cp ${BASEDIR}/src/${LIB_NAME}/openh264-static.pc ${INSTALL_PKG_CONFIG_DIR}/openh264.pc || exit 1
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="opus"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -37,7 +37,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_opus} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
Executable
+67
@@ -0,0 +1,67 @@
|
||||
#!/bin/bash
|
||||
|
||||
if [[ -z ${ANDROID_NDK_ROOT} ]]; then
|
||||
echo -e "(*) ANDROID_NDK_ROOT not defined\n"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [[ -z ${ARCH} ]]; then
|
||||
echo -e "(*) ARCH not defined\n"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [[ -z ${API} ]]; then
|
||||
echo -e "(*) API not defined\n"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [[ -z ${BASEDIR} ]]; then
|
||||
echo -e "(*) BASEDIR not defined\n"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="rubberband"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
# PREPARING FLAGS
|
||||
BUILD_HOST=$(get_build_host)
|
||||
CFLAGS=$(get_cflags ${LIB_NAME})
|
||||
CXXFLAGS=$(get_cxxflags ${LIB_NAME})
|
||||
LDFLAGS=$(get_ldflags ${LIB_NAME})
|
||||
export PKG_CONFIG_LIBDIR=${INSTALL_PKG_CONFIG_DIR}
|
||||
|
||||
cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# DISABLE OPTIONAL FEATURES MANUALLY, SINCE ./configure DOES NOT PROVIDE OPTIONS FOR THEM
|
||||
rm -f ${BASEDIR}/src/${LIB_NAME}/configure.ac
|
||||
cp ${BASEDIR}/tools/make/rubberband/configure.ac ${BASEDIR}/src/${LIB_NAME}/configure.ac
|
||||
rm -f ${BASEDIR}/src/${LIB_NAME}/Makefile.in
|
||||
cp ${BASEDIR}/tools/make/rubberband/Makefile.android.in ${BASEDIR}/src/${LIB_NAME}/Makefile.in
|
||||
|
||||
# FIX PACKAGE CONFIG FILE DEPENDENCIES
|
||||
rm -f ${BASEDIR}/src/${LIB_NAME}/rubberband.pc.in
|
||||
cp ${BASEDIR}/tools/make/rubberband/rubberband.pc.in ${BASEDIR}/src/${LIB_NAME}/rubberband.pc.in
|
||||
${SED_INLINE} 's/%DEPENDENCIES%/sndfile, samplerate/g' ${BASEDIR}/src/${LIB_NAME}/rubberband.pc.in
|
||||
|
||||
# ALWAYS RECONFIGURE
|
||||
autoreconf_library ${LIB_NAME}
|
||||
|
||||
# MANUALLY CREATE LIB DIRECTORY
|
||||
mkdir -p ${BASEDIR}/src/${LIB_NAME}/lib || exit 1
|
||||
|
||||
./configure \
|
||||
--prefix=${BASEDIR}/prebuilt/android-$(get_target_build)/${LIB_NAME} \
|
||||
--host=${BUILD_HOST} || exit 1
|
||||
|
||||
make AR="$AR" -j$(get_cpu_count) || exit 1
|
||||
|
||||
make install || exit 1
|
||||
|
||||
# MANUALLY COPY PKG-CONFIG FILES
|
||||
cp ./*.pc ${INSTALL_PKG_CONFIG_DIR} || exit 1
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="sdl"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -38,7 +38,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_sdl} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="shine"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -37,7 +37,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_shine} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="snappy"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -67,6 +67,6 @@ cmake -Wno-dev \
|
||||
make -j$(get_cpu_count) || exit 1
|
||||
|
||||
# CREATE PACKAGE CONFIG MANUALLY
|
||||
create_snappy_package_config "1.1.7"
|
||||
create_snappy_package_config "1.1.8"
|
||||
|
||||
make install || exit 1
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="soxr"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="speex"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -43,7 +43,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_speex} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="tesseract"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -37,7 +37,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ! -f ${BASEDIR}/src/${LIB_NAME}/configure ]] || [[ ${RECONF_tesseract} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="tiff"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -37,7 +37,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_tiff} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="twolame"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -38,7 +38,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_twolame} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="wavpack"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -37,7 +37,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_wavpack} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -28,7 +28,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="x264"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="x265"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -42,19 +42,19 @@ if [[ ${DOWNLOAD_RESULT} -ne 0 ]]; then
|
||||
fi
|
||||
cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
ASM_OPTIONS=""
|
||||
ARCH_OPTIONS=""
|
||||
case ${ARCH} in
|
||||
arm-v7a | arm-v7a-neon)
|
||||
ASM_OPTIONS="-DENABLE_ASSEMBLY=0 -DCROSS_COMPILE_ARM=1"
|
||||
ARCH_OPTIONS="-DENABLE_ASSEMBLY=0 -DCROSS_COMPILE_ARM=1"
|
||||
;;
|
||||
arm64-v8a)
|
||||
ASM_OPTIONS="-DENABLE_ASSEMBLY=0 -DCROSS_COMPILE_ARM=1"
|
||||
ARCH_OPTIONS="-DENABLE_ASSEMBLY=0 -DCROSS_COMPILE_ARM=1"
|
||||
;;
|
||||
x86)
|
||||
ASM_OPTIONS="-DENABLE_ASSEMBLY=0 -DCROSS_COMPILE_ARM=0"
|
||||
ARCH_OPTIONS="-DENABLE_ASSEMBLY=0 -DCROSS_COMPILE_ARM=0"
|
||||
;;
|
||||
x86-64)
|
||||
ASM_OPTIONS="-DENABLE_ASSEMBLY=0 -DCROSS_COMPILE_ARM=0"
|
||||
ARCH_OPTIONS="-DENABLE_ASSEMBLY=0 -DCROSS_COMPILE_ARM=0"
|
||||
;;
|
||||
esac
|
||||
|
||||
@@ -87,13 +87,13 @@ cmake -Wno-dev \
|
||||
-DSTATIC_LINK_CRT=1 \
|
||||
-DENABLE_PIC=1 \
|
||||
-DENABLE_CLI=0 \
|
||||
${ASM_OPTIONS} \
|
||||
${ARCH_OPTIONS} \
|
||||
-DCMAKE_SYSTEM_PROCESSOR="${ARCH}" \
|
||||
-DENABLE_SHARED=0 ../source || exit 1
|
||||
|
||||
make -j$(get_cpu_count) || exit 1
|
||||
|
||||
# CREATE PACKAGE CONFIG MANUALLY
|
||||
create_x265_package_config "3.2.1"
|
||||
create_x265_package_config "3.3"
|
||||
|
||||
make install || exit 1
|
||||
|
||||
@@ -23,7 +23,7 @@ fi
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
. ${BASEDIR}/build/android-common.sh
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="xvidcore"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -37,7 +37,7 @@ cd ${BASEDIR}/src/${LIB_NAME}/build/generic || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_xvidcore} -eq 1 ]]; then
|
||||
./bootstrap.sh
|
||||
fi
|
||||
|
||||
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="chromaprint"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
|
||||
+76
-82
@@ -39,33 +39,35 @@ get_library_name() {
|
||||
18) echo "xvidcore" ;;
|
||||
19) echo "x265" ;;
|
||||
20) echo "libvidstab" ;;
|
||||
21) echo "libilbc" ;;
|
||||
22) echo "opus" ;;
|
||||
23) echo "snappy" ;;
|
||||
24) echo "soxr" ;;
|
||||
25) echo "libaom" ;;
|
||||
26) echo "chromaprint" ;;
|
||||
27) echo "twolame" ;;
|
||||
28) echo "sdl" ;;
|
||||
29) echo "tesseract" ;;
|
||||
30) echo "openh264" ;;
|
||||
31) echo "giflib" ;;
|
||||
32) echo "jpeg" ;;
|
||||
33) echo "libogg" ;;
|
||||
34) echo "libpng" ;;
|
||||
35) echo "nettle" ;;
|
||||
36) echo "tiff" ;;
|
||||
37) echo "expat" ;;
|
||||
38) echo "libsndfile" ;;
|
||||
39) echo "leptonica" ;;
|
||||
40) echo "ios-zlib" ;;
|
||||
41) echo "ios-audiotoolbox" ;;
|
||||
42) echo "ios-coreimage" ;;
|
||||
43) echo "ios-bzip2" ;;
|
||||
44) echo "ios-videotoolbox" ;;
|
||||
45) echo "ios-avfoundation" ;;
|
||||
46) echo "ios-libiconv" ;;
|
||||
47) echo "ios-libuuid" ;;
|
||||
21) echo "rubberband" ;;
|
||||
22) echo "libilbc" ;;
|
||||
23) echo "opus" ;;
|
||||
24) echo "snappy" ;;
|
||||
25) echo "soxr" ;;
|
||||
26) echo "libaom" ;;
|
||||
27) echo "chromaprint" ;;
|
||||
28) echo "twolame" ;;
|
||||
29) echo "sdl" ;;
|
||||
30) echo "tesseract" ;;
|
||||
31) echo "openh264" ;;
|
||||
32) echo "giflib" ;;
|
||||
33) echo "jpeg" ;;
|
||||
34) echo "libogg" ;;
|
||||
35) echo "libpng" ;;
|
||||
36) echo "nettle" ;;
|
||||
37) echo "tiff" ;;
|
||||
38) echo "expat" ;;
|
||||
39) echo "libsndfile" ;;
|
||||
40) echo "leptonica" ;;
|
||||
41) echo "libsamplerate" ;;
|
||||
42) echo "ios-zlib" ;;
|
||||
43) echo "ios-audiotoolbox" ;;
|
||||
44) echo "ios-coreimage" ;;
|
||||
45) echo "ios-bzip2" ;;
|
||||
46) echo "ios-videotoolbox" ;;
|
||||
47) echo "ios-avfoundation" ;;
|
||||
48) echo "ios-libiconv" ;;
|
||||
49) echo "ios-libuuid" ;;
|
||||
esac
|
||||
}
|
||||
|
||||
@@ -79,15 +81,16 @@ get_package_config_file_name() {
|
||||
11) echo "libxml-2.0" ;;
|
||||
12) echo "opencore-amrnb" ;;
|
||||
20) echo "vidstab" ;;
|
||||
25) echo "aom" ;;
|
||||
26) echo "libchromaprint" ;;
|
||||
28) echo "sdl2" ;;
|
||||
32) echo "libjpeg" ;;
|
||||
33) echo "ogg" ;;
|
||||
36) echo "libtiff-4" ;;
|
||||
38) echo "sndfile" ;;
|
||||
39) echo "lept" ;;
|
||||
47) echo "uuid" ;;
|
||||
26) echo "aom" ;;
|
||||
27) echo "libchromaprint" ;;
|
||||
29) echo "sdl2" ;;
|
||||
33) echo "libjpeg" ;;
|
||||
34) echo "ogg" ;;
|
||||
37) echo "libtiff-4" ;;
|
||||
39) echo "sndfile" ;;
|
||||
40) echo "lept" ;;
|
||||
41) echo "samplerate" ;;
|
||||
49) echo "uuid" ;;
|
||||
*) echo $(get_library_name $1)
|
||||
esac
|
||||
}
|
||||
@@ -103,16 +106,17 @@ get_static_archive_name() {
|
||||
9) echo "libvpx.a" ;;
|
||||
11) echo "libxml2.a" ;;
|
||||
20) echo "libvidstab.a" ;;
|
||||
21) echo "libilbc.a" ;;
|
||||
25) echo "libaom.a" ;;
|
||||
27) echo "libtwolame.a" ;;
|
||||
28) echo "libSDL2.a" ;;
|
||||
29) echo "libtesseract.a" ;;
|
||||
31) echo "libgif.a" ;;
|
||||
33) echo "libogg.a" ;;
|
||||
34) echo "libpng.a" ;;
|
||||
38) echo "libsndfile.a" ;;
|
||||
39) echo "liblept.a" ;;
|
||||
22) echo "libilbc.a" ;;
|
||||
26) echo "libaom.a" ;;
|
||||
28) echo "libtwolame.a" ;;
|
||||
29) echo "libSDL2.a" ;;
|
||||
30) echo "libtesseract.a" ;;
|
||||
32) echo "libgif.a" ;;
|
||||
34) echo "libogg.a" ;;
|
||||
35) echo "libpng.a" ;;
|
||||
39) echo "libsndfile.a" ;;
|
||||
40) echo "liblept.a" ;;
|
||||
41) echo "libsamplerate.a" ;;
|
||||
*) echo lib$(get_library_name $1).a
|
||||
esac
|
||||
}
|
||||
@@ -399,15 +403,18 @@ get_cxxflags() {
|
||||
gnutls)
|
||||
echo "-std=c++11 -fno-rtti ${BITCODE_FLAGS} ${COMMON_CFLAGS} ${OPTIMIZATION_FLAGS}"
|
||||
;;
|
||||
opencore-amr)
|
||||
echo "-fno-rtti ${BITCODE_FLAGS} ${COMMON_CFLAGS} ${OPTIMIZATION_FLAGS}"
|
||||
;;
|
||||
libwebp | xvidcore)
|
||||
echo "-std=c++11 -fno-exceptions -fno-rtti ${BITCODE_FLAGS} -fno-common -DPIC ${COMMON_CFLAGS} ${OPTIMIZATION_FLAGS}"
|
||||
;;
|
||||
libaom)
|
||||
echo "-std=c++11 -fno-exceptions ${BITCODE_FLAGS} ${COMMON_CFLAGS} ${OPTIMIZATION_FLAGS}"
|
||||
;;
|
||||
opencore-amr)
|
||||
echo "-fno-rtti ${BITCODE_FLAGS} ${COMMON_CFLAGS} ${OPTIMIZATION_FLAGS}"
|
||||
;;
|
||||
rubberband)
|
||||
echo "-fno-rtti ${BITCODE_FLAGS} ${COMMON_CFLAGS} ${OPTIMIZATION_FLAGS}"
|
||||
;;
|
||||
*)
|
||||
echo "-std=c++11 -fno-exceptions -fno-rtti ${BITCODE_FLAGS} ${COMMON_CFLAGS} ${OPTIMIZATION_FLAGS}"
|
||||
;;
|
||||
@@ -623,7 +630,7 @@ Cflags: -I\${includedir}
|
||||
EOF
|
||||
}
|
||||
|
||||
create_libiconv_package_config() {
|
||||
create_libiconv_system_package_config() {
|
||||
local LIB_ICONV_VERSION=$(grep '_LIBICONV_VERSION' ${SDK_PATH}/usr/include/iconv.h | grep -Eo '0x.*' | grep -Eo '.* ')
|
||||
|
||||
cat > "${INSTALL_PKG_CONFIG_DIR}/libiconv.pc" << EOF
|
||||
@@ -711,25 +718,6 @@ Cflags: -I\${includedir}
|
||||
EOF
|
||||
}
|
||||
|
||||
create_libwebp_package_config() {
|
||||
local LIB_WEBP_VERSION="$1"
|
||||
|
||||
cat > "${INSTALL_PKG_CONFIG_DIR}/libwebp.pc" << EOF
|
||||
prefix=${BASEDIR}/prebuilt/$(get_target_build_directory)/libwebp
|
||||
exec_prefix=\${prefix}
|
||||
libdir=\${prefix}/lib
|
||||
includedir=\${prefix}/include
|
||||
|
||||
Name: libwebp
|
||||
Description: webp codec library
|
||||
Version: ${LIB_WEBP_VERSION}
|
||||
|
||||
Requires:
|
||||
Libs: -L\${libdir} -lwebp -lwebpdecoder -lwebpdemux
|
||||
Cflags: -I\${includedir}
|
||||
EOF
|
||||
}
|
||||
|
||||
create_libxml2_package_config() {
|
||||
local LIBXML2_VERSION="$1"
|
||||
|
||||
@@ -811,7 +799,7 @@ Cflags: -I\${includedir}
|
||||
EOF
|
||||
}
|
||||
|
||||
create_uuid_system_package_config() {
|
||||
create_libuuid_system_package_config() {
|
||||
local UUID_VERSION="$1"
|
||||
|
||||
cat > "${INSTALL_PKG_CONFIG_DIR}/uuid.pc" << EOF
|
||||
@@ -848,7 +836,7 @@ Cflags: -I\${includedir}
|
||||
EOF
|
||||
}
|
||||
|
||||
create_zlib_package_config() {
|
||||
create_zlib_system_package_config() {
|
||||
ZLIB_VERSION=$(grep '#define ZLIB_VERSION' ${SDK_PATH}/usr/include/zlib.h | grep -Eo '\".*\"' | sed -e 's/\"//g')
|
||||
|
||||
cat > "${INSTALL_PKG_CONFIG_DIR}/zlib.pc" << EOF
|
||||
@@ -867,7 +855,7 @@ Cflags: -I\${includedir}
|
||||
EOF
|
||||
}
|
||||
|
||||
create_bzip2_package_config() {
|
||||
create_bzip2_system_package_config() {
|
||||
BZIP2_VERSION=$(grep -Eo 'version.*of' ${SDK_PATH}/usr/include/bzlib.h | sed -e 's/of//;s/version//g;s/\ //g')
|
||||
|
||||
cat > "${INSTALL_PKG_CONFIG_DIR}/bzip2.pc" << EOF
|
||||
@@ -932,15 +920,15 @@ download_gpl_library_source() {
|
||||
GPL_LIB_DEST_DIR="libvidstab"
|
||||
;;
|
||||
x264)
|
||||
GPL_LIB_URL="https://code.videolan.org/videolan/x264/-/archive/1771b556ee45207f8711744ccbd5d42a3949b14c/x264-1771b556ee45207f8711744ccbd5d42a3949b14c.tar.bz2"
|
||||
GPL_LIB_FILE="x264-1771b556ee45207f8711744ccbd5d42a3949b14c.tar.bz2"
|
||||
GPL_LIB_ORIG_DIR="x264-1771b556ee45207f8711744ccbd5d42a3949b14c"
|
||||
GPL_LIB_URL="https://code.videolan.org/videolan/x264/-/archive/296494a4011f58f32adc54304a2654627558c59a/x264-296494a4011f58f32adc54304a2654627558c59a.tar.bz2"
|
||||
GPL_LIB_FILE="x264-296494a4011f58f32adc54304a2654627558c59a.tar.bz2"
|
||||
GPL_LIB_ORIG_DIR="x264-296494a4011f58f32adc54304a2654627558c59a"
|
||||
GPL_LIB_DEST_DIR="x264"
|
||||
;;
|
||||
x265)
|
||||
GPL_LIB_URL="https://bitbucket.org/multicoreware/x265/downloads/x265_3.2.1.tar.gz"
|
||||
GPL_LIB_FILE="x265-3.2.tar.gz"
|
||||
GPL_LIB_ORIG_DIR="x265_3.2.1"
|
||||
GPL_LIB_URL="https://bitbucket.org/multicoreware/x265/downloads/x265_3.3.tar.gz"
|
||||
GPL_LIB_FILE="x265_3.3.tar.gz"
|
||||
GPL_LIB_ORIG_DIR="x265_3.3"
|
||||
GPL_LIB_DEST_DIR="x265"
|
||||
;;
|
||||
xvidcore)
|
||||
@@ -949,6 +937,12 @@ download_gpl_library_source() {
|
||||
GPL_LIB_ORIG_DIR="xvidcore"
|
||||
GPL_LIB_DEST_DIR="xvidcore"
|
||||
;;
|
||||
rubberband)
|
||||
GPL_LIB_URL="https://breakfastquay.com/files/releases/rubberband-1.8.2.tar.bz2"
|
||||
GPL_LIB_FILE="rubberband-1.8.2.tar.bz2"
|
||||
GPL_LIB_ORIG_DIR="rubberband-1.8.2"
|
||||
GPL_LIB_DEST_DIR="rubberband"
|
||||
;;
|
||||
esac
|
||||
|
||||
local GPL_LIB_SOURCE_PATH="${BASEDIR}/src/${GPL_LIB_DEST_DIR}"
|
||||
@@ -1082,19 +1076,19 @@ set_toolchain_clang_paths() {
|
||||
fi
|
||||
|
||||
if [ ! -f ${ZLIB_PACKAGE_CONFIG_PATH} ]; then
|
||||
create_zlib_package_config
|
||||
create_zlib_system_package_config
|
||||
fi
|
||||
|
||||
if [ ! -f ${LIB_ICONV_PACKAGE_CONFIG_PATH} ]; then
|
||||
create_libiconv_package_config
|
||||
create_libiconv_system_package_config
|
||||
fi
|
||||
|
||||
if [ ! -f ${BZIP2_PACKAGE_CONFIG_PATH} ]; then
|
||||
create_bzip2_package_config
|
||||
create_bzip2_system_package_config
|
||||
fi
|
||||
|
||||
if [ ! -f ${LIB_UUID_PACKAGE_CONFIG_PATH} ]; then
|
||||
create_uuid_system_package_config
|
||||
create_libuuid_system_package_config
|
||||
fi
|
||||
|
||||
prepare_inline_sed
|
||||
|
||||
+2
-2
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="expat"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -41,7 +41,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_expat} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
+29
-16
@@ -32,7 +32,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="ffmpeg"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -79,6 +79,7 @@ case ${ARCH} in
|
||||
BITCODE_FLAGS=""
|
||||
;;
|
||||
x86-64)
|
||||
ARCH_OPTIONS="--disable-asm"
|
||||
TARGET_CPU="x86_64"
|
||||
TARGET_ARCH="x86_64"
|
||||
NEON_FLAG=" --disable-neon"
|
||||
@@ -95,10 +96,10 @@ esac
|
||||
|
||||
if [[ ${APPLE_TVOS_BUILD} -eq 1 ]]; then
|
||||
CONFIGURE_POSTFIX="--disable-avfoundation"
|
||||
LIBRARY_COUNT=47
|
||||
LIBRARY_COUNT=49
|
||||
else
|
||||
CONFIGURE_POSTFIX=""
|
||||
LIBRARY_COUNT=48
|
||||
LIBRARY_COUNT=50
|
||||
fi
|
||||
|
||||
library=1
|
||||
@@ -213,6 +214,12 @@ do
|
||||
FFMPEG_LDFLAGS+=" $(pkg-config --libs --static opus)"
|
||||
CONFIGURE_POSTFIX+=" --enable-libopus"
|
||||
;;
|
||||
rubberband)
|
||||
FFMPEG_CFLAGS+=" $(pkg-config --cflags rubberband)"
|
||||
FFMPEG_LDFLAGS+=" $(pkg-config --libs --static rubberband)"
|
||||
FFMPEG_LDFLAGS+=" -framework Accelerate"
|
||||
CONFIGURE_POSTFIX+=" --enable-librubberband --enable-gpl"
|
||||
;;
|
||||
sdl)
|
||||
FFMPEG_CFLAGS+=" $(pkg-config --cflags sdl2)"
|
||||
FFMPEG_LDFLAGS+=" $(pkg-config --libs --static sdl2)"
|
||||
@@ -323,21 +330,21 @@ do
|
||||
else
|
||||
|
||||
# THE FOLLOWING LIBRARIES SHOULD BE EXPLICITLY DISABLED TO PREVENT AUTODETECT
|
||||
if [[ ${library} -eq 29 ]]; then
|
||||
if [[ ${library} -eq 30 ]]; then
|
||||
CONFIGURE_POSTFIX+=" --disable-sdl2"
|
||||
elif [[ ${library} -eq 41 ]]; then
|
||||
CONFIGURE_POSTFIX+=" --disable-zlib"
|
||||
elif [[ ${library} -eq 42 ]]; then
|
||||
CONFIGURE_POSTFIX+=" --disable-audiotoolbox"
|
||||
elif [[ ${library} -eq 43 ]]; then
|
||||
CONFIGURE_POSTFIX+=" --disable-coreimage"
|
||||
CONFIGURE_POSTFIX+=" --disable-zlib"
|
||||
elif [[ ${library} -eq 44 ]]; then
|
||||
CONFIGURE_POSTFIX+=" --disable-bzlib"
|
||||
CONFIGURE_POSTFIX+=" --disable-audiotoolbox"
|
||||
elif [[ ${library} -eq 45 ]]; then
|
||||
CONFIGURE_POSTFIX+=" --disable-videotoolbox"
|
||||
CONFIGURE_POSTFIX+=" --disable-coreimage"
|
||||
elif [[ ${library} -eq 46 ]]; then
|
||||
CONFIGURE_POSTFIX+=" --disable-avfoundation"
|
||||
CONFIGURE_POSTFIX+=" --disable-bzlib"
|
||||
elif [[ ${library} -eq 47 ]]; then
|
||||
CONFIGURE_POSTFIX+=" --disable-videotoolbox"
|
||||
elif [[ ${library} -eq 48 ]]; then
|
||||
CONFIGURE_POSTFIX+=" --disable-avfoundation"
|
||||
elif [[ ${library} -eq 49 ]]; then
|
||||
CONFIGURE_POSTFIX+=" --disable-iconv"
|
||||
fi
|
||||
fi
|
||||
@@ -398,12 +405,9 @@ if [[ -z ${NO_WORKSPACE_CLEANUP_ffmpeg} ]]; then
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
fi
|
||||
|
||||
# Workaround to prevent adding of -mdynamic-no-pic flag
|
||||
${SED_INLINE} 's/check_cflags -mdynamic-no-pic && add_asflags -mdynamic-no-pic;/check_cflags -mdynamic-no-pic;/g' ./configure 1>>${BASEDIR}/build.log 2>&1
|
||||
|
||||
# Workaround for issue #328
|
||||
rm -f ${BASEDIR}/src/${LIB_NAME}/libswscale/aarch64/hscale.S 1>>${BASEDIR}/build.log 2>&1
|
||||
cp ${BASEDIR}/tools/make/ffmpeg/libswscale/aarch64/hscale.S ${BASEDIR}/src/${LIB_NAME}/libswscale/aarch64/hscale.S 1>>${BASEDIR}/build.log 2>&1
|
||||
|
||||
# Workaround for videotoolbox on mac catalyst
|
||||
if [ ${ARCH} == "x86-64-mac-catalyst" ]; then
|
||||
${SED_INLINE} 's/ CFDictionarySetValue(buffer_attributes\, kCVPixelBufferOpenGLESCompatibilityKey/ \/\/ CFDictionarySetValue(buffer_attributes\, kCVPixelBufferOpenGLESCompatibilityKey/g' ${BASEDIR}/src/${LIB_NAME}/libavcodec/videotoolbox.c
|
||||
@@ -411,6 +415,9 @@ else
|
||||
${SED_INLINE} 's/ \/\/ CFDictionarySetValue(buffer_attributes\, kCVPixelBufferOpenGLESCompatibilityKey/ CFDictionarySetValue(buffer_attributes\, kCVPixelBufferOpenGLESCompatibilityKey/g' ${BASEDIR}/src/${LIB_NAME}/libavcodec/videotoolbox.c
|
||||
fi
|
||||
|
||||
# Workaround for not supported iOS/tvOS features
|
||||
git checkout 2e595085ef653f365af49e6a32f012cc6d9ee03c -- ${BASEDIR}/src/${LIB_NAME}/libavdevice/avfoundation.m 1>>${BASEDIR}/build.log 2>&1
|
||||
|
||||
./configure \
|
||||
--sysroot=${SDK_PATH} \
|
||||
--prefix=${BASEDIR}/prebuilt/$(get_target_build_directory)/${LIB_NAME} \
|
||||
@@ -467,6 +474,12 @@ fi
|
||||
--disable-vdpau \
|
||||
${CONFIGURE_POSTFIX} 1>>${BASEDIR}/build.log 2>&1
|
||||
|
||||
# Workaround for issue #328
|
||||
echo "" >>ffbuild/config.mak
|
||||
echo "all:" >>ffbuild/config.mak
|
||||
echo "libswscale/aarch64/hscale.o: ${BASEDIR}/tools/make/ffmpeg/libswscale/aarch64/hscale.S" >>ffbuild/config.mak
|
||||
echo ' $(COMPILE_S)' >>ffbuild/config.mak
|
||||
|
||||
if [ $? -ne 0 ]; then
|
||||
echo "failed"
|
||||
exit 1
|
||||
|
||||
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="fontconfig"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -42,7 +42,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_fontconfig} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="freetype"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="fribidi"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -42,7 +42,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_fribidi} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
+2
-2
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="giflib"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -42,7 +42,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_giflib} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
+3
-3
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="gmp"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -39,7 +39,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_gmp} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
@@ -75,6 +75,6 @@ esac
|
||||
make -j$(get_cpu_count) || exit 1
|
||||
|
||||
# CREATE PACKAGE CONFIG MANUALLY
|
||||
create_gmp_package_config "6.1.2"
|
||||
create_gmp_package_config "6.2.0"
|
||||
|
||||
make install || exit 1
|
||||
|
||||
+8
-8
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="gnutls"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -48,18 +48,18 @@ export HOGWEED_LIBS="-L${BASEDIR}/prebuilt/$(get_target_build_directory)/nettle/
|
||||
export GMP_CFLAGS="-I${BASEDIR}/prebuilt/$(get_target_build_directory)/gmp/include"
|
||||
export GMP_LIBS="-L${BASEDIR}/prebuilt/$(get_target_build_directory)/gmp/lib -lgmp"
|
||||
|
||||
HARDWARE_ACCELERATION=""
|
||||
ARCH_OPTIONS=""
|
||||
case ${ARCH} in
|
||||
arm64 | arm64e)
|
||||
HARDWARE_ACCELERATION="--enable-hardware-acceleration"
|
||||
ARCH_OPTIONS="--enable-hardware-acceleration"
|
||||
;;
|
||||
i386)
|
||||
# DISABLING thread_local WHICH IS NOT SUPPORTED ON i386
|
||||
export CFLAGS+=" -D__thread="
|
||||
HARDWARE_ACCELERATION="--enable-hardware-acceleration"
|
||||
ARCH_OPTIONS="--enable-hardware-acceleration"
|
||||
;;
|
||||
*)
|
||||
HARDWARE_ACCELERATION="--enable-hardware-acceleration"
|
||||
ARCH_OPTIONS="--enable-hardware-acceleration"
|
||||
;;
|
||||
esac
|
||||
|
||||
@@ -71,7 +71,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_gnutls} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
@@ -84,7 +84,7 @@ fi
|
||||
--with-included-unistring \
|
||||
--without-idn \
|
||||
--without-p11-kit \
|
||||
${HARDWARE_ACCELERATION} \
|
||||
${ARCH_OPTIONS} \
|
||||
--enable-static \
|
||||
--disable-openssl-compatibility \
|
||||
--disable-shared \
|
||||
@@ -101,6 +101,6 @@ fi
|
||||
make -j$(get_cpu_count) || exit 1
|
||||
|
||||
# CREATE PACKAGE CONFIG MANUALLY
|
||||
create_gnutls_package_config "3.6.11.1"
|
||||
create_gnutls_package_config "3.6.13"
|
||||
|
||||
make install || exit 1
|
||||
|
||||
+1
-1
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="jpeg"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
export CCAS=${AS}
|
||||
|
||||
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="kvazaar"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -37,7 +37,7 @@ case ${ARCH} in
|
||||
i386)
|
||||
BUILD_HOST="x86-apple-darwin"
|
||||
;;
|
||||
x86-64-mac-catalyst)
|
||||
x86-64 | x86-64-mac-catalyst)
|
||||
ARCH_OPTIONS="--disable-asm"
|
||||
BUILD_HOST=$(get_build_host)
|
||||
;;
|
||||
@@ -56,7 +56,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_kvazaar} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
+2
-2
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="lame"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -42,7 +42,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_lame} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="leptonica"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -58,7 +58,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_leptonica} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
+1
-1
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libaom"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
|
||||
+3
-3
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libass"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -40,7 +40,7 @@ export PKG_CONFIG_LIBDIR=${INSTALL_PKG_CONFIG_DIR}
|
||||
|
||||
ARCH_OPTIONS=""
|
||||
case ${ARCH} in
|
||||
x86-64-mac-catalyst)
|
||||
x86-64 | x86-64-mac-catalyst)
|
||||
ARCH_OPTIONS="--disable-asm"
|
||||
;;
|
||||
*)
|
||||
@@ -52,7 +52,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_libass} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libilbc"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -41,7 +41,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_libilbc} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
+2
-2
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libogg"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -41,7 +41,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_libogg} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
+6
-6
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libpng"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -38,13 +38,13 @@ export CPPFLAGS=$(get_cflags ${LIB_NAME})
|
||||
export CXXFLAGS=$(get_cxxflags ${LIB_NAME})
|
||||
export LDFLAGS=$(get_ldflags ${LIB_NAME})
|
||||
|
||||
CPU_SPECIFIC_OPTIONS="--enable-hardware-optimizations=yes"
|
||||
ARCH_OPTIONS="--enable-hardware-optimizations=yes"
|
||||
case ${ARCH} in
|
||||
x86 | x86-64 | x86-64-mac-catalyst)
|
||||
CPU_SPECIFIC_OPTIONS+=" --enable-intel-sse=yes"
|
||||
ARCH_OPTIONS+=" --enable-intel-sse=yes"
|
||||
;;
|
||||
armv7 | armv7s | arm64 | arm64e)
|
||||
CPU_SPECIFIC_OPTIONS+=" --enable-arm-neon=yes"
|
||||
ARCH_OPTIONS+=" --enable-arm-neon=yes"
|
||||
;;
|
||||
esac
|
||||
|
||||
@@ -52,7 +52,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_libpng} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
@@ -66,7 +66,7 @@ fi
|
||||
--disable-fast-install \
|
||||
--disable-unversioned-libpng-pc \
|
||||
--disable-unversioned-libpng-config \
|
||||
${CPU_SPECIFIC_OPTIONS} \
|
||||
${ARCH_OPTIONS} \
|
||||
--host=${BUILD_HOST} || exit 1
|
||||
|
||||
make -j$(get_cpu_count) || exit 1
|
||||
|
||||
Executable
+68
@@ -0,0 +1,68 @@
|
||||
#!/bin/bash
|
||||
|
||||
if [[ -z ${ARCH} ]]; then
|
||||
echo -e "(*) ARCH not defined\n"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [[ -z ${TARGET_SDK} ]]; then
|
||||
echo -e "(*) TARGET_SDK not defined\n"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [[ -z ${SDK_PATH} ]]; then
|
||||
echo -e "(*) SDK_PATH not defined\n"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [[ -z ${BASEDIR} ]]; then
|
||||
echo -e "(*) BASEDIR not defined\n"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
if [[ ${APPLE_TVOS_BUILD} -eq 1 ]]; then
|
||||
. ${BASEDIR}/build/tvos-common.sh
|
||||
else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libsamplerate"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
# PREPARING FLAGS
|
||||
BUILD_HOST=$(get_build_host)
|
||||
export CFLAGS=$(get_cflags ${LIB_NAME})
|
||||
export CXXFLAGS=$(get_cxxflags ${LIB_NAME})
|
||||
export LDFLAGS=$(get_ldflags ${LIB_NAME})
|
||||
export PKG_CONFIG_LIBDIR=${INSTALL_PKG_CONFIG_DIR}
|
||||
|
||||
cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_libsamplerate} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
./configure \
|
||||
--prefix=${BASEDIR}/prebuilt/$(get_target_build_directory)/${LIB_NAME} \
|
||||
--with-pic \
|
||||
--with-sysroot=${SDK_PATH} \
|
||||
--enable-static \
|
||||
--disable-fftw \
|
||||
--disable-shared \
|
||||
--disable-fast-install \
|
||||
--host=${BUILD_HOST} || exit 1
|
||||
|
||||
# DISABLE building of examples manually
|
||||
${SED_INLINE} 's/examples tests//g' ${BASEDIR}/src/${LIB_NAME}/Makefile
|
||||
|
||||
make -j$(get_cpu_count) || exit 1
|
||||
|
||||
# MANUALLY COPY PKG-CONFIG FILES
|
||||
cp ./*.pc ${INSTALL_PKG_CONFIG_DIR} || exit 1
|
||||
|
||||
make install || exit 1
|
||||
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libsndfile"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libtheora"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -42,7 +42,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_libtheora} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libuuid"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -41,7 +41,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_libuuid} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libvidstab"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libvorbis"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -42,7 +42,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_libvorbis} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
+2
-2
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libvpx"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -68,7 +68,7 @@ case ${ARCH} in
|
||||
;;
|
||||
x86-64)
|
||||
TARGET="x86_64-iphonesimulator-gcc"
|
||||
ASM_FLAGS="--enable-runtime-cpu-detect --disable-avx512"
|
||||
ASM_FLAGS="--enable-runtime-cpu-detect --disable-avx512 --disable-sse --disable-sse2 --disable-mmx"
|
||||
;;
|
||||
x86-64-mac-catalyst)
|
||||
TARGET="x86_64-macosx-gcc"
|
||||
|
||||
+43
-58
@@ -27,76 +27,61 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libwebp"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
# PREPARING FLAGS
|
||||
BUILD_HOST=$(get_build_host)
|
||||
CFLAGS=$(get_cflags ${LIB_NAME})
|
||||
CXXFLAGS=$(get_cxxflags ${LIB_NAME})
|
||||
LDFLAGS=$(get_ldflags ${LIB_NAME})
|
||||
export CFLAGS=$(get_cflags ${LIB_NAME})
|
||||
export CXXFLAGS=$(get_cxxflags ${LIB_NAME})
|
||||
export LDFLAGS=$(get_ldflags ${LIB_NAME})
|
||||
export PKG_CONFIG_LIBDIR="${INSTALL_PKG_CONFIG_DIR}"
|
||||
|
||||
ARCH_OPTIONS=""
|
||||
case ${ARCH} in
|
||||
armv7 | armv7s | arm64 | arm64e)
|
||||
ARCH_OPTIONS="--enable-neon --enable-neon-rtcd"
|
||||
;;
|
||||
x86-64-mac-catalyst)
|
||||
ARCH_OPTIONS="--disable-sse2 --disable-sse4.1"
|
||||
;;
|
||||
*)
|
||||
ARCH_OPTIONS="--enable-sse2 --enable-sse4.1"
|
||||
;;
|
||||
esac
|
||||
|
||||
cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
if [ -d "build" ]; then
|
||||
rm -rf build
|
||||
fi
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
mkdir build;
|
||||
cd build
|
||||
# ALWAYS RECONFIGURE
|
||||
autoreconf_library ${LIB_NAME}
|
||||
|
||||
# OVERRIDING INCLUDE PATH ORDER
|
||||
CFLAGS="-I${BASEDIR}/prebuilt/$(get_target_build_directory)/giflib/include \
|
||||
-I${BASEDIR}/prebuilt/$(get_target_build_directory)/jpeg/include \
|
||||
-I${BASEDIR}/prebuilt/$(get_target_build_directory)/libpng/include \
|
||||
-I${BASEDIR}/prebuilt/$(get_target_build_directory)/tiff/include $CFLAGS"
|
||||
|
||||
cmake -Wno-dev \
|
||||
-DCMAKE_VERBOSE_MAKEFILE=0 \
|
||||
-DCMAKE_C_FLAGS="${CFLAGS}" \
|
||||
-DCMAKE_CXX_FLAGS="${CXXFLAGS}" \
|
||||
-DCMAKE_EXE_LINKER_FLAGS="${LDFLAGS}" \
|
||||
-DCMAKE_SYSROOT="${SDK_PATH}" \
|
||||
-DCMAKE_FIND_ROOT_PATH="${SDK_PATH}" \
|
||||
-DCMAKE_BUILD_TYPE=Release \
|
||||
-DCMAKE_INSTALL_PREFIX="${BASEDIR}/prebuilt/$(get_target_build_directory)/${LIB_NAME}" \
|
||||
-DCMAKE_SYSTEM_NAME=Darwin \
|
||||
-DCMAKE_OSX_SYSROOT="" \
|
||||
-DCMAKE_C_COMPILER="$CC" \
|
||||
-DCMAKE_LINKER="$LD" \
|
||||
-DCMAKE_AR="$(xcrun --sdk $(get_sdk_name) -f ar)" \
|
||||
-DCMAKE_AS="$AS" \
|
||||
-DGIF_INCLUDE_DIR=${BASEDIR}/prebuilt/$(get_target_build_directory)/giflib/include \
|
||||
-DGIF_LIBRARY= \
|
||||
-DJPEG_INCLUDE_DIR=${BASEDIR}/prebuilt/$(get_target_build_directory)/jpeg/include \
|
||||
-DJPEG_LIBRARY=${BASEDIR}/prebuilt/$(get_target_build_directory)/jpeg/lib \
|
||||
-DPNG_PNG_INCLUDE_DIR=${BASEDIR}/prebuilt/$(get_target_build_directory)/libpng/include \
|
||||
-DPNG_LIBRARY=${BASEDIR}/prebuilt/$(get_target_build_directory)/libpng/lib \
|
||||
-DTIFF_INCLUDE_DIR=${BASEDIR}/prebuilt/$(get_target_build_directory)/tiff/include \
|
||||
-DTIFF_LIBRARY=${BASEDIR}/prebuilt/$(get_target_build_directory)/tiff/lib \
|
||||
-DZLIB_INCLUDE_DIR=${SDK_PATH}/usr/include \
|
||||
-DZLIB_LIBRARY=${SDK_PATH}/usr/lib \
|
||||
-DGLUT_INCLUDE_DIR= \
|
||||
-DGLUT_cocoa_LIBRARY= \
|
||||
-DGLUT_glut_LIBRARY= \
|
||||
-DOPENGL_INCLUDE_DIR= \
|
||||
-DSDLMAIN_LIBRARY= \
|
||||
-DSDL_INCLUDE_DIR= \
|
||||
-DWEBP_BUILD_CWEBP=0 \
|
||||
-DWEBP_BUILD_DWEBP=0 \
|
||||
-DWEBP_BUILD_EXTRAS=0 \
|
||||
-DWEBP_BUILD_GIF2WEBP=0 \
|
||||
-DWEBP_BUILD_IMG2WEBP=0 \
|
||||
-DWEBP_BUILD_WEBPMUX=0 \
|
||||
-DWEBP_BUILD_WEBPINFO=0 \
|
||||
-DWEBP_BUILD_ANIM_UTILS=0 \
|
||||
-DCMAKE_SYSTEM_PROCESSOR=$(get_target_arch) \
|
||||
-DBUILD_SHARED_LIBS=0 .. || exit 1
|
||||
./configure \
|
||||
--prefix="${BASEDIR}/prebuilt/$(get_target_build_directory)/${LIB_NAME}" \
|
||||
--with-pic \
|
||||
--with-sysroot=${SDK_PATH} \
|
||||
--enable-static \
|
||||
--disable-shared \
|
||||
--disable-dependency-tracking \
|
||||
--enable-libwebpmux \
|
||||
${ARCH_OPTIONS} \
|
||||
--with-pngincludedir="${BASEDIR}/prebuilt/$(get_target_build_directory)/libpng/include" \
|
||||
--with-pnglibdir="${BASEDIR}/prebuilt/$(get_target_build_directory)/libpng/lib" \
|
||||
--with-jpegincludedir="${BASEDIR}/prebuilt/$(get_target_build_directory)/jpeg/include" \
|
||||
--with-jpeglibdir="${BASEDIR}/prebuilt/$(get_target_build_directory)/jpeg/lib" \
|
||||
--with-gifincludedir="${BASEDIR}/prebuilt/$(get_target_build_directory)/giflib/include" \
|
||||
--with-giflibdir="${BASEDIR}/prebuilt/$(get_target_build_directory)/giflib/lib" \
|
||||
--with-tiffincludedir="${BASEDIR}/prebuilt/$(get_target_build_directory)/tiff/include" \
|
||||
--with-tifflibdir="${BASEDIR}/prebuilt/$(get_target_build_directory)/tiff/lib" \
|
||||
--host=${BUILD_HOST} || exit 1
|
||||
|
||||
make -j$(get_cpu_count) || exit 1
|
||||
|
||||
# CREATE PACKAGE CONFIG MANUALLY
|
||||
create_libwebp_package_config "1.1.0"
|
||||
# MANUALLY COPY PKG-CONFIG FILES
|
||||
cp ${BASEDIR}/src/${LIB_NAME}/src/*.pc ${INSTALL_PKG_CONFIG_DIR} || exit 1
|
||||
cp ${BASEDIR}/src/${LIB_NAME}/src/demux/*.pc ${INSTALL_PKG_CONFIG_DIR} || exit 1
|
||||
cp ${BASEDIR}/src/${LIB_NAME}/src/mux/*.pc ${INSTALL_PKG_CONFIG_DIR} || exit 1
|
||||
|
||||
make install || exit 1
|
||||
|
||||
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="libxml2"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -42,7 +42,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# ALWAYS RECONFIGURED
|
||||
# ALWAYS RECONFIGURE
|
||||
autoreconf_library ${LIB_NAME}
|
||||
|
||||
./configure \
|
||||
|
||||
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="mobile-ffmpeg"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -55,7 +55,7 @@ make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
rm -f ${BASEDIR}/ios/src/libmobileffmpeg* 1>>${BASEDIR}/build.log 2>&1
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_mobile_ffmpeg} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
+2
-2
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="nettle"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -51,7 +51,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_nettle} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="opencore-amr"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -51,7 +51,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_opencore_amr} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="openh264"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -56,13 +56,12 @@ esac
|
||||
|
||||
cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
# MAKE SURE THAT ASM IS ENABLED FOR ALL IOS ARCHITECTURES
|
||||
# MAKE SURE THAT ASM IS ENABLED FOR ALL IOS ARCHITECTURES - EXCEPT x86-64
|
||||
${SED_INLINE} 's/arm64 aarch64/arm64% aarch64/g' ${BASEDIR}/src/${LIB_NAME}/build/arch.mk
|
||||
${SED_INLINE} 's/%86 x86_64,/%86 x86_64 x86-64,/g' ${BASEDIR}/src/${LIB_NAME}/build/arch.mk
|
||||
${SED_INLINE} 's/filter-out arm64,/filter-out arm64%,/g' ${BASEDIR}/src/${LIB_NAME}/build/arch.mk
|
||||
${SED_INLINE} 's/CFLAGS += -DHAVE_NEON/#CFLAGS += -DHAVE_NEON/g' ${BASEDIR}/src/${LIB_NAME}/build/arch.mk
|
||||
${SED_INLINE} 's/ifeq (\$(ASM_ARCH), arm64)/ifneq (\$(filter arm64%, \$(ASM_ARCH)),)/g' ${BASEDIR}/src/${LIB_NAME}/codec/common/targets.mk
|
||||
${SED_INLINE} 's/ifeq (\$(ASM_ARCH), x86)/ifneq (\$(filter %86 x86-64, \$(ASM_ARCH)),)/g' ${BASEDIR}/src/${LIB_NAME}/codec/common/targets.mk
|
||||
${SED_INLINE} 's/ifeq (\$(ASM_ARCH), arm)/ifneq (\$(filter armv%, \$(ASM_ARCH)),)/g' ${BASEDIR}/src/${LIB_NAME}/codec/common/targets.mk
|
||||
|
||||
make clean 2>/dev/null 1>/dev/null
|
||||
|
||||
+2
-2
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="opus"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -41,7 +41,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_opus} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
Executable
+71
@@ -0,0 +1,71 @@
|
||||
#!/bin/bash
|
||||
|
||||
if [[ -z ${ARCH} ]]; then
|
||||
echo -e "(*) ARCH not defined\n"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [[ -z ${TARGET_SDK} ]]; then
|
||||
echo -e "(*) TARGET_SDK not defined\n"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [[ -z ${SDK_PATH} ]]; then
|
||||
echo -e "(*) SDK_PATH not defined\n"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [[ -z ${BASEDIR} ]]; then
|
||||
echo -e "(*) BASEDIR not defined\n"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# ENABLE COMMON FUNCTIONS
|
||||
if [[ ${APPLE_TVOS_BUILD} -eq 1 ]]; then
|
||||
. ${BASEDIR}/build/tvos-common.sh
|
||||
else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="rubberband"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
# PREPARING FLAGS
|
||||
BUILD_HOST=$(get_build_host)
|
||||
export CFLAGS=$(get_cflags ${LIB_NAME})
|
||||
export CXXFLAGS=$(get_cxxflags ${LIB_NAME})
|
||||
export LDFLAGS=$(get_ldflags ${LIB_NAME})
|
||||
export PKG_CONFIG_LIBDIR=${INSTALL_PKG_CONFIG_DIR}
|
||||
|
||||
cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# DISABLE OPTIONAL FEATURES MANUALLY, SINCE ./configure DOES NOT PROVIDE OPTIONS FOR THEM
|
||||
rm -f ${BASEDIR}/src/${LIB_NAME}/configure.ac
|
||||
cp ${BASEDIR}/tools/make/rubberband/configure.ac ${BASEDIR}/src/${LIB_NAME}/configure.ac
|
||||
rm -f ${BASEDIR}/src/${LIB_NAME}/Makefile.in
|
||||
cp ${BASEDIR}/tools/make/rubberband/Makefile.ios.in ${BASEDIR}/src/${LIB_NAME}/Makefile.in
|
||||
|
||||
# FIX PACKAGE CONFIG FILE DEPENDENCIES
|
||||
rm -f ${BASEDIR}/src/${LIB_NAME}/rubberband.pc.in
|
||||
cp ${BASEDIR}/tools/make/rubberband/rubberband.pc.in ${BASEDIR}/src/${LIB_NAME}/rubberband.pc.in
|
||||
${SED_INLINE} 's/%DEPENDENCIES%/sndfile, samplerate/g' ${BASEDIR}/src/${LIB_NAME}/rubberband.pc.in
|
||||
|
||||
# ALWAYS RECONFIGURE
|
||||
autoreconf_library ${LIB_NAME}
|
||||
|
||||
# MANUALLY CREATE LIB DIRECTORY
|
||||
mkdir -p ${BASEDIR}/src/${LIB_NAME}/lib || exit 1
|
||||
|
||||
./configure \
|
||||
--prefix=${BASEDIR}/prebuilt/$(get_target_build_directory)/${LIB_NAME} \
|
||||
--host=${BUILD_HOST} || exit 1
|
||||
|
||||
make AR="$AR" -j$(get_cpu_count) || exit 1
|
||||
|
||||
make install || exit 1
|
||||
|
||||
# MANUALLY COPY PKG-CONFIG FILES
|
||||
cp ./*.pc ${INSTALL_PKG_CONFIG_DIR} || exit 1
|
||||
+2
-2
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="sdl"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -52,7 +52,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_sdl} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
+2
-2
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="shine"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -41,7 +41,7 @@ cd ${BASEDIR}/src/${LIB_NAME} || exit 1
|
||||
|
||||
make distclean 2>/dev/null 1>/dev/null
|
||||
|
||||
# RECONFIGURING IF REQUESTED
|
||||
# RECONFIGURE IF REQUESTED
|
||||
if [[ ${RECONF_shine} -eq 1 ]]; then
|
||||
autoreconf_library ${LIB_NAME}
|
||||
fi
|
||||
|
||||
+2
-2
@@ -27,7 +27,7 @@ else
|
||||
. ${BASEDIR}/build/ios-common.sh
|
||||
fi
|
||||
|
||||
# PREPARING PATHS & DEFINING ${INSTALL_PKG_CONFIG_DIR}
|
||||
# PREPARE PATHS & DEFINE ${INSTALL_PKG_CONFIG_DIR}
|
||||
LIB_NAME="snappy"
|
||||
set_toolchain_clang_paths ${LIB_NAME}
|
||||
|
||||
@@ -71,6 +71,6 @@ cmake -Wno-dev \
|
||||
make -j$(get_cpu_count) || exit 1
|
||||
|
||||
# CREATE PACKAGE CONFIG MANUALLY
|
||||
create_snappy_package_config "1.1.7"
|
||||
create_snappy_package_config "1.1.8"
|
||||
|
||||
make install || exit 1
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user