Coder Social home page Coder Social logo

compile-error without reason about laf HOT 1 OPEN

aseprite avatar aseprite commented on July 17, 2024
compile-error without reason

from laf.

Comments (1)

mr-who2012 avatar mr-who2012 commented on July 17, 2024

ok, I got it to work: Turns out, I had to compile skia by hand, in addition. The pre-compiled versions don't seem to work on ubuntu 18.04. For this, I had to install the package libc++-10-dev in ubuntu. They contain the c++10-header-files. Also I had to type

export CPLUS_INCLUDE_PATH=/usr/lib/llvm-10/include/c++/v1
at the command line, so the build-system could actually make use of the c++10-header-files.

BTW, the build-system is called GN and it needs to get downloaded with:

curl -L -o gn.zip "https://chrome-infra-packages.appspot.com/dl/gn/gn/linux-amd64/+/latest"

inside the downloaded zip-file was just one file "gn". I made it executable
chmod ugo+x ./gn
and copied it to /usr/local/bin so the system could make use of it.

Edit:
The command to make the build-environmant of skia was:
gn gen out/Release --args='is_debug=false is_official_build=true skia_use_system_expat=false skia_use_system_icu=false skia_use_system_libjpeg_turbo=false skia_use_system_libpng=false skia_use_system_libwebp=false skia_use_system_zlib=false skia_use_sfntly=false skia_use_freetype=true skia_use_harfbuzz=true skia_pdf_subset_harfbuzz=true skia_use_system_freetype2=false skia_use_system_harfbuzz=false cc="clang" cxx="clang++" extra_cflags_cc=["-stdlib=libc++"] extra_ldflags=["-stdlib=libc++"]' --extra-cxx-flags="-I/usr/lib/llvm-10/include/c++/v1"

this line is longer than stated in the official build-documentation.

Also, I had to add a few switches to make cmake work with clang or somethin' like this. I don't remember exactly. Anyway, this options needed to be added to the cmake-line of laf:

-DCMAKE_CXX_FLAGS=-stdlib=libc++
and
-DCMAKE_EXE_LINKER_FLAGS=-stdlib=libc++

so, in the end (to compile laf) the line was:
cmake -G Ninja -DLAF_BACKEND=skia -DSKIA_DIR=/home/user/deps/skia -DSKIA_LIBRARY_DIR=/home/user/deps/skia/out/Release-x64 -DCMAKE_CXX_FLAGS=-stdlib=libc++ -DCMAKE_EXE_LINKER_FLAGS=-stdlib=libc++ ..

compilation was started with

ninja
afterwards

from laf.

Related Issues (19)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.