diff --git a/build.sh b/build.sh index 9337d58..e5c1ca3 100755 --- a/build.sh +++ b/build.sh @@ -1,5 +1,14 @@ #!/usr/bin/env bash + +ICU_VERSION=59 +QT_VERSION=5.9 + +ICU_URL=http://download.icu-project.org/files/icu4c/${ICU_VERSION}.1/icu4c-${ICU_VERSION}_1-src.tgz +QTBASE_URL=http://download.qt.io/archive/qt/$QT_VERSION/$QT_VERSION.0/submodules/qtbase-opensource-src-$QT_VERSION.0.tar.xz +QTWEBENGINE_URL=http://download.qt.io/archive/qt/$QT_VERSION/$QT_VERSION.0/submodules/qtwebengine-opensource-src-$QT_VERSION.0.tar.xz + + if [[ -z $JOBS ]]; then JOBS=$((`getconf _NPROCESSORS_ONLN` + 1)) fi @@ -16,9 +25,10 @@ function err(){ } +# # ICU +# -ICU_URL=http://download.icu-project.org/files/icu4c/56.1/icu4c-56_1-src.tgz SRC_DIR=`pwd`/deps/icu OUT_DIR=`pwd`/build/icu @@ -28,7 +38,7 @@ if [[ ! -d $SRC_DIR ]]; then fi if [[ ! -d $OUT_DIR ]]; then - rm -rf `pwd`/build/qtbase + rm -rf `pwd`/build/qtbase || exit 2 rm -rf ${OUT_DIR}_obj && mkdir -p ${OUT_DIR}_obj || exit 3 @@ -59,17 +69,20 @@ ICU_INC=$OUT_DIR/include export LD_LIBRARY_PATH=$ICU_LIB +# # qtbase +# SRC_DIR=`pwd`/deps/qtbase OUT_DIR=`pwd`/build/qtbase if [[ ! -d $SRC_DIR ]]; then - git clone git://code.qt.io/qt/qtbase.git $SRC_DIR || exit 10 + mkdir -p $SRC_DIR && + curl -L $QTBASE_URL | tar -xJ --strip-components=1 -C $SRC_DIR || exit 10 fi if [[ ! -d $OUT_DIR ]]; then - rm -rf `pwd`/build/qtwebkit + rm -rf `pwd`/build/qtwebengine mkdir -p $OUT_DIR || exit 11 @@ -80,9 +93,7 @@ if [[ ! -d $OUT_DIR ]]; then -prefix $OUT_DIR \ -opensource \ -confirm-license \ - -static \ -no-sql-sqlite \ - -no-pkg-config \ -qt-zlib \ -qt-libpng \ -qt-libjpeg \ @@ -93,13 +104,15 @@ if [[ ! -d $OUT_DIR ]]; then -nomake tools \ -no-qml-debug \ -silent \ - -no-fontconfig \ - -no-dbus \ -icu -continue \ -L $ICU_LIB \ -I $ICU_INC \ -qt-xcb \ -linuxfb || exit 13 +# -static \ +# -no-dbus \ +# -no-fontconfig \ +# -no-pkg-config \ # -no-xcb \ $MAKE || exit 14 @@ -112,13 +125,16 @@ export CMAKE_LIBRARY_PATH=$ICU_LIB export CMAKE_INCLUDE_PATH=$ICU_INC +# # qtwebengine +# SRC_DIR=`pwd`/deps/qtwebengine OUT_DIR=`pwd`/build/qtwebengine if [[ ! -d $SRC_DIR ]]; then - git clone git://code.qt.io/qt/qtwebengine.git $SRC_DIR || exit 20 + mkdir -p $SRC_DIR && + curl -L $QTWEBENGINE_URL | tar -xJ --strip-components=1 -C $SRC_DIR || exit 20 fi if [[ ! -d $OUT_DIR ]]; then @@ -136,7 +152,9 @@ if [[ ! -d $OUT_DIR ]]; then fi +# # noGUI +# SRC_DIR=`pwd` OUT_DIR=`pwd`/build/nogui diff --git a/install-dependencies.sh b/install-dependencies.sh index 5914017..5a2af25 100755 --- a/install-dependencies.sh +++ b/install-dependencies.sh @@ -1,3 +1,5 @@ #!/usr/bin/env sh apt-get install gperf bison ruby flex + +apt-get install libdbus-1-dev libegl1-mesa-dev libfontconfig1-dev diff --git a/readme.md b/readme.md index c5f77f8..420f296 100644 --- a/readme.md +++ b/readme.md @@ -1,35 +1,36 @@ -#### NodeOS HTML Renderer +# NodeOS HTML Renderer - This is a first attempt to give NodeOS a working gui ! It's name is prettey simple: **N**ode**O**s-**Gui**. +This is a first try to give NodeOS a working GUI! It's name is pretty simple: +**N**ode**O**s-**GUI**. -##### Building and Configuring QT5 +## Building and Configuring QT5 -Let's build **noGui**: +Let's build **noGUI**: -Nothing easier than that. Just execute `./build.sh` +Nothing easier than that. Just execute `./build.sh`. This will clone the Qt +repo, build a static binary and build noGUI. To check if it worked, type +`ldd ./[noGUI executable]`. -This will clone the qt repo, build a static binary and build noGui. +## Using the build script -To check if it worked , type `ldd ./[noGUI executable]`. +Nothing special, just copy and paste it into the project root and run it (maybe +you'll need root). -##### using the build script +## Running noGUI -Nothing special, just copy and paste it into the project root and run it (maybe you'll need root) +To run noGui you need either a linux framebuffer or EGLFS. -##### Running noGui - -To run noGui you need either a linuxfb or EGLFS - -Run on fb: +Run on FbDev: +```sh +./noGUI -platform linuxfb http://url.com ``` -./noGui -platform linuxfb http://url.com -``` Run on EGLFS (recommended) -``` -./noGui .platform eglfs http://url.com + +```sh +./noGUI .platform eglfs http://url.com ``` **Note that you have to add http://**