Skip to content

Commit

Permalink
Merge branch 'develop'. We're now at RmlUi 3.0!
Browse files Browse the repository at this point in the history
# Conflicts:
#	readme.md
  • Loading branch information
mikke89 committed Oct 13, 2019
2 parents b4be495 + c653be4 commit c7fb5df
Show file tree
Hide file tree
Showing 661 changed files with 29,109 additions and 29,858 deletions.
49 changes: 25 additions & 24 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,25 +1,17 @@
sudo: false
dist: trusty
dist: bionic
language: c++

matrix:
include:
- os: osx
osx_image: xcode10.2
env: ARCH=OSX
language: c++
osx_image: xcode10.3
compiler: clang
- os: linux
language: c++
compiler: clang
env: MATRIX_EVAL="CC=clang-6.0 CXX=clang++-6.0"
addons:
apt:
sources:
- ubuntu-toolchain-r-test
- llvm-toolchain-trusty-6.0
packages:
- clang-6.0
- libstdc++-7-dev
- cmake
- build-essential
- libsdl2-dev
Expand All @@ -29,15 +21,27 @@ matrix:
- liblua5.2-dev
- libsfml-dev
- os: linux
language: c++
compiler: clang
env: NO_FONT_INTERFACE_DEFAULT="ON"
addons:
apt:
packages:
- cmake
- build-essential
- libsdl2-dev
- libsdl2-image-dev
- libfreetype6-dev
- libglew-dev
- liblua5.2-dev
- libsfml-dev
- os: linux
compiler: gcc
env: MATRIX_EVAL="CC=gcc-7 CXX=g++-7" VALGRIND_SAMPLES="1"
env: VALGRIND_SAMPLES="1"
services:
- xvfb
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- g++-7
- cmake
- build-essential
- libsdl2-dev
Expand All @@ -49,20 +53,17 @@ matrix:
- mesa-utils
- valgrind

before_install:
- if [[ -n "${MATRIX_EVAL}" ]]; then eval "${MATRIX_EVAL}" ; fi

install:
- cd "$TRAVIS_BUILD_DIR"
- if [[ "$TRAVIS_OS_NAME" != "osx" ]]; then cmake -DBUILD_LUA_BINDINGS=ON -DBUILD_SAMPLES=ON .; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then cmake -G Xcode .; fi
- if [[ "$TRAVIS_OS_NAME" != "osx" ]]; then cmake -DBUILD_LUA_BINDINGS=ON -DBUILD_SAMPLES=ON -DNO_FONT_INTERFACE_DEFAULT=${NO_FONT_INTERFACE_DEFAULT:-OFF} .; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then cmake -DNO_THIRDPARTY_CONTAINERS=ON -G Xcode .; fi

before_script:
- if [[ "$VALGRIND_SAMPLES" == "1" ]] && [[ "$TRAVIS_OS_NAME" == "linux" ]]; then export DISPLAY=:99.0 && sh -e /etc/init.d/xvfb start && sleep 3; fi
- if [[ "$VALGRIND_SAMPLES" == "1" ]] && [[ "$TRAVIS_OS_NAME" == "linux" ]]; then export DISPLAY=:99.0; fi

script:
- if [[ "$TRAVIS_OS_NAME" != "osx" ]]; then make -j4; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then xcodebuild -project rmlui.xcodeproj/ -jobs 4 -configuration Release -target ALL_BUILD; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then xcodebuild -project rmlui.xcodeproj/ -jobs 4 -configuration Release -scheme ALL_BUILD | xcpretty --color; test ${PIPESTATUS[0]} -eq 0; fi
- if [[ "$VALGRIND_SAMPLES" == "1" ]]; then mkdir build && make DESTDIR=build install; fi
- |
if [[ "$VALGRIND_SAMPLES" == "1" ]]; then
Expand All @@ -72,7 +73,7 @@ script:
cd `dirname $f`
sample=$(basename $f)
printf "\033[0;36m$sample\033[0m\n"
LD_LIBRARY_PATH=$TRAVIS_BUILD_DIR/build/usr/local/lib timeout --preserve-status --signal=TERM --kill-after=15 10 valgrind --leak-check=full --suppressions=$TRAVIS_BUILD_DIR/.travis.valgrind.supp --error-exitcode=1 --log-fd=1 ./$sample >>$vout
LD_LIBRARY_PATH=$TRAVIS_BUILD_DIR/build/usr/local/lib timeout --preserve-status --signal=TERM --kill-after=15 10 valgrind --leak-check=full --track-origins=yes --suppressions=$TRAVIS_BUILD_DIR/.travis.valgrind.supp --error-exitcode=1 --log-fd=1 ./$sample >>$vout
cnt=$((cnt+1))
done;
Expand Down
130 changes: 57 additions & 73 deletions Cmake/FileList.cmake → CMake/FileList.cmake

Large diffs are not rendered by default.

File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
46 changes: 32 additions & 14 deletions Cmake/SampleFileList.cmake → CMake/SampleFileList.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,31 @@ set(shell_SRC_FILES
${PROJECT_SOURCE_DIR}/Samples/shell/src/ShellSystemInterface.cpp
)

set(animation_HDR_FILES
)

set(animation_SRC_FILES
${PROJECT_SOURCE_DIR}/Samples/basic/animation/src/main.cpp
)

set(benchmark_HDR_FILES
)

set(benchmark_SRC_FILES
${PROJECT_SOURCE_DIR}/Samples/basic/benchmark/src/main.cpp
)

set(bitmapfont_HDR_FILES
${PROJECT_SOURCE_DIR}/Samples/basic/bitmapfont/src/FontEngineBitmap.h
${PROJECT_SOURCE_DIR}/Samples/basic/bitmapfont/src/FontEngineInterfaceBitmap.h
)

set(bitmapfont_SRC_FILES
${PROJECT_SOURCE_DIR}/Samples/basic/bitmapfont/src/FontEngineBitmap.cpp
${PROJECT_SOURCE_DIR}/Samples/basic/bitmapfont/src/FontEngineInterfaceBitmap.cpp
${PROJECT_SOURCE_DIR}/Samples/basic/bitmapfont/src/main.cpp
)

set(customlog_HDR_FILES
${PROJECT_SOURCE_DIR}/Samples/basic/customlog/src/SystemInterface.h
)
Expand All @@ -27,6 +52,13 @@ set(customlog_SRC_FILES
${PROJECT_SOURCE_DIR}/Samples/basic/customlog/src/SystemInterface.cpp
)

set(demo_HDR_FILES
)

set(demo_SRC_FILES
${PROJECT_SOURCE_DIR}/Samples/basic/demo/src/main.cpp
)

set(drag_HDR_FILES
${PROJECT_SOURCE_DIR}/Samples/basic/drag/src/DragListener.h
${PROJECT_SOURCE_DIR}/Samples/basic/drag/src/Inventory.h
Expand All @@ -45,13 +77,6 @@ set(loaddocument_SRC_FILES
${PROJECT_SOURCE_DIR}/Samples/basic/loaddocument/src/main.cpp
)

set(bitmapfont_HDR_FILES
)

set(bitmapfont_SRC_FILES
${PROJECT_SOURCE_DIR}/Samples/basic/bitmapfont/src/main.cpp
)

set(treeview_HDR_FILES
${PROJECT_SOURCE_DIR}/Samples/basic/treeview/src/FileFormatter.h
${PROJECT_SOURCE_DIR}/Samples/basic/treeview/src/FileSystem.h
Expand All @@ -70,13 +95,6 @@ set(transform_SRC_FILES
${PROJECT_SOURCE_DIR}/Samples/basic/transform/src/main.cpp
)

set(animation_HDR_FILES
)

set(animation_SRC_FILES
${PROJECT_SOURCE_DIR}/Samples/basic/animation/src/main.cpp
)

set(sdl2_HDR_FILES
${PROJECT_SOURCE_DIR}/Samples/basic/sdl2/src/RenderInterfaceSDL2.h
${PROJECT_SOURCE_DIR}/Samples/basic/sdl2/src/SystemInterfaceSDL2.h
Expand Down
File renamed without changes.
30 changes: 25 additions & 5 deletions Cmake/gen_filelists.sh → CMake/gen_filelists.sh
Original file line number Diff line number Diff line change
@@ -1,35 +1,53 @@
#!/usr/bin/env bash

basedir="../.."
file=Build/cmake/FileList.cmake
basedir=".."
file=CMake/FileList.cmake
src='set(lib_SRC_FILES'
hdr='set(lib_HDR_FILES'
masterpubhdr='set(MASTER_lib_PUB_HDR_FILES'
pubhdr='set(lib_PUB_HDR_FILES'
srcdir='${PROJECT_SOURCE_DIR}'
fontdefaultbegin='if(NOT NO_FONT_INTERFACE_DEFAULT)'
fontdefaultend='endif()'
srcpath=Source
hdrpath=Include/RmlUi
luapath=Lua
fontdefaultpath=FontEngineDefault

printfiles() {
# Print headers
echo ${hdr/lib/$1} >>$file
find $srcpath/$1 -maxdepth 1 -iname "*.h" -exec echo ' '$srcdir/{} \; 2>/dev/null | sort -f >>$file
find $srcpath/$1 -maxdepth 3 -path */$luapath -prune -o -path */$fontdefaultpath -prune -o \( -iname "*.h" -o -iname "*.hpp" \) -exec echo ' '$srcdir/{} \; 2>/dev/null | sort -f >>$file
echo -e ')\n' >>$file
# Print master header for library
echo ${masterpubhdr/lib/$1} >>$file
echo ' '$srcdir/Include/RmlUi/$1.h >>$file
echo -e ')\n' >>$file
# Print public headers sub directory
echo ${pubhdr/lib/$1} >>$file
find $hdrpath/$1 -maxdepth 1 \( -iname "*.h" -o -iname "*.inl" \) -exec echo ' '$srcdir/{} \; 2>/dev/null | sort -f >>$file
find $hdrpath/$1 -maxdepth 3 -path */$luapath -prune -o -path */$fontdefaultpath -prune -o \( -iname "*.h" -o -iname "*.inl" -o -iname "*.hpp" \) -exec echo ' '$srcdir/{} \; 2>/dev/null | sort -f >>$file
echo -e ')\n' >>$file
# Print source files
echo ${src/lib/$1} >>$file
find $srcpath/$1 -maxdepth 1 -iname "*.cpp" -exec echo ' '$srcdir/{} \; 2>/dev/null | sort -f >>$file
find $srcpath/$1 -maxdepth 3 -path */$luapath -prune -o -path */$fontdefaultpath -prune -o -iname "*.cpp" -exec echo ' '$srcdir/{} \; 2>/dev/null | sort -f >>$file
echo -e ')\n' >>$file
}

printfontdefaultfiles() {
# Print headers
echo $fontdefaultbegin >>$file
echo ' '${hdr/lib/$1} >>$file
echo ' ${'$1'_HDR_FILES}' >>$file
find $srcpath/$1/$fontdefaultpath -iname "*.h" -exec echo ' '$srcdir/{} \; 2>/dev/null | sort -f >>$file
echo -e ' )\n' >>$file
# Print source files
echo ' '${src/lib/$1} >>$file
echo ' ${'$1'_SRC_FILES}' >>$file
find $srcpath/$1/$fontdefaultpath -iname "*.cpp" -exec echo ' '$srcdir/{} \; 2>/dev/null | sort -f >>$file
echo -e ' )' >>$file
echo -e $fontdefaultend'\n' >>$file
}

printluafiles() {
# Print headers
echo ${hdr/lib/Lua${1}} >>$file
Expand All @@ -51,6 +69,8 @@ for lib in "Core" "Controls" "Debugger"; do
printfiles $lib
done

printfontdefaultfiles "Core"

for lib in "Core" "Controls"; do
printluafiles $lib
done
Expand Down
10 changes: 5 additions & 5 deletions Cmake/gen_samplelists.sh → CMake/gen_samplelists.sh
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,23 +1,23 @@
#!/usr/bin/env bash

basedir="../.."
file=Build/cmake/SampleFileList.cmake
basedir=".."
file=CMake/SampleFileList.cmake
src='set(sample_SRC_FILES'
hdr='set(sample_HDR_FILES'
srcdir='${PROJECT_SOURCE_DIR}'
srcpath=Samples
samples=( 'shell'
'basic/customlog' 'basic/drag' 'basic/loaddocument' 'basic/treeview' 'basic/transform'
'basic/animation' 'basic/benchmark' 'basic/bitmapfont' 'basic/customlog' 'basic/demo' 'basic/drag' 'basic/loaddocument' 'basic/treeview' 'basic/transform'
'basic/sdl2' 'basic/sfml2'
'basic/directx10'
'tutorial/template' 'tutorial/datagrid' 'tutorial/datagrid_tree' 'tutorial/tutorial_drag'
'tutorial/template' 'tutorial/datagrid' 'tutorial/datagrid_tree' 'tutorial/drag'
'invaders' 'luainvaders'
)

printfiles() {
# Print headers
name=${1//basic\//} #substitute basic/ for nothing
name=${name//tutorial\/} #substitute tutorial/ for nothing
name=${name//tutorial\//tutorial_} #substitute 'tutorial/' for 'tutorial_'
echo ${hdr/sample/$name} >>$file
find $srcpath/$1/src -maxdepth 1 -iname "*.h" -exec echo ' '$srcdir/{} \; 2>/dev/null | sort -f >>$file
find $srcpath/$1/include -maxdepth 1 -iname "*.h" -exec echo ' '$srcdir/{} \; 2>/dev/null | sort -f >>$file 2>/dev/null
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
Loading

0 comments on commit c7fb5df

Please sign in to comment.