mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-07-23 11:15:13 +03:00
224 lines
9.6 KiB
Diff
224 lines
9.6 KiB
Diff
--- old/build.gradle
|
|
+++ new/build.gradle
|
|
@@ -3175,6 +3175,12 @@
|
|
processResources.dependsOn copyDTtoPackager
|
|
}
|
|
|
|
+def pkgConfigEnv = [
|
|
+ PKG_CONFIG_PATH: "$PKG_CONFIG_PATH",
|
|
+ PKG_CONFIG_SYSROOT_DIR: "$PKG_CONFIG_SYSROOT_DIR"
|
|
+]
|
|
+
|
|
+
|
|
project(":media") {
|
|
configurations {
|
|
media
|
|
@@ -3280,6 +3286,7 @@
|
|
|
|
doLast {
|
|
exec {
|
|
+ environment(pkgConfigEnv)
|
|
commandLine ("make", "${makeJobsFlag}", "-C", "${nativeSrcDir}/jfxmedia/projects/${projectDir}")
|
|
args("JAVA_HOME=${JDK_HOME}", "GENERATED_HEADERS_DIR=${generatedHeadersDir}",
|
|
"OUTPUT_DIR=${nativeOutputDir}", "BUILD_TYPE=${buildType}", "BASE_NAME=jfxmedia",
|
|
@@ -3309,6 +3316,7 @@
|
|
enabled = IS_COMPILE_MEDIA
|
|
doLast {
|
|
exec {
|
|
+ environment(pkgConfigEnv)
|
|
commandLine ("make", "${makeJobsFlag}", "-C", "${nativeSrcDir}/gstreamer/projects/${projectDir}/gstreamer-lite")
|
|
args("OUTPUT_DIR=${nativeOutputDir}", "BUILD_TYPE=${buildType}", "BASE_NAME=gstreamer-lite",
|
|
IS_64 ? "ARCH=x64" : "ARCH=x32", "CC=${mediaProperties.compiler}",
|
|
@@ -3327,6 +3335,7 @@
|
|
|
|
doLast {
|
|
exec {
|
|
+ environment(pkgConfigEnv)
|
|
commandLine ("make", "${makeJobsFlag}", "-C", "${nativeSrcDir}/gstreamer/projects/${projectDir}/fxplugins")
|
|
args("OUTPUT_DIR=${nativeOutputDir}", "BUILD_TYPE=${buildType}", "BASE_NAME=fxplugins",
|
|
IS_64 ? "ARCH=x64" : "ARCH=x32",
|
|
@@ -3455,6 +3464,7 @@
|
|
}
|
|
exec {
|
|
workingDir("$libavDir")
|
|
+ environment(pkgConfigEnv)
|
|
commandLine("make")
|
|
}
|
|
}
|
|
@@ -3523,6 +3533,7 @@
|
|
}
|
|
exec {
|
|
workingDir("$libavDir")
|
|
+ environment(pkgConfigEnv)
|
|
commandLine("make")
|
|
}
|
|
}
|
|
@@ -3594,6 +3605,7 @@
|
|
}
|
|
exec {
|
|
workingDir("$libavDir")
|
|
+ environment(pkgConfigEnv)
|
|
commandLine("make")
|
|
}
|
|
}
|
|
@@ -3628,6 +3640,7 @@
|
|
File dir = file(libavDir)
|
|
if (dir.exists()) {
|
|
exec {
|
|
+ environment(pkgConfigEnv)
|
|
commandLine ("make", "${makeJobsFlag}", "-C", "${nativeSrcDir}/gstreamer/projects/linux/avplugin")
|
|
args("CC=${mediaProperties.compiler}", "LINKER=${mediaProperties.linker}",
|
|
"OUTPUT_DIR=${nativeOutputDir}", "BUILD_TYPE=${buildType}",
|
|
@@ -3642,6 +3655,7 @@
|
|
File dir = file(libavDir)
|
|
if (dir.exists()) {
|
|
exec {
|
|
+ environment(pkgConfigEnv)
|
|
commandLine ("make", "${makeJobsFlag}", "-C", "${nativeSrcDir}/gstreamer/projects/linux/avplugin")
|
|
args("CC=${mediaProperties.compiler}", "LINKER=${mediaProperties.linker}",
|
|
"OUTPUT_DIR=${nativeOutputDir}", "BUILD_TYPE=${buildType}",
|
|
@@ -3656,6 +3670,7 @@
|
|
File dir = file(libavDir)
|
|
if (dir.exists()) {
|
|
exec {
|
|
+ environment(pkgConfigEnv)
|
|
commandLine ("make", "${makeJobsFlag}", "-C", "${nativeSrcDir}/gstreamer/projects/linux/avplugin")
|
|
args("CC=${mediaProperties.compiler}", "LINKER=${mediaProperties.linker}",
|
|
"OUTPUT_DIR=${nativeOutputDir}", "BUILD_TYPE=${buildType}",
|
|
@@ -3667,6 +3682,7 @@
|
|
} else {
|
|
// Building fxavcodec plugin (libav plugin)
|
|
exec {
|
|
+ environment(pkgConfigEnv)
|
|
commandLine ("make", "${makeJobsFlag}", "-C", "${nativeSrcDir}/gstreamer/projects/linux/avplugin")
|
|
args("CC=${mediaProperties.compiler}", "LINKER=${mediaProperties.linker}",
|
|
"OUTPUT_DIR=${nativeOutputDir}", "BUILD_TYPE=${buildType}",
|
|
@@ -3865,7 +3881,7 @@
|
|
exec {
|
|
workingDir("$webkitOutputDir")
|
|
commandLine("perl", "$projectDir/src/main/native/Tools/Scripts/set-webkit-configuration", "--$webkitConfig")
|
|
- environment(["WEBKIT_OUTPUTDIR" : webkitOutputDir])
|
|
+ environment(["WEBKIT_OUTPUTDIR" : webkitOutputDir, "CC" : CC, "CXX" : CXX, "AR" : AR])
|
|
}
|
|
|
|
exec {
|
|
@@ -3911,6 +3927,9 @@
|
|
"JAVA_HOME" : JDK_HOME,
|
|
"WEBKIT_OUTPUTDIR" : webkitOutputDir,
|
|
"PYTHONDONTWRITEBYTECODE" : "1",
|
|
+ "CC" : CC,
|
|
+ "CXX" : CXX,
|
|
+ "AR" : AR
|
|
])
|
|
|
|
def targetCpuBitDepthSwitch = ""
|
|
--- old/buildSrc/linux.gradle
|
|
+++ new/buildSrc/linux.gradle
|
|
@@ -55,11 +55,13 @@
|
|
commonFlags, "-I$JDK_HOME/include", "-I$JDK_HOME/include/linux", "-c",
|
|
"-ffunction-sections", "-fdata-sections",
|
|
IS_DEBUG_NATIVE ? ["-ggdb", "-DVERBOSE"] : ["-O2", "-DNDEBUG"]].flatten()
|
|
+ccFlags.addAll(ext.EXTRA_CXXFLAGS.split(" "))
|
|
def ccFlagsGTK3 = ccFlags
|
|
//ccFlags.addAll(["-Wnon-virtual-dtor", "-Woverloaded-virtual", "-std=c++0x"])
|
|
def linkFlags = ["-static-libgcc", "-static-libstdc++", "-shared", commonFlags,
|
|
"-z", "relro",
|
|
"-Wl,--gc-sections"].flatten()
|
|
+linkFlags.addAll(ext.EXTRA_LDFLAGS.split(" "))
|
|
|
|
if (IS_DEBUG_NATIVE) {
|
|
linkFlags += "-g"
|
|
@@ -78,11 +80,17 @@
|
|
def gtk3LinkFlags = [ ];
|
|
LINUX.buildGTK3 = true
|
|
|
|
+def pkgConfigEnv = [
|
|
+ PKG_CONFIG_PATH: "$PKG_CONFIG_PATH",
|
|
+ PKG_CONFIG_SYSROOT_DIR: "$PKG_CONFIG_SYSROOT_DIR"
|
|
+]
|
|
+
|
|
// Create $buildDir/linux_tools.properties file and load props from it
|
|
setupTools("linux_gtk2",
|
|
{ propFile ->
|
|
ByteArrayOutputStream results1 = new ByteArrayOutputStream();
|
|
exec {
|
|
+ environment(pkgConfigEnv)
|
|
commandLine("${toolchainDir}pkg-config", "--cflags", "gtk+-2.0", "gthread-2.0", "xtst")
|
|
setStandardOutput(results1);
|
|
}
|
|
@@ -90,6 +98,7 @@
|
|
|
|
ByteArrayOutputStream results3 = new ByteArrayOutputStream();
|
|
exec {
|
|
+ environment(pkgConfigEnv)
|
|
commandLine("${toolchainDir}pkg-config", "--libs", "gtk+-2.0", "gthread-2.0", "xtst")
|
|
setStandardOutput(results3);
|
|
}
|
|
@@ -111,6 +120,7 @@
|
|
{ propFile ->
|
|
ByteArrayOutputStream results2 = new ByteArrayOutputStream();
|
|
exec {
|
|
+ environment(pkgConfigEnv)
|
|
commandLine("${toolchainDir}pkg-config", "--cflags", "gtk+-3.0", "gthread-2.0", "xtst")
|
|
setStandardOutput(results2);
|
|
ignoreExitValue(true)
|
|
@@ -119,6 +129,7 @@
|
|
|
|
ByteArrayOutputStream results4 = new ByteArrayOutputStream();
|
|
exec {
|
|
+ environment(pkgConfigEnv)
|
|
commandLine("${toolchainDir}pkg-config", "--libs", "gtk+-3.0", "gthread-2.0", "xtst")
|
|
setStandardOutput(results4);
|
|
ignoreExitValue(true)
|
|
@@ -145,6 +156,7 @@
|
|
{ propFile ->
|
|
ByteArrayOutputStream results = new ByteArrayOutputStream();
|
|
exec {
|
|
+ environment(pkgConfigEnv)
|
|
commandLine "${toolchainDir}pkg-config", "--cflags", "pangoft2"
|
|
standardOutput = results
|
|
}
|
|
@@ -152,6 +164,7 @@
|
|
|
|
results = new ByteArrayOutputStream();
|
|
exec {
|
|
+ environment(pkgConfigEnv)
|
|
commandLine "${toolchainDir}pkg-config", "--libs", "pangoft2"
|
|
standardOutput = results
|
|
}
|
|
@@ -176,6 +189,7 @@
|
|
{ propFile ->
|
|
ByteArrayOutputStream results = new ByteArrayOutputStream();
|
|
exec {
|
|
+ environment(pkgConfigEnv)
|
|
commandLine "${toolchainDir}pkg-config", "--cflags", "freetype2"
|
|
standardOutput = results
|
|
}
|
|
@@ -183,6 +197,7 @@
|
|
|
|
results = new ByteArrayOutputStream();
|
|
exec {
|
|
+ environment(pkgConfigEnv)
|
|
commandLine "${toolchainDir}pkg-config", "--libs", "freetype2"
|
|
standardOutput = results
|
|
}
|
|
@@ -200,8 +215,8 @@
|
|
}
|
|
)
|
|
|
|
-def compiler = IS_COMPILE_PARFAIT ? "parfait-gcc" : "${toolchainDir}gcc";
|
|
-def linker = IS_COMPILE_PARFAIT ? "parfait-g++" : "${toolchainDir}g++";
|
|
+def compiler = ext.CC;
|
|
+def linker = ext.CXX;
|
|
|
|
LINUX.glass = [:]
|
|
LINUX.glass.variants = ["glass", "glassgtk2"]
|
|
@@ -337,7 +352,7 @@
|
|
LINUX.media = [:]
|
|
LINUX.media.compiler = compiler
|
|
LINUX.media.linker = linker
|
|
-LINUX.media.ar = "${toolchainDir}ar"
|
|
+LINUX.media.ar = ext.AR
|
|
|
|
LINUX.webkit = [:]
|
|
LINUX.webkit.compiler = compiler
|