Skip to content

Commit

Permalink
SparkGL support (#2069)
Browse files Browse the repository at this point in the history
* webgl support (#1859)

* Added initial webgl support

* added a new api for shared contexts and references (#1742)

*  added a new api for shared contexts and references (#1744)

* added a new api for shared contexts and references

* added a new api for shared contexts and references update

* shared context support for egl (#1750)

* initial commit

* updates

* updates

* updates

* thread safety support

* threading updates

* update

* removing test for removed api

* fix for mips contexts (#1756)

* updates to the new shared context api

* Added view events for the webgl view

* Enhanced triangle sample to log out some view events

* Added a todo comment

* Fixed crash when creating a Function object

* Added support for setTimeout to setup gl context

* depth support for egl

* setImmediate wrapper to setup drawing context

* Fixed a bug in clearImmediate wrapper

* A fix to make webgl scene nav more stable

* Added a variation of the triangle webgl sample

* Applied a patch to RunInThisContext

* adding the process object to sandbox

* Added a per sandbox spark module system

* exposing beginDrawing/endDrawing to global space

* Fixed crash in https ... lightning content reloads

* Clear color in new gl context

* Clearing initial framebuffer for webgl context

* fix a typo in method9ArgAndNoReturn macro

Signed-off-by: Gurdal Oruklu <gurdaloruklu@gmail.com>

* initial commit for WebGL

* fix libnode6.9 macOS compiler flags

* modified triangle2.js to use Spark's own WebGL

* merge update

* merge updates

* build fixes (#1862)

* build fixes

* build fixes

* adding edge builds (#1875)

* node updates and patches

* node updates

* updates for edge builds

* fix for edge build auto updates (#1876)

* fix onClose, fix setImmediate (#1906)

* add more modules to sandbox (#1885)

* run init.js as starting script

* run init.js as starting script

* Update test_rtnode.cpp

* Update test_rtnode.cpp

* Management of HTTP, HTTPS, WebSockets lifetimes (#1912)

* Management of HTTP, HTTPS, WebSockets lifetimes

* fix typo (https vs http, clearImmediate vs clearTimeout), better logging

* ability to get native texture id for pxTextureOffscreen (#1892) (#1921)

*  adding ability to create and expose textures of text and images objects (#1929)

* adding ability to create and expose textures of text and images

* updates

* texture creation helper api (#1931)

* rendering updates for text and images (#1933)

* Webgl fixes for linux (#1920)

* fixes for lightning++ on linux

* a fix for gl black screen

* fixed stuff which was reset during beginDrawing/endDrawing

* same fixes for triangle2.js

* minor changes for mac

* Update spark.sh

* node10 integration (#1934)

* adding node10 source code

* node-v10.5.3

* Revert "node-v10.5.3"

This reverts commit 96703c2.

* spark changes for node10

* spark changes for node10

* remove 8.15.1 files

* remove 8.15.1 files

* Update CommDeps.cmake

* Update spark.sh

* Update leak.supp

* windows changes

* windows changes

* compatibility with node 6.9

* Update execute_linux.sh

* compatibility with node 6.9

* fix uwebsockets build locally

* fix uwebsockets build locally

* fix crash on syntax errors

* fix crash on syntax errors

* Update leak.supp

* adding qemu patch

* reduce logging (#1945)

* fix 3-box (upgrade to canvas 2.x, infinite loop fix, gl fixes) and 4-static (gl fixes) (#1943)

* local storage for Lightning++ (#1944)

* enabling inspector (#1942)

* enabling inspector

* enabling inspector

* adding node-fetch module (#1954)

* mjs support changes (#1956)

* mjs support changes

* Update pxScene2d.cpp

* Update initGL.js

* Update initGL.js

* Update initGL.js

* adding some additional node modules (#1957)

* gl header updates (#1958)

* remove the need to build with harfbuzz (#1959)

* adding ability to flip images vertically when created (#1960)

* adding ability to flip images

* image udpates

* image updates

* image updates

* script updates (#1965)

* startup optimizations (#1967)

* added some missing webGL functions (#1969)

* changes for fixing path issues on js file under webgl (#1961)

* Update execute_linux.sh

* Update execute_linux.sh

* changes for running js file

* changes for fixing path issues on js file under webgl

* optimizations (#1972)

* optimization

* updates

* image resource flip updates (#1973)

* optimization

* updates

* image resource flip updates

* expose localStorage, a fix for non-mjs files (#1963)

* cleanup initGL (#1978)

* cleanup initGL

* Update initGL.js

* Update execute_linux.sh

* Update execute_linux.sh

* Update initGL.js

* Update initGL.js

* changes for fixing node6,node10 compatibility (#1990)

* fix for crash on exception on async execution (#1993)

* fixing issues seen with running apps remotely (#1994)

* fixing issues seen with running apps remotely

* Update initGL.js

* code cleanup (#1995)

* Effects merge (#1998)

* Adding [shaderResource] (#1908)

* Adding [shaderResource]

* Changed log level

* Adding files missed in merge/pick

* Define needed...

* Warnings...

* More warnings.

* Updates ...

* Minor fix

* Refactor / Tidy

* More tidying...

* Updates

* Naming convention for "internal" classes

* Update pxMatrix4T.h

* Missed removal of [pxShaderEffect.cpp] ... fixed

* Errant include of "pxShaderEffect.h" - now removed

* Refactor and Simplification

* Removed errant [skipTransform} ...

* Inlining...

* Refactor and Tidy up

* Tidy up unused code

* Tidy

* Revert name change

* Remove dead code

* Narrow scope via 'static' ...

* Simplification

* Refactoring...

* References !

* Adding CI test for [ shaderResource ]

* Fix warnings

* Name change to avoid conflicts

* Refactor to isolate code better

* Grrrrr... "#define ANIMATION_ROTATE_XYZ"

* Grrrr 2 ... "#define ANIMATION_ROTATE_XYZ"

* Grrr 3 - "#define ANIMATION_ROTATE_XYZ"

* Only one "#define ANIMATION_ROTATE_XYZ" ...

* Bug

* Changed dependency

* Refactor program and "use()"

* Tidy up

* Adding tests ... some refactoring

* CodeCov Test updates

* Additional tests ...

* Updates

* Additional testing changes

* Project changes + bug fix

* Updates to tests

* Missed a bug in merge.

* Comment out Archive support (for now)

* "off by one" bug in copy from rtString to rtData

* Refactoring and refinement.

* Fixes to google tests

* Unused params

* Adding flush() to API

* Save/Restore uniforms

* Permit "no uniforms" in config.

* Updated CPP unit test.  Fixed comment.

* Removed glException class throw/catch. Fix Reject

* Fix warnings

* Update per Review comments

* Missed a change.  Added Warning.

* Removed errant AddRef() calls

* Adding appropriate AddRef() calls.

* Minor edit

* ANIMATION_ROTATE_XYZ  related

* Adding include.

* Class name change

* More detail.

* Useful comment

* Avoid flicker on RT shaders

* Allow a little more time to test.

* Refactor use of shaders and FBO's

* Removed unnecessary 'flush()' api

* Remove AddRef() ... possible leak

* Fix for "FILE://" or "file://" prefixed URL's (#1984)

* Fix for "FILE://" or "file://" prefixed URL's

* Typo fix

*  Typo ... should have been Lowercase + Uppercase (#1986)

* Fix for "FILE://" or "file://" prefixed URL's

* Typo fix

* Typo ... should have been Lowercase + Uppercase

* AddRef() - Fix for compailation failed case. (#1989)

* AddRef() - Fix for compailation failed case.

* Revert .shaders version 2 -> 1

* Quieter

* Fixes for Shader Compilation failures

* Changes per PR review.

* Fix for Data/File mix permutations

* updates

* code coverage improvement for eventloop and windownative (#1870)

*  bootstrap (#1991)

* refactoring of json util functions

* bootstrap

* extension should include dot

* create app with options

* support non-gl: URLs in initGL

* optimization

* fix broken CI, revert some changes

* CI test, a fix for .spark?... urls

* create ready promise in constructor

* change useBaseURI to a proper value

* memory leak fix

* default to transparent background for sparkgl apps (#2007)

* support for spark keys and q downloads with query params (#2010)

* image flip updates and ability to read query parameters (#2012)

* image flip updates

* support to read query parameters

* fix overriding of file descriptors on spawned processes (#2014)

* Implemented fillText() and fillStyle() with color, font and pixelSize support (#2020)

refactored pxTextPaint as pxTextCanvas

Updates to pxTextCanvas, width() support

function stubs for the functions used in Lightning

updated pxTextCanvas with all props and method stubs for Lightning++. Includes the test script

moved some method definitions from pxTextCanvas.h to pxTextCanvas.cpp

moved some method definitions from pxFont.h to pxFont.cpp

fillStyle() now accepts ARGB color notation; fixed a crash when getting shadowBlur value

new property: label

Fixes

canvas size quick fix
translate property
removed shadow/hightlighting from pxTextCanvas (now dervied from pxText)
removed excessive debug info (almost)

debug info

* fix leaks (#2017)

* gl cleanup on pxWebGL destroy

* gl.delete fucntions support

* clean up memory when initGL destroys, remove hacks

* clean up global when initGL destroys

* clean bootStrapCache (leak), fix accidential global variables, delete all from sandbox

* remove old code

* change log level

* do not keep duplicate ids

* delete unique elements with std::find

* fix a leak in pxContextGL

* clean renderbuffer

* Fix for text displacement on pxTextCanvas (#2021)

* export lightning app exports via api; allow create bootstrap apps w/o options (#2025)

* video support (#2027)

* an object to support video playback (#1816)

* fix for black screen on mojave

* Video Support (#2024)

* XRE2-2164: Intergrate AAMP & depending libraries

Reason for change:  AAMP player & depending libraries required to make AAMP as the primary player of Spark
Test Procedure: Make sure that building the Spark for Linux & Mac & make contains the necessary libraries of AAMP
Risks: Low

Signed-off-by: Vinod Damodaran <vinod_damodaran@comcast.com>

* XRE2-2099: Support AAMP playback on SPARK

Reason for change: Added AAMP support in SPARK.
Test Procedure: Play js script with scene type 'video'
Risks: Medium

Signed-off-by: Vinod Damodaran <vinod_damodaran@comcast.com>

* build.sh updates

* Add URL Query Parameters to Options for Lightning Apps (#2023)

* fix for hangs (#2018)

* fix for hangs

* Update pxScene2d.cpp

* Update pxScene2d.cpp

* Update pxScene2d.cpp

* adding missing license headers (#2029)

* support file: URLs and relative to them (#2030)

* support file:, http URLs and relative to them

* fix ci scripts...

* disabling passing parameters into options (#2037)

* fix Error: Cannot find module 'ws' (#2039)

* pxTextCanvas improvements (#2038)

pxTextCanvas textAlignment and textBaseline support.
Allowed negative x and y coords in fillText() and fillRect().
Clipping is on by default to resemple HTML Canvas.
globalAlpha property

* adding a default api object for gl apps (#2040)

* disabling passing parameters into options

* adding a default api object for gl apps

* adding a default api object for gl apps

* test with remote externals (#2041)

* test with built externals

* test with built externals

* cleanups

* cleanups

* Webgl on windows (#2028)

* updated readme

* linked openssl lib

* linked openssl lib

* switch to loadArchive in initGL to enable caching (#2045)

* use externals artifacts from remote (#2049)

* new change test

* new change test

* Update .travis.yml

* Update .travis.yml

* Test

* Test

* Test

* Test

* Test

* Tt

* Tt

* Tt

* few updates

* few updates

* Update .travis.yml

* Update .travis.yml

* Update after_script.sh

* Update after_script.sh

* Update build_linux.sh

* Update tests.json

* Update .travis.yml

* Remove jpeg dylib

* Avoid printing logs on success execution

* Update execute_linux.sh

* Update tests.json

* Few updates

* fix cron failures for osx (#2052)

* Update build_osx.sh

* Update .travis.yml

* Update build_osx.sh

* Update build_osx.sh

* Update build_osx.sh

* Added support for byte range curl download(RDK-24363). (#1939) (#2055)

* Added support for byyte range curl download(RDK-24363).

* Added byte curl download support.

Added trim, toString methods in rtString.

* Added byte curl download support.

Added trim, toString methods in rtString.

* Added byte curl download support.

Added trim, toString methods in rtString.

* Added byte curl download support.

Added trim, toString methods in rtString.

* pxTextCanvas: support for CutSx, CutSy, CutEx, CutEy, fontStyle in Lightning++ (#2048)

* pxTextCanvas: support for CutSx, CutSy, CutEx, CutEy props in Lightning++

* fontStyle support for pxFont; fixed a Windows build issue

* Windows compatibility fixes

* One more Windows compatibility fix

* fontStyle coercion in pxFont

* Refactored for better backward compatibility; improved coercion detection

* Revert "pxTextCanvas: support for CutSx, CutSy, CutEx, CutEy, fontStyle in Lightning++ (#2048)" (#2057)

This reverts commit 4d93600.

* Revert "Revert "pxTextCanvas: support for CutSx, CutSy, CutEx, CutEy, fontStyle in Lightning++ (#2048)" (#2057)" (#2058)

This reverts commit 4b8cba2.

* Yet another backward compatibility fix and (again) improved coercion … (#2059)

* Yet another backward compatibility fix and (again) improved coercion detection

* fontStyle support for downloaded fonts

* Moved a comment to the appropriate place

* gzip for rtHttpRequest (#2056)

* Improve Spark fetch performance

* don't update node-fetch to 2.6.0 (same speed)

* pass sparkHttp like other webgl functions

* make compression default

* Added user configurable curl options (#2031)

* Mutex lock/unlock is not required during reaching from cache. (#2043)

* remove one line

* updates for edge builds

* more edge build updates

* updates

* updates for node

* prevent promise rejection on download processing (#2061)

* prevent promise rejection on download processing

* Update pxResource.h

* Update pxResource.h

* build updates

* build updates

* update to tests

* build script updates

* build script updates

* build script updates

* install script updates

* pick changes from revert a4a55d9 (#20)

* pick http_wrap.js from _webgl branch

* changes for switching to node6.9.0 (#1867)

* changes for switching to node6.9.0

* changes for switching to node6.9.0

* Update http_wrap.js

* Update http_wrap.js

* pick changes from revert a4a55d9

* pick changes from revert a4a55d9

* pick changes from revert a4a55d9

* pick changes from revert a4a55d9

* pick changes from revert a4a55d9

* pick changes from revert a4a55d9

* pick changes from revert a4a55d9

* pick changes from revert a4a55d9

* pick changes from revert a4a55d9

* pick changes from revert a4a55d9

* pick changes from revert a4a55d9

* pick changes from revert a4a55d9

* pick changes from revert a4a55d9

* pick changes from revert a4a55d9

* pick changes from revert a4a55d9

* pick changes from revert a4a55d9

* fix for mac unittests gif failure (#19)

* gif build error debug

* gif build error debug

* Update tests.json

* set external gif preference to off by default

* ensure a safe copy is given to javascript

* cleanup

* updates

* copy support

* Windows build fixes
  • Loading branch information
mfiess committed Oct 15, 2019
1 parent cce9ba8 commit a9ccf7a
Show file tree
Hide file tree
Showing 17,794 changed files with 6,008,946 additions and 919 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
22 changes: 22 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -176,3 +176,25 @@ examples/pxScene2d/external/libpng-1.6.28/timepng
tests/pxScene2d/Makefile

remote/js/node_modules
examples/pxScene2d/external/spark-webgl/build
.vscode/
examples/pxScene2d/external/zlib-1.2.11/Makefile
examples/pxScene2d/external/zlib-1.2.11/zconf.h

examples/pxScene2d/external/freetype-2.8.1/builds/unix/config.log
examples/pxScene2d/external/freetype-2.8.1/config.mk
examples/pxScene2d/external/freetype-2.8.1/builds/unix/config.status
examples/pxScene2d/external/freetype-2.8.1/builds/unix/ftconfig.h
examples/pxScene2d/external/freetype-2.8.1/builds/unix/libtool
examples/pxScene2d/external/freetype-2.8.1/builds/unix/unix-cc.mk
examples/pxScene2d/external/freetype-2.8.1/builds/unix/unix-def.mk
examples/pxScene2d/external/freetype-2.8.1/objs/ftmodule.h
examples/pxScene2d/external/spark-webgl/node_modules/
examples/pxScene2d/pxScene2d.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist
examples/pxScene2d/external/zlib-1.2.11/Makefile
examples/pxScene2d/external/zlib-1.2.11/example
examples/pxScene2d/external/zlib-1.2.11/examplesh
examples/pxScene2d/external/zlib-1.2.11/minigzip
examples/pxScene2d/external/zlib-1.2.11/minigzipsh
examples/pxScene2d/external/zlib-1.2.11/zconf.h
examples/pxScene2d/external/extlibs
1 change: 0 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ before_install:
install:
- ./ci/install.sh
before_script:
- if ( [ "$TRAVIS_EVENT_TYPE" = "push" ] || [ "$TRAVIS_EVENT_TYPE" = "pull_request" ] ) && [ -z "${TRAVIS_TAG}" ] ; then ccache -s; fi
- ./ci/before_script.sh
- if [ "$TRAVIS_EVENT_TYPE" = "api" ] || [ ! -z "${TRAVIS_TAG}" ] ; then export linenumber=`awk '/CFBundleShortVersionString/{ print NR; exit }' $TRAVIS_BUILD_DIR/examples/pxScene2d/src/macstuff/Info.plist`;export PX_VERSION=`sed -n "\`echo $((linenumber+1))\`p" $TRAVIS_BUILD_DIR/examples/pxScene2d/src/macstuff/Info.plist|awk -F '<string>' '{print $2}'|awk -F'</string>' '{print $1}'`; fi
- if [ "$TRAVIS_EVENT_TYPE" = "cron" ] ; then export PX_VERSION=edge_`date +%Y-%m-%d` ; fi
Expand Down
6 changes: 6 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ option(BUILD_PXSCENE "BUILD_PXSCENE" ON)
option(BUILD_PX_TESTS "BUILD_PX_TESTS" OFF)
option(BUILD_PXBENCHMARK "BUILD_PXBENCHMARK" OFF)
option(BUILD_WITH_GIF "BUILD_WITH_GIF" ON)
option(PREFER_EXTERNAL_GIF "PREFER_EXTERNAL_GIF" OFF)

option(PREFER_SYSTEM_LIBRARIES "Prefer to use system libraries over bundled." "OFF")
# Fine selection of which external node package to pick-up, if multiple are installed on the system
Expand All @@ -17,6 +18,7 @@ option(DISABLE_DEBUG_MODE "Disable debugging mode." "OFF") # OFF for backward co
option(SUPPORT_NODE "SUPPORT_NODE" ON)
option(SUPPORT_V8 "SUPPORT_V8" OFF)
option(SUPPORT_DUKTAPE "SUPPORT_DUKTAPE" ON)
option(USE_NODE_10 "USE_NODE_10" ON)

option(SUPPORT_STORAGE "SUPPORT_STORAGE" ON)
option(ENABLE_SQLITE_ENCRYPTION_EXTENSION "Toggle SQLite encryption extension support" OFF)
Expand Down Expand Up @@ -60,3 +62,7 @@ if (BUILD_PXBENCHMARK)
message("Building pxbenchmark")
add_subdirectory(examples/pxBenchmark/src)
endif (BUILD_PXBENCHMARK)

if (APPLE)
add_definitions(-DGL_SILENCE_DEPRECATION)
endif (APPLE)
8 changes: 7 additions & 1 deletion ci/after_script.sh
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ then
checkError $? "unable to move artifacts folder to release directory" "artifacts directory created" "Retry"
tar -cvzf release.tgz release/*
checkError $? "unable to compress release folder" "release folder present?" "Retry"
if [ "$TRAVIS_REPO_SLUG" = "pxscene/pxCore" ] && ( [ "$TRAVIS_BRANCH" = "master" ] || [ "$TRAVIS_BRANCH" = "$TRAVIS_TAG" ] );
if [ "$TRAVIS_REPO_SLUG" = "pxscene/pxCore" ] && ( [ "$TRAVIS_BRANCH" = "master" ] || [ "$TRAVIS_BRANCH" = "_webgl" ] || [ "$TRAVIS_BRANCH" = "$TRAVIS_TAG" ] );
then
./ci/release_osx.sh 96.116.56.119 release.tgz
checkError $? "unable to send artifacts to 96.116.56.119" "96.116.56.119 down?" "Retry"
Expand Down Expand Up @@ -81,3 +81,9 @@ then
git push --repo="https://$REPO_USER_NAME:$GH_TOKEN@github.com/$REPO_USER_NAME/$REPO_NAME.git"
checkError $? "unable to commit data to repo" "" "check the credentials"
fi

cd $TRAVIS_BUILD_DIR
cd ..
rm -rf Spark-Externals
rm -rf rlExternals
cd $TRAVIS_BUILD_DIR
34 changes: 32 additions & 2 deletions ci/before_install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -56,9 +56,12 @@ if [ "$TRAVIS_OS_NAME" = "osx" ] ;
then
brew update;
#brew upgrade cmake;
brew install yasm bison flex python
ln -sf /usr/local/opt/bison/bin/bison /usr/local/bin/bison
brew install quilt
brew install libuv
brew install xmlto
brew install pkg-config glfw3 glew
sudo /usr/sbin/DevToolsSecurity --enable
lldb --version
lldb --help
Expand All @@ -74,8 +77,6 @@ then
# brew install lighttpd
brew install gcovr
brew install lcov
brew install ccache
ls -al $HOME/.ccache
fi
fi

Expand Down Expand Up @@ -132,3 +133,32 @@ then
fi
sudo pip install codecov
fi

#setup spark externals repo
SRC_REPO_USER_NAME='pxscene'
DEST_REPO_USER_NAME=`echo $TRAVIS_REPO_SLUG | cut -d'/' -f 1`
cd $TRAVIS_BUILD_DIR
cd ../
mkdir rlExternals
cd rlExternals
git clone --branch=master https://github.com/$SRC_REPO_USER_NAME/Spark-Externals.git
cd Spark-Externals
if [ "$TRAVIS_OS_NAME" = "osx" ]; then
sed -i -n "s/$SRC_REPO_USER_NAME/$DEST_REPO_USER_NAME/g" artifacts/$TRAVIS_OS_NAME/lib/pkgconfig/*
else
sed -i "s/$SRC_REPO_USER_NAME/$DEST_REPO_USER_NAME/g" artifacts/$TRAVIS_OS_NAME/lib/pkgconfig/*
fi
ln -sf artifacts/$TRAVIS_OS_NAME extlibs
cd extlibs
mkdir lib_orig
cp -R lib/* lib_orig/.
if [ "$TRAVIS_OS_NAME" = "osx" ]; then
rm -rf lib_orig/libgif.7.dylib
rm -rf lib_orig/libpng.dylib
rm -rf lib_orig/libsqlite3.dylib
rm -rf lib_orig/libjpeg.dylib
fi
cd $TRAVIS_BUILD_DIR
cd ..
ln -sf rlExternals/Spark-Externals Spark-Externals
cd $TRAVIS_BUILD_DIR
6 changes: 3 additions & 3 deletions ci/build_linux.sh
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,11 @@ export CODE_COVERAGE=1
cd $TRAVIS_BUILD_DIR
mkdir -p temp
cd temp

export PKG_CONFIG_PATH=$TRAVIS_BUILD_DIR/examples/pxScene2d/external/extlibs/lib/pkgconfig:$PKG_CONFIG_PATH
if [ "$TRAVIS_PULL_REQUEST" = "false" ]
then
echo "************************* Generating config files *************************" >> $BUILDLOGS
cmake -DBUILD_PX_TESTS=ON -DBUILD_PXSCENE_STATIC_LIB=ON -DBUILD_DEBUG_METRICS=ON -DPXSCENE_TEST_HTTP_CACHE=ON .. >>$BUILDLOGS 2>&1;
cmake -DPREFER_SYSTEM_LIBRARIES=ON -DPREFER_PKGCONFIG=ON -DPREFER_EXTERNAL_GIF=ON -DSPARK_ENABLE_VIDEO=ON -DBUILD_PX_TESTS=ON -DBUILD_PXSCENE_STATIC_LIB=ON -DBUILD_DEBUG_METRICS=ON -DPXSCENE_TEST_HTTP_CACHE=ON .. >>$BUILDLOGS 2>&1;
checkError $? "cmake config failed" "Config error" "Check the error in $BUILDLOGS"

echo "************************* Building pxcore,rtcore,pxscene app,libpxscene, unitttests ****" >> $BUILDLOGS
Expand All @@ -36,7 +36,7 @@ then

else
echo "************************* Generating config files ****"
cmake -DBUILD_PX_TESTS=ON -DBUILD_PXSCENE_STATIC_LIB=ON -DBUILD_DEBUG_METRICS=ON -DPXSCENE_TEST_HTTP_CACHE=ON .. 1>>$BUILDLOGS;
cmake -DPREFER_SYSTEM_LIBRARIES=ON -DPREFER_PKGCONFIG=ON -DPREFER_EXTERNAL_GIF=ON -DSPARK_ENABLE_VIDEO=ON -DBUILD_PX_TESTS=ON -DBUILD_PXSCENE_STATIC_LIB=ON -DBUILD_DEBUG_METRICS=ON -DPXSCENE_TEST_HTTP_CACHE=ON .. 1>>$BUILDLOGS;
checkError $? "cmake config failed" "Config error" "Check the errors displayed in this window"

echo "************************* Building pxcore,rtcore,pxscene app,libpxscene, unitttests ********"
Expand Down
8 changes: 4 additions & 4 deletions ci/build_osx.sh
Original file line number Diff line number Diff line change
Expand Up @@ -40,21 +40,21 @@ fi
cd $TRAVIS_BUILD_DIR;
mkdir -p temp
cd temp

export PKG_CONFIG_PATH=$TRAVIS_BUILD_DIR/examples/pxScene2d/external/extlibs/lib/pkgconfig:$PKG_CONFIG_PATH
if [ "$TRAVIS_PULL_REQUEST" = "false" ]
then
echo "***************************** Generating config files ****" >> $BUILDLOGS
if [ "$TRAVIS_EVENT_TYPE" != "cron" ] && [ "$TRAVIS_EVENT_TYPE" != "api" ] && [ -z "${TRAVIS_TAG}" ]
then
cmake -DBUILD_PX_TESTS=ON -DBUILD_PXSCENE_STATIC_LIB=ON -DBUILD_DEBUG_METRICS=ON -DPXSCENE_TEST_HTTP_CACHE=ON -DENABLE_THREAD_SANITIZER=ON .. >>$BUILDLOGS 2>&1;
cmake -DPREFER_SYSTEM_LIBRARIES=ON -DPREFER_PKGCONFIG=ON -DPREFER_EXTERNAL_GIF=ON -DSPARK_ENABLE_VIDEO=ON -DBUILD_PX_TESTS=ON -DBUILD_PXSCENE_STATIC_LIB=ON -DBUILD_DEBUG_METRICS=ON -DPXSCENE_TEST_HTTP_CACHE=ON -DENABLE_THREAD_SANITIZER=ON .. >>$BUILDLOGS 2>&1;
else
if [ "$TRAVIS_EVENT_TYPE" == "cron" ] ;
then
cp ../examples/pxScene2d/src/macstuff/Resources/SparkEdge.icns ../examples/pxScene2d/src/macstuff/Resources/pxscene.icns
cp ../examples/pxScene2d/src/macstuff/Resources/SparkEdge.icns ../examples/pxScene2d/src/macstuff/Resources/AppIcon.icns
cp ../examples/pxScene2d/src/macstuff/Resources/SparkEdge.icns ../examples/pxScene2d/src/macstuff/dmgresources/pxscene.icns

cmake -DSUPPORT_DUKTAPE=OFF -DPXSCENE_VERSION=edge_`date +%Y-%m-%d` .. >>$BUILDLOGS 2>&1;
cmake -DPREFER_SYSTEM_LIBRARIES=ON -DPREFER_PKGCONFIG=ON -DPREFER_EXTERNAL_GIF=ON -DSPARK_ENABLE_VIDEO=ON -DSUPPORT_DUKTAPE=OFF -DPXSCENE_VERSION=edge_`date +%Y-%m-%d` .. >>$BUILDLOGS 2>&1;
else
cmake -DSUPPORT_DUKTAPE=OFF .. >>$BUILDLOGS 2>&1;
fi
Expand All @@ -69,7 +69,7 @@ then
else

echo "***************************** Generating config files ****"
cmake -DBUILD_PX_TESTS=ON -DBUILD_PXSCENE_STATIC_LIB=ON -DBUILD_DEBUG_METRICS=OFF -DPXSCENE_TEST_HTTP_CACHE=ON -DENABLE_THREAD_SANITIZER=ON .. 1>>$BUILDLOGS;
cmake -DPREFER_SYSTEM_LIBRARIES=ON -DPREFER_PKGCONFIG=ON -DPREFER_EXTERNAL_GIF=ON -DSPARK_ENABLE_VIDEO=ON -DBUILD_PX_TESTS=ON -DBUILD_PXSCENE_STATIC_LIB=ON -DBUILD_DEBUG_METRICS=OFF -DPXSCENE_TEST_HTTP_CACHE=ON -DENABLE_THREAD_SANITIZER=ON .. 1>>$BUILDLOGS;
checkError $? 1 "cmake config failed" "Config error" "Check the errors displayed in this window"

echo "***************************** Building pxcore,rtcore,pxscene app,libpxscene,unitttests ****" >> $BUILDLOGS
Expand Down
1 change: 0 additions & 1 deletion ci/build_px.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
#This script is changed to accomodate running multiple scripts
#!/bin/sh
export CCACHE_DISABLE=true
retval=0
for var in "$@"
do
Expand Down
10 changes: 5 additions & 5 deletions ci/execute_linux.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#!/bin/sh

EXECLOGS=$TRAVIS_BUILD_DIR/logs/exec_logs
checkError()
{
if [ "$1" -ne 0 ]
Expand All @@ -11,7 +12,8 @@ checkError()
printf "\nReproduction/How to fix: $4"
printf "\n*******************************************************************";
printf "\n*******************************************************************\n\n";
#exit 1;
cat $EXECLOGS
exit 1;
fi
}

Expand Down Expand Up @@ -41,9 +43,8 @@ export SUPPRESSIONS=$TRAVIS_BUILD_DIR/ci/leak.supp
export SPARK_ENABLE_COLLECT_GARBAGE=1

touch $VALGRINDLOGS
EXECLOGS=$TRAVIS_BUILD_DIR/logs/exec_logs
TESTRUNNERURL="https://www.sparkui.org/tests-ci/test-run/testRunner.js"
TESTS="file://$TRAVIS_BUILD_DIR/tests/pxScene2d/testRunner/testsDesktop.json,file://$TRAVIS_BUILD_DIR/tests/pxScene2d/testRunner/tests.json"
TESTS="file://$TRAVIS_BUILD_DIR/tests/pxScene2d/testRunner/tests.json"

# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
printExecLogs()
Expand Down Expand Up @@ -75,7 +76,7 @@ count=0
#adding spark log a part of console.log increase execution time in linux in ci
#in linux we have timeouts, so increasing the limit
max_seconds=2300
while [ "$retVal" -ne 0 ] && [ "$count" -ne "$max_seconds" ]; do
while [ "$retVal" -ne 0 ] && [ "$count" -le "$max_seconds" ]; do
printf "\n [execute_linux.sh] snoozing for 30 seconds (%d of %d) \n" $count $max_seconds
sleep 30; # seconds
grep "TEST RESULTS: " $EXECLOGS
Expand All @@ -88,7 +89,6 @@ while [ "$retVal" -ne 0 ] && [ "$count" -ne "$max_seconds" ]; do
retVal=$?
fi
done

ls -lrt /tmp/pxscenecrash
retVal=$?
if [ "$retVal" -eq 0 ]
Expand Down
6 changes: 4 additions & 2 deletions ci/generate_cache_install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,16 @@ travis_retry() {
if [ "$TRAVIS_OS_NAME" = "linux" ] ;
then
travis_retry sudo apt-get update
travis_retry sudo apt-get install git libglew-dev freeglut3 freeglut3-dev libgcrypt11-dev zlib1g-dev g++ libssl-dev nasm autoconf libyaml-dev cmake gdb quilt libuv-dev xmlto
travis_retry sudo apt-get install git libglew-dev freeglut3 freeglut3-dev libgcrypt11-dev zlib1g-dev g++ nasm autoconf libyaml-dev cmake gdb quilt libuv-dev xmlto
fi

if [ "$TRAVIS_OS_NAME" = "osx" ] ;
then
brew update;
brew install yasm bison flex python
ln -sf /usr/local/opt/bison/bin/bison /usr/local/bin/bison
brew upgrade cmake;
brew install quilt libuv xmlto;
brew install quilt libuv xmlto pkg-config glfw3 glew;
sudo /usr/sbin/DevToolsSecurity --enable
fi

Expand Down
2 changes: 1 addition & 1 deletion ci/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,6 @@ fi

echo "******************** Building externals ********************" > $BUILDLOGS
cd $TRAVIS_BUILD_DIR/examples/pxScene2d/external
./build.sh>>$BUILDLOGS
./build_release.sh --release-externals-path $TRAVIS_BUILD_DIR/../rlExternals/Spark-Externals>>$BUILDLOGS
checkError $? "building externals failed" "compilation error" "Need to build the externals directory locally in $TRAVIS_OS_NAME"
exit 0;
39 changes: 39 additions & 0 deletions ci/leak.supp
Original file line number Diff line number Diff line change
Expand Up @@ -235,3 +235,42 @@
fun:_ZN9pxScene2d8onUpdateEd
fun:_ZN12pxScriptView8onUpdateEd
}
{
rtScriptNodeDtorNeverCalled
Memcheck:Leak
match-leak-kinds: definite
fun:calloc
fun:allocate_dtv
fun:_dl_allocate_tls
fun:allocate_stack
fun:pthread_create@@GLIBC_2.2.5
fun:uv_thread_create
fun:_ZN4node12NodePlatformC1EiPN2v817TracingControllerE
fun:_ZN4node14CreatePlatformEiPN2v817TracingControllerE
fun:_ZN12rtScriptNode5init2Ev
fun:_ZN12rtScriptNode4initEv
fun:_ZN8rtScript4initEv
fun:_Z6pxMainiPPc
fun:main
}
{
gcSweeperLeak
Memcheck:Leak
match-leak-kinds: definite
fun:_Znwm
fun:_ZN2v88internal7Sweeper31ScheduleIncrementalSweepingTaskEv
fun:_ZN2v88internal7Sweeper17StartSweeperTasksEv
fun:_ZN2v88internal20MarkCompactCollector6FinishEv
fun:_ZN2v88internal20MarkCompactCollector14CollectGarbageEv
fun:_ZN2v88internal4Heap11MarkCompactEv
fun:_ZN2v88internal4Heap24PerformGarbageCollectionENS0_16GarbageCollectorENS_15GCCallbackFlagsE
fun:_ZN2v88internal4Heap14CollectGarbageENS0_15AllocationSpaceENS0_23GarbageCollectionReasonENS_15GCCallbackFlagsE
fun:_ZN2v88internal4Heap26CollectAllAvailableGarbageENS0_23GarbageCollectionReasonE
fun:_ZN2v815SnapshotCreator10CreateBlobENS0_20FunctionCodeHandlingE
fun:_ZN2v82V822CreateSnapshotDataBlobEPKc
fun:_ZN12rtScriptNode5init2Ev
fun:_ZN12rtScriptNode4initEv
fun:_ZN8rtScript4initEv
fun:_Z6pxMainiPPc
fun:main
}
5 changes: 5 additions & 0 deletions ci/release_osx.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,12 @@ if [ "$TRAVIS_EVENT_TYPE" != "cron" ]
then
export DEPLOY_DESTINATION=${DEPLOY_DESTINATION:-/var/www/html/releases}
else
if [ "$TRAVIS_BRANCH" = "master" ]
then
export DEPLOY_DESTINATION=${DEPLOY_DESTINATION:-/var/www/html/edge/osx}
else
export DEPLOY_DESTINATION=${DEPLOY_DESTINATION:-/var/www/html/edge_webgl/osx}
fi
fi
export DEPLOY_USER="${DEPLOY_USER:-ubuntu}"
REMOTE_HOST="$1"
Expand Down
2 changes: 1 addition & 1 deletion ci/unittests_osx.sh
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ then
cat $TESTLOGS
echo "************************** LOG ENDS *******************************"
else
errCause="Either one or more tests failed. Check the log file $TESTLOGS"
errCause="Failed Test. Either one or more tests failed. Check the log file $TESTLOGS"
fi
checkError -1 "unittests execution failed" "$errCause" "Run unittests locally"
else
Expand Down
Loading

0 comments on commit a9ccf7a

Please sign in to comment.