1 /* 2 * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved. 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * 5 * This code is free software; you can redistribute it and/or modify it 6 * under the terms of the GNU General Public License version 2 only, as 7 * published by the Free Software Foundation. Oracle designates this 8 * particular file as subject to the "Classpath" exception as provided 9 * by Oracle in the LICENSE file that accompanied this code. 10 * 11 * This code is distributed in the hope that it will be useful, but WITHOUT 12 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 13 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 14 * version 2 for more details (a copy is included in the LICENSE file that 15 * accompanied this code). 16 * 17 * You should have received a copy of the GNU General Public License version 18 * 2 along with this work; if not, write to the Free Software Foundation, 19 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 20 * 21 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 22 * or visit www.oracle.com if you need additional information or have any 23 * questions. 24 */ 25 26 ext.ARMV6HF = [:] 27 28 // Define the location of the sdk and toolchain 29 def sdk=file("${rootProject.CROSS_TOOLS_DIR}/armhf-raspberry-pi-10") 30 def compilerHome=file("${rootProject.CROSS_TOOLS_DIR}/gcc-linaro-arm-linux-gnueabihf-raspbian-2012.09-20120921_linux") 31 def compilerPrefix 32 def jniPlatform 33 if (IS_LINUX) { 34 fetchExternalTools('ARMV6HF', 35 ["armhf-raspberry-pi-10.tgz", 36 "gcc-linaro-arm-linux-gnueabihf-raspbian-2012.09-20120921_linux.tgz" ], 37 rootProject.CROSS_TOOLS_DIR, rootProject.IS_IMPORT_CROSS_TOOLS) 38 39 compilerHome=file("${rootProject.CROSS_TOOLS_DIR}/gcc-linaro-arm-linux-gnueabihf-raspbian-2012.09-20120921_linux") 40 compilerPrefix="arm-linux-gnueabihf-" 41 jniPlatform="linux" 42 } else if (IS_MAC) { 43 fetchExternalTools('ARMV6HF', 44 ["armhf-raspberry-pi-10.tgz"], 45 rootProject.CROSS_TOOLS_DIR, rootProject.IS_IMPORT_CROSS_TOOLS) 46 47 compilerHome=file("/usr/local/arm-linux") 48 compilerPrefix="arm-linux-" 49 jniPlatform="darwin" 50 } else { 51 println "ERROR: Cannot build on this platform" 52 return; 53 } 54 55 if (rootProject.hasProperty("ARMV6HF_COMPILER")) { 56 logger.quiet "Using alternate ARMV6HF_COMPILER $rootProject.ARMV6HF_COMPILER" 57 compilerHome=file(rootProject.ARMV6HF_COMPILER); 58 } 59 if (rootProject.hasProperty("ARMV6HF_COMPILER_PREFIX")) { 60 logger.quiet "Using alternate ARMV6HF_COMPILER_PREFIX $rootProject.ARMV6HF_COMPILER_PREFIX" 61 compilerPrefix="${rootProject.ARMV6HF_COMPILER_PREFIX}" 62 } 63 64 // Declare whether this particular target file applies to the current system 65 ARMV6HF.canBuild = (IS_LINUX || IS_MAC) && compilerHome.exists() && sdk.exists() 66 if (!ARMV6HF.canBuild) { 67 if (!compilerHome.exists()) println "ERROR: Mising compiler $compilerHome" 68 if (!sdk.exists()) println "ERROR: Mising sdk $sdk" 69 return; 70 } 71 72 // Lambda for naming the generated libs 73 ARMV6HF.library = { name -> return "lib${name}.so" as String } 74 75 ARMV6HF.compileSwing = false; 76 ARMV6HF.compileSWT = false; 77 ARMV6HF.compileFXPackager = false; 78 ARMV6HF.compileDesignTime = false; 79 80 // Libraries end up in the sdk/rt/lib/arm directory for arm builds 81 ARMV6HF.libDest = "lib/arm" 82 83 // TODO this is garbage. Each target file should define what it includes, 84 // not what it excludes. 85 ARMV6HF.jfxrtJarExcludes = [ 86 "**/*.hlsl", 87 "com/sun/glass/ui/win", 88 "com/sun/glass/ui/accessible/win", 89 "com/sun/prism/d3d", 90 "com/sun/prism/es2/gl/win", 91 //"com/sun/prism/null3d", 92 "com/sun/scenario/effect/impl/hw/d3d", 93 94 "com/sun/glass/events/mac", 95 "com/sun/glass/ui/mac", 96 "com/sun/glass/ui/accessible/mac", 97 "com/sun/prism/es2/gl/mac", 98 99 "com/sun/glass/ui/android", 100 101 "com/sun/glass/ui/ios", 102 103 "com/sun/glass/ui/swt", // SWT glass 104 105 "javafx/embed/swing", // Swing Interop 106 107 "javafx/embed/swt", // SWT Interop 108 109 "com/sun/prism/es2/MacGL*", 110 "com/sun/prism/es2/IOSGL*", 111 "com/sun/prism/es2/WinGL*", 112 ] 113 114 def commonFlags = [ 115 "-fno-strict-aliasing", "-fPIC", "-fno-omit-frame-pointer", // optimization flags 116 "-W", "-Wall", "-Wno-unused", "-Wno-parentheses", "-Werror=implicit-function-declaration"] // warning flags 117 // Specify the compilation parameters and link parameters 118 def ccFlags = [ 119 commonFlags, "-I$JDK_HOME/include", "-I$JDK_HOME/include/$jniPlatform", "-c", 120 IS_DEBUG_NATIVE ? ["-ggdb", "-DVERBOSE"] : "-O2"].flatten() 121 //ccFlags.addAll(["-Wnon-virtual-dtor", "-Woverloaded-virtual", "-std=c++0x"]) 122 def linkFlags = ["-shared", commonFlags].flatten() 123 124 // Specify the compilation parameters and link parameters 125 def extraCFlags = [ 126 "-I", "-L", 127 ccFlags, 128 "-marm", "-mfloat-abi=hard", "-mfpu=vfp", 129 "-I$sdk/usr/include", 130 "-I$sdk/opt/vc/include", 131 "-I$sdk/opt/vc/include/interface/vcos/pthreads", 132 "-I$sdk/opt/vc/include/interface/vmcs_host/linux", 133 "-DOMAP3", "-DUSE_DISPMAN"].flatten(); 134 135 //See if we should build for imx6 136 def imxHeader=file("$sdk/usr/include/linux/mxcfb.h") 137 if (imxHeader.exists()) { 138 extraCFlags = [extraCFlags,"-DIMX6_PLATFORM"].flatten(); 139 } 140 141 def extraLFlags = [ 142 "-I", "-L", 143 linkFlags, 144 "-L$sdk/lib/arm-linux/gnueabihf", 145 "-L$sdk/usr/lib", 146 "-L$sdk/usr/lib/arm-linux-gnueabihf", 147 "-L$sdk/opt/vc/lib"].flatten() 148 149 def lensLFlags = [extraLFlags, "-lpthread", "-ludev", "-ldl", "-lm"].flatten() 150 def monocleCFlags = [ 151 extraCFlags, 152 "-Werror", 153 "-I", file("modules/graphics/src/main/native-glass/monocle/")].flatten(); 154 def monocleLFlags = [extraLFlags, "-ldl", "-lm"].flatten() 155 156 def fontCFlags = [extraCFlags].flatten() 157 def fontLFlags = [extraLFlags].flatten() 158 159 def iioCFlags = [extraCFlags].flatten() 160 def iioLFlags = [extraLFlags].flatten() 161 162 def es2EglfbCFlags = [extraCFlags, "-DIS_EGLFB", "-DLINUX"].flatten() 163 def es2EglfbLFlags = [extraLFlags].flatten() 164 def es2MonocleCFlags = [extraCFlags, "-DIS_EGLFB", "-DLINUX"].flatten() 165 def es2MonocleLFlags = [extraLFlags].flatten() 166 167 def es2X11CFlags = [extraCFlags, "-DUSE_XSHM", "-DDEBUG", "-DIS_EGLX11", "-DLINUX"].flatten() 168 def es2X11LFlags = [extraLFlags, "-lX11", "-lXext", "-lXdmcp", "-lXau"].flatten() 169 170 def mediaCFlags = [extraCFlags, 171 "-I$sdk/usr/include/gstreamer-0.10", 172 "-I$sdk/usr/include/glib-2.0", 173 "-I$sdk/usr/lib/arm-linux-gnueabihf/glib-2.0/include", 174 "-DENABLE_NATIVE_SOURCE=1", "-DENABLE_GST_FFMPEG=1"].flatten() 175 def mediaLFlags = [extraLFlags, "-lgstreamer-0.10", "-lgstapp-0.10", 176 "-lgstbase-0.10", "-lglib-2.0", "-lgobject-2.0", "-lgmodule-2.0", "-lgthread-2.0"].flatten() 177 178 def webCFlags = [extraCFlags].flatten() 179 def webLFlags = [extraLFlags].flatten() 180 181 // libraries to remove from the SDK 182 //deploy.trim.public.library.filter= \ 183 // fxavcodecplugin-52.so \ 184 // fxavcodecplugin-53.so \ 185 // fxplugins.so \ 186 // libjfxwebkit.so \ 187 // libgstplugins-lite.so \ 188 // libgstreamer-lite.so \ 189 // libprism-es2-eglx11.so \ 190 // libglass_lens_fb.so \ 191 192 def gtkCFlags = [extraCFlags].flatten() 193 def gtkLFlags = [extraLFlags].flatten() 194 setupTools("armv6hf_tools", 195 { propFile -> 196 ByteArrayOutputStream results = new ByteArrayOutputStream(); 197 exec { 198 commandLine("$sdk/bin/pkg-config", "--cflags", "gtk+-2.0", "gthread-2.0", "xtst"); 199 setStandardOutput(results); 200 } 201 propFile << "cflags=" << results.toString().trim() << "\n"; 202 203 results = new ByteArrayOutputStream(); 204 exec { 205 commandLine "$sdk/bin/pkg-config", "--libs", "gtk+-2.0", "gthread-2.0", "xtst" 206 standardOutput = results 207 } 208 propFile << "libs=" << results.toString().trim(); 209 }, 210 { properties -> 211 gtkCFlags.addAll(properties.getProperty("cflags").split(" ")) 212 gtkLFlags.addAll(properties.getProperty("libs").split(" ")) 213 } 214 ) 215 216 ARMV6HF.javafxPlatformProperties ="""javafx.platform=eglfb 217 directfb.com.sun.javafx.scene.control.skin.ListViewSkin.pannable=true 218 directfb.com.sun.javafx.scene.control.skin.TreeViewSkin.pannable=true 219 directfb.com.sun.javafx.scene.control.skin.TableViewSkin.pannable=true 220 directfb.glass.platform=Lens 221 directfb.glass.lens=dfb 222 directfb.prism.order=sw 223 directfb.com.sun.javafx.isEmbedded=true 224 directfb.com.sun.javafx.scene.control.skin.FXVK.cache=true 225 eglfb.com.sun.javafx.scene.control.skin.ListViewSkin.pannable=true 226 eglfb.com.sun.javafx.scene.control.skin.TreeViewSkin.pannable=true 227 eglfb.com.sun.javafx.scene.control.skin.TableViewSkin.pannable=true 228 eglfb.glass.platform=Lens 229 eglfb.glass.lens=eglfb 230 eglfb.prism.order=es2 231 eglfb.prism.eglfb=true 232 eglfb.prism.lcdtext=false 233 eglfb.prism.maxvram=128m 234 eglfb.prism.targetvram=112m 235 eglfb.use.egl=true 236 eglfb.use.gles2=true 237 eglfb.embedded=eglfb 238 eglfb.com.sun.javafx.isEmbedded=true 239 eglfb.doNativeComposite=true 240 eglfb.com.sun.javafx.scene.control.skin.FXVK.cache=true 241 eglfb.prism.glDepthSize=0 242 fb.com.sun.javafx.scene.control.skin.ListViewSkin.pannable=true 243 fb.com.sun.javafx.scene.control.skin.TreeViewSkin.pannable=true 244 fb.com.sun.javafx.scene.control.skin.TableViewSkin.pannable=true 245 fb.glass.platform=Lens 246 fb.glass.lens=fb 247 fb.prism.order=sw 248 fb.com.sun.javafx.isEmbedded=true 249 fb.glass.restrictWindowToScreen=true 250 fb.com.sun.javafx.scene.control.skin.FXVK.cache=true 251 monocle.glass.platform=Monocle 252 monocle.prism.order=es2,sw 253 monocle.prism.eglfb=true 254 monocle.prism.lcdtext=false 255 monocle.prism.maxvram=128m 256 monocle.prism.targetvram=112m 257 monocle.use.egl=true 258 monocle.use.gles2=true 259 monocle.embedded=monocle 260 monocle.com.sun.javafx.isEmbedded=true 261 monocle.doNativeComposite=true 262 monocle.com.sun.javafx.scene.control.skin.FXVK.cache=true 263 monocle.prism.glDepthSize=0 264 eglx11.com.sun.javafx.scene.control.skin.ListViewSkin.pannable=true 265 eglx11.com.sun.javafx.scene.control.skin.TreeViewSkin.pannable=true 266 eglx11.com.sun.javafx.scene.control.skin.TableViewSkin.pannable=true 267 eglx11.glass.platform=Lens 268 eglx11.glass.lens=eglx11 269 eglx11.prism.order=es2 270 eglx11.prism.eglx11=true 271 eglx11.prism.lcdtext=false 272 eglx11.prism.maxvram=128m 273 eglx11.prism.targetvram=112m 274 eglx11.use.egl=true 275 eglx11.use.gles2=true 276 eglx11.embedded=eglx11 277 eglx11.com.sun.javafx.isEmbedded=true 278 eglx11.com.sun.javafx.scene.control.skin.FXVK.cache=true 279 eglx11.prism.glDepthSize=0 280 gtk.com.sun.javafx.scene.control.skin.ListViewSkin.pannable=true 281 gtk.com.sun.javafx.scene.control.skin.TreeViewSkin.pannable=true 282 gtk.com.sun.javafx.scene.control.skin.TableViewSkin.pannable=true 283 gtk.glass.platform=gtk 284 gtk.prism.order=sw 285 gtk.com.sun.javafx.isEmbedded=true 286 gtk.com.sun.javafx.scene.control.skin.FXVK.cache=true""" 287 288 def pangoCCFlags = [extraCFlags, "-D_ENABLE_PANGO"]; 289 def pangoLinkFlags = [extraLFlags]; 290 setupTools("armv6hf_pango_tools", 291 { propFile -> 292 ByteArrayOutputStream results = new ByteArrayOutputStream(); 293 exec { 294 commandLine "$sdk/bin/pkg-config", "--cflags", "pangoft2" 295 standardOutput = results 296 } 297 propFile << "cflags=" << results.toString().trim() << "\n"; 298 299 results = new ByteArrayOutputStream(); 300 exec { 301 commandLine "$sdk/bin/pkg-config", "--libs", "pangoft2" 302 standardOutput = results 303 } 304 propFile << "libs=" << results.toString().trim(); 305 }, 306 { properties -> 307 pangoCCFlags.addAll(properties.getProperty("cflags").split(" ")) 308 pangoLinkFlags.addAll(properties.getProperty("libs").split(" ")) 309 } 310 ) 311 312 def freetypeCCFlags = [ext.IS_COMPILE_PANGO ? "-D_ENABLE_PANGO" : 313 ext.IS_COMPILE_HARFBUZZ ? "-D_ENABLE_HARFBUZZ" : ""] 314 def freetypeLinkFlags = [] 315 setupTools("armv6hf_freetype_tools", 316 { propFile -> 317 ByteArrayOutputStream results = new ByteArrayOutputStream(); 318 exec { 319 commandLine "$sdk/bin/pkg-config", "--cflags", "freetype2" 320 standardOutput = results 321 } 322 propFile << "cflags=" << results.toString().trim() << "\n"; 323 324 results = new ByteArrayOutputStream(); 325 exec { 326 commandLine "$sdk/bin/pkg-config", "--libs", "freetype2" 327 standardOutput = results 328 } 329 propFile << "libs=" << results.toString().trim(); 330 }, 331 { properties -> 332 freetypeCCFlags.addAll(properties.getProperty("cflags").split(" ")) 333 freetypeLinkFlags.addAll(properties.getProperty("libs").split(" ")) 334 } 335 ) 336 337 def compiler = file("$compilerHome/bin/${compilerPrefix}gcc").getAbsolutePath() 338 def linker = file("$compilerHome/bin/${compilerPrefix}g++").getAbsolutePath() 339 340 ARMV6HF.glass = [:] 341 ARMV6HF.glass.variants = ["eglfb", "directfb", "fb", "gtk", "lensport", "monocle", "monocle_x11" ] 342 ARMV6HF.glass.javahInclude = [ 343 "com/sun/glass/events/**", 344 "com/sun/glass/ui/*", 345 "com/sun/glass/ui/lens/*", 346 "com/sun/glass/ui/monocle/*", 347 "com/sun/glass/ui/monocle/dispman/*", 348 "com/sun/glass/ui/monocle/mx6/*", 349 "com/sun/glass/ui/monocle/linux/*", 350 "com/sun/glass/ui/monocle/util/*", 351 "com/sun/glass/ui/monocle/x11/*", 352 "com/sun/glass/ui/gtk/*", 353 "com/sun/glass/ui/accessible/gtk/*"] 354 ARMV6HF.glass.lib = "glass" 355 356 ARMV6HF.glass.lensport = [:] 357 ARMV6HF.glass.lensport.nativeSource = [ 358 file("modules/graphics/src/main/native-glass/lens/lensport") ] 359 ARMV6HF.glass.lensport.compiler = compiler 360 ARMV6HF.glass.lensport.ccFlags = ["-ffast-math", extraCFlags, "-DLINUX", "-DISEGLFB", 361 "-DLENSPORT", "-I", file("modules/graphics/src/main/native-glass/lens/") ].flatten() 362 ARMV6HF.glass.lensport.linker = linker 363 ARMV6HF.glass.lensport.linkFlags = [lensLFlags].flatten() 364 ARMV6HF.glass.lensport.lib = "lens_porting" 365 366 ARMV6HF.glass.monocle = [:] 367 ARMV6HF.glass.monocle.nativeSource = [ 368 file("modules/graphics/src/main/native-glass/monocle"), 369 file("modules/graphics/src/main/native-glass/monocle/dispman"), 370 file("modules/graphics/src/main/native-glass/monocle/mx6"), 371 file("modules/graphics/src/main/native-glass/monocle/linux"), 372 file("modules/graphics/src/main/native-glass/monocle/util") ] 373 ARMV6HF.glass.monocle.compiler = compiler 374 ARMV6HF.glass.monocle.ccFlags = monocleCFlags 375 ARMV6HF.glass.monocle.linker = linker 376 ARMV6HF.glass.monocle.linkFlags = monocleLFlags 377 ARMV6HF.glass.monocle.lib = "glass_monocle" 378 379 ARMV6HF.glass.monocle_x11 = [:] 380 ARMV6HF.glass.monocle_x11.nativeSource = [ 381 file("modules/graphics/src/main/native-glass/monocle/util"), 382 file("modules/graphics/src/main/native-glass/monocle/x11") ] 383 ARMV6HF.glass.monocle_x11.compiler = compiler 384 ARMV6HF.glass.monocle_x11.ccFlags = monocleCFlags 385 ARMV6HF.glass.monocle_x11.linker = linker 386 ARMV6HF.glass.monocle_x11.linkFlags = [ monocleLFlags, "-lX11" ].flatten() 387 ARMV6HF.glass.monocle_x11.lib = "glass_monocle_x11" 388 389 ARMV6HF.glass.eglfb = [:] 390 // TODO when building headless, use lens/cursor/nullcursor/ 391 // otherwise we use lens/cursor/fbCursor/ and lens/input/udev 392 393 // TODO when USE_RFB is specified use lens/rfb 394 395 // TODO use /eglfb/x11ContainerScreen when using eglfb and EGL_X11_FB_CONTAINER 396 // TODO use /headless/headlessScreen when using headless 397 ARMV6HF.glass.eglfb.nativeSource = [ 398 file("modules/graphics/src/main/native-glass/lens"), 399 file("modules/graphics/src/main/native-glass/lens/wm"), 400 file("modules/graphics/src/main/native-glass/lens/cursor/fbCursor"), 401 file("modules/graphics/src/main/native-glass/lens/input/udev"), 402 file("modules/graphics/src/main/native-glass/lens/wm/screen/fbdevScreen.c") ] 403 ARMV6HF.glass.eglfb.compiler = compiler 404 ARMV6HF.glass.eglfb.ccFlags = ["-ffast-math", extraCFlags, "-DLINUX", "-DISEGLFB"].flatten() 405 ARMV6HF.glass.eglfb.linker = linker 406 ARMV6HF.glass.eglfb.linkFlags = [lensLFlags].flatten() 407 ARMV6HF.glass.eglfb.lib = "glass_lens_eglfb" 408 409 ARMV6HF.glass.directfb = [:] 410 ARMV6HF.glass.directfb.nativeSource = [ 411 file("modules/graphics/src/main/native-glass/lens"), 412 file("modules/graphics/src/main/native-glass/lens/wm"), 413 file("modules/graphics/src/main/native-glass/lens/cursor/fbCursor"), 414 file("modules/graphics/src/main/native-glass/lens/input/udev"), 415 file("modules/graphics/src/main/native-glass/lens/wm/screen/dfbScreen.c") ] 416 ARMV6HF.glass.directfb.compiler = compiler 417 ARMV6HF.glass.directfb.ccFlags = ["-ffast-math", extraCFlags, "-I$sdk/usr/include/directfb", "-DLINUX"].flatten() 418 ARMV6HF.glass.directfb.linker = linker 419 ARMV6HF.glass.directfb.linkFlags = [lensLFlags].flatten() 420 ARMV6HF.glass.directfb.lib = "glass_lens_dfb" 421 422 ARMV6HF.glass.fb = [:] 423 ARMV6HF.glass.fb.nativeSource = [ 424 file("modules/graphics/src/main/native-glass/lens"), 425 file("modules/graphics/src/main/native-glass/lens/wm"), 426 file("modules/graphics/src/main/native-glass/lens/cursor/fbCursor"), 427 file("modules/graphics/src/main/native-glass/lens/input/udev"), 428 file("modules/graphics/src/main/native-glass/lens/wm/screen/fbdevScreen.c") ] 429 ARMV6HF.glass.fb.compiler = compiler 430 ARMV6HF.glass.fb.ccFlags = ["-ffast-math", extraCFlags, "-DLINUX"].flatten() 431 ARMV6HF.glass.fb.linker = linker 432 ARMV6HF.glass.fb.linkFlags = [lensLFlags].flatten() 433 ARMV6HF.glass.fb.lib = "glass_lens_fb" 434 435 ARMV6HF.glass.eglx11 = [:] 436 ARMV6HF.glass.eglx11.nativeSource = [ 437 file("modules/graphics/src/main/native-glass/lens"), 438 file("modules/graphics/src/main/native-glass/lens/wm"), 439 file("modules/graphics/src/main/native-glass/lens/cursor/fbCursor"), 440 file("modules/graphics/src/main/native-glass/lens/input/udev"), 441 file("modules/graphics/src/main/native-glass/lens/wm/screen/x11ContainerScreen.c")] 442 //file("modules/graphics/src/main/native-glass/lens/wm/screen")] 443 ARMV6HF.glass.eglx11.compiler = compiler 444 ARMV6HF.glass.eglx11.ccFlags = ["-ffast-math", extraCFlags, "-DLINUX"].flatten() 445 ARMV6HF.glass.eglx11.linker = linker 446 ARMV6HF.glass.eglx11.linkFlags = [lensLFlags].flatten() 447 ARMV6HF.glass.eglx11.lib = "glass_lens_eglx11" 448 449 ARMV6HF.glass.gtk = [:] 450 ARMV6HF.glass.gtk.nativeSource = file("modules/graphics/src/main/native-glass/gtk") 451 ARMV6HF.glass.gtk.compiler = compiler 452 ARMV6HF.glass.gtk.ccFlags = ["-ffast-math", gtkCFlags, "-DLINUX"].flatten() 453 ARMV6HF.glass.gtk.linker = linker 454 ARMV6HF.glass.gtk.linkFlags = [gtkLFlags, "-lstdc++"].flatten() 455 ARMV6HF.glass.gtk.lib = "glass" 456 457 ARMV6HF.decora = [:] 458 ARMV6HF.decora.compiler = compiler 459 ARMV6HF.decora.ccFlags = extraCFlags 460 ARMV6HF.decora.linker = linker 461 ARMV6HF.decora.linkFlags = extraLFlags 462 ARMV6HF.decora.lib = "decora_sse" 463 464 ARMV6HF.prism = [:] 465 ARMV6HF.prism.javahInclude = ["com/sun/prism/impl/**/*", "com/sun/prism/PresentableState*"] 466 ARMV6HF.prism.nativeSource = file("modules/graphics/src/main/native-prism") 467 ARMV6HF.prism.compiler = compiler 468 ARMV6HF.prism.ccFlags = [extraCFlags].flatten() 469 ARMV6HF.prism.linker = linker 470 ARMV6HF.prism.linkFlags = [extraLFlags].flatten() 471 ARMV6HF.prism.lib = "prism_common" 472 473 ARMV6HF.prismSW = [:] 474 ARMV6HF.prismSW.javahInclude = ["com/sun/pisces/**/*"] 475 ARMV6HF.prismSW.nativeSource = file("modules/graphics/src/main/native-prism-sw") 476 ARMV6HF.prismSW.compiler = compiler 477 ARMV6HF.prismSW.ccFlags = [extraCFlags].flatten() 478 ARMV6HF.prismSW.linker = linker 479 ARMV6HF.prismSW.linkFlags = [extraLFlags].flatten() 480 ARMV6HF.prismSW.lib = "prism_sw" 481 482 ARMV6HF.iio = [:] 483 ARMV6HF.iio.javahInclude = ["com/sun/javafx/iio/**/*"] 484 ARMV6HF.iio.nativeSource = [ 485 file("modules/graphics/src/main/native-iio"), 486 file("modules/graphics/src/main/native-iio/libjpeg7")] 487 ARMV6HF.iio.compiler = compiler 488 ARMV6HF.iio.ccFlags = iioCFlags 489 ARMV6HF.iio.linker = linker 490 ARMV6HF.iio.linkFlags = iioLFlags 491 ARMV6HF.iio.lib = "javafx_iio" 492 493 ARMV6HF.prismES2 = [:] 494 ARMV6HF.prismES2.variants = ["eglfb", "monocle"] 495 ARMV6HF.prismES2.javahInclude = ["com/sun/prism/es2/**/*"] 496 497 ARMV6HF.prismES2.eglfb = [:] 498 ARMV6HF.prismES2.eglfb.nativeSource = [ 499 file("modules/graphics/src/main/native-prism-es2"), 500 file("modules/graphics/src/main/native-prism-es2/GL"), 501 file("modules/graphics/src/main/native-prism-es2/eglfb") 502 ] 503 ARMV6HF.prismES2.eglfb.compiler = compiler 504 ARMV6HF.prismES2.eglfb.ccFlags = [ es2EglfbCFlags, "-I", ARMV6HF.glass.lensport.nativeSource ].flatten() 505 ARMV6HF.prismES2.eglfb.linker = linker 506 ARMV6HF.prismES2.eglfb.linkFlags = es2EglfbLFlags 507 ARMV6HF.prismES2.eglfb.lib = "prism_es2_eglfb" 508 509 ARMV6HF.prismES2.monocle= [:] 510 ARMV6HF.prismES2.monocle.nativeSource = [ 511 file("modules/graphics/src/main/native-prism-es2"), 512 file("modules/graphics/src/main/native-prism-es2/GL"), 513 file("modules/graphics/src/main/native-prism-es2/monocle") 514 ] 515 ARMV6HF.prismES2.monocle.compiler = compiler 516 ARMV6HF.prismES2.monocle.ccFlags = [ es2EglfbCFlags, "-I", ARMV6HF.glass.lensport.nativeSource ].flatten() 517 ARMV6HF.prismES2.monocle.linker = linker 518 ARMV6HF.prismES2.monocle.linkFlags = es2EglfbLFlags 519 ARMV6HF.prismES2.monocle.lib = "prism_es2_monocle" 520 521 ARMV6HF.prismES2.eglx11 = [:] 522 ARMV6HF.prismES2.eglx11.nativeSource = [ 523 file("modules/graphics/src/main/native-prism-es2"), 524 file("modules/graphics/src/main/native-prism-es2/GL"), 525 file("modules/graphics/src/main/native-prism-es2/eglx11") 526 ] 527 ARMV6HF.prismES2.eglx11.compiler = compiler 528 ARMV6HF.prismES2.eglx11.ccFlags = es2X11CFlags 529 ARMV6HF.prismES2.eglx11.linker = linker 530 ARMV6HF.prismES2.eglx11.linkFlags = es2X11LFlags 531 ARMV6HF.prismES2.eglx11.lib = "prism_es2_eglx11" 532 533 def closedDir = file("$projectDir/../rt-closed") 534 ARMV6HF.font = [:] 535 ARMV6HF.font.javahInclude = [ 536 "com/sun/javafx/font/**/*", 537 "com/sun/javafx/text/**/*"] 538 ARMV6HF.font.nativeSource = [file("modules/graphics/src/main/native-font")] 539 ARMV6HF.font.compiler = compiler 540 ARMV6HF.font.ccFlags = fontCFlags 541 ARMV6HF.font.linker = linker 542 ARMV6HF.font.linkFlags = fontLFlags 543 ARMV6HF.font.lib = "javafx_font" 544 545 ARMV6HF.fontT2K = [:] 546 ARMV6HF.fontT2K.javahInclude = ["com/sun/javafx/font/t2k/**/*"] 547 ARMV6HF.fontT2K.nativeSource = [ 548 file("$closedDir/javafx-font-t2k-native/src"), 549 file("$closedDir/javafx-font-t2k-native/src/layout")] 550 ARMV6HF.fontT2K.compiler = compiler 551 ARMV6HF.fontT2K.ccFlags = [fontCFlags, "-DLE_STANDALONE"].flatten() 552 ARMV6HF.fontT2K.linker = linker 553 ARMV6HF.fontT2K.linkFlags = fontLFlags 554 ARMV6HF.fontT2K.lib = "javafx_font_t2k" 555 556 ARMV6HF.fontFreetype = [:] 557 ARMV6HF.fontFreetype.javahInclude = ["com/sun/javafx/font/freetype/OSFreetype.class*"] 558 ARMV6HF.fontFreetype.nativeSource = ["src/main/native-font/freetype.c"] 559 ARMV6HF.fontFreetype.compiler = compiler 560 ARMV6HF.fontFreetype.ccFlags = ["-DJFXFONT_PLUS", ccFlags, fontCFlags, freetypeCCFlags].flatten() 561 ARMV6HF.fontFreetype.linker = linker 562 ARMV6HF.fontFreetype.linkFlags = [linkFlags, fontLFlags, freetypeLinkFlags].flatten() 563 ARMV6HF.fontFreetype.lib = "javafx_font_freetype" 564 565 ARMV6HF.fontPango = [:] 566 ARMV6HF.fontPango.javahInclude = ["com/sun/javafx/font/freetype/OSPango.class"] 567 ARMV6HF.fontPango.nativeSource = ["src/main/native-font/pango.c"] 568 ARMV6HF.fontPango.compiler = compiler 569 ARMV6HF.fontPango.ccFlags = ["-DJFXFONT_PLUS", ccFlags, pangoCCFlags].flatten() 570 ARMV6HF.fontPango.linker = linker 571 ARMV6HF.fontPango.linkFlags = [linkFlags, pangoLinkFlags].flatten() 572 ARMV6HF.fontPango.lib = "javafx_font_pango" 573 574 ARMV6HF.webkit = [:] 575 ARMV6HF.webkit.binDir = "$compilerHome/bin" 576 ARMV6HF.webkit.compiler = compiler 577 ARMV6HF.webkit.linker = linker 578 ARMV6HF.webkit.ar = file("$compilerHome/bin/${compilerPrefix}ar").getAbsolutePath() 579 ARMV6HF.webkit.objcopy = file("$compilerHome/bin/${compilerPrefix}objcopy").getAbsolutePath() 580 ARMV6HF.webkit.strip = file("$compilerHome/bin/${compilerPrefix}strip").getAbsolutePath() 581 ARMV6HF.webkit.ccFlags = extraCFlags.join(' ') 582 ARMV6HF.webkit.linkFlags = extraLFlags.join(' ') 583 584 ARMV6HF.media = [:] 585 ARMV6HF.media.compiler = compiler 586 ARMV6HF.media.linker = linker 587 ARMV6HF.media.extra_cflags = mediaCFlags.join(' ') 588 ARMV6HF.media.extra_ldflags = mediaLFlags.join(' ')