mirror of
https://framagit.org/tom79/fedilab-tube
synced 2025-06-05 21:09:11 +02:00
lib
This commit is contained in:
@@ -45,23 +45,19 @@ ext {
|
||||
libtorrentVersion = '1.2.11.0'
|
||||
}
|
||||
|
||||
// Custom task which downloads the appropriate version of JAR files for jlibtorrent
|
||||
task downloadDependencies(type: Download) {
|
||||
def baseUrl = "https://github.com/frostwire/frostwire-jlibtorrent" +
|
||||
"/releases/download/release%2F$libtorrentVersion"
|
||||
|
||||
def platforms = ['arm', 'arm64', 'x86', 'x86_64']
|
||||
def urls = platforms.collect { "$baseUrl/jlibtorrent-android-$it-${libtorrentVersion}.jar" }
|
||||
urls.add("$baseUrl/jlibtorrent-${libtorrentVersion}.jar")
|
||||
|
||||
src urls
|
||||
dest 'libs'
|
||||
overwrite false
|
||||
task myPrebuildTask(type: Exec) {
|
||||
executable "sh"
|
||||
if (System.getProperty('os.name').toLowerCase(Locale.ROOT).contains('windows')) {
|
||||
commandLine 'cmd', '/c', 'compile.sh'
|
||||
} else {
|
||||
commandLine './compile.sh'
|
||||
}
|
||||
}
|
||||
|
||||
// Add our custom task as a dependency to the build
|
||||
// You may need to run gradle sync for IDE warnings to disappear
|
||||
preBuild.dependsOn(downloadDependencies)
|
||||
preBuild.dependsOn(myPrebuildTask)
|
||||
|
||||
// Add deletion of libs folder to clean task
|
||||
clean {
|
||||
|
21
torrentStream/compile.sh
Executable file
21
torrentStream/compile.sh
Executable file
@@ -0,0 +1,21 @@
|
||||
#!/bin/bash
|
||||
# 1 - Install linux toolchain
|
||||
# sudo add-apt-repository ppa:ubuntu-toolchain-r/test -y
|
||||
# sudo apt-get update -qq
|
||||
# sudo apt-get install -qq g++-7 g++-7-multilib swig
|
||||
# 2 - Install swig
|
||||
# sudo apt install swig
|
||||
# 3 - Depending on your version (a or b)
|
||||
# 3a - toolchain (x86)
|
||||
# sudo apt-get install -qq g++-mingw-w64-i686 swig
|
||||
# 3b - toolchain (64)
|
||||
# sudo apt-get install -qq g++-mingw-w64-x86-64 swig
|
||||
|
||||
cd ../frostwire-jlibtorrent/swig/ || exit
|
||||
source build-android-arm.sh
|
||||
#cd ../frostwire-jlibtorrent/swig/ || exit
|
||||
#source build-android-arm64.sh
|
||||
#cd ../frostwire-jlibtorrent/swig/ || exit
|
||||
#source build-android-x86.sh
|
||||
#cd ../frostwire-jlibtorrent/swig/ || exit
|
||||
#source build-android-x86_64.sh
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Reference in New Issue
Block a user