Giter VIP home page Giter VIP logo

Comments (7)

dottokuya avatar dottokuya commented on June 27, 2024

Update: Tried again, this time I removed cleanup command from scripts/build.cmake and it built successfully. Running well on VM (20.04). However running the binary on 20.10 (my main machine) threw a segfault.

from nanoem.

hkrn avatar hkrn commented on June 27, 2024

What the stacktrace produces after gdb -ex r nanoem and bt are executed? (CMAKE_BUILD_TYPE=Debug at building nanoem is required to produce the stacktrace correctly)

On Linux platform, nanoem requires OpenGL 3.3 Core Profile to run (see also sokol's prerequisite).

from nanoem.

dottokuya avatar dottokuya commented on June 27, 2024

Using build script from GitHub Workflow, with CMAKE_BUILD_TYPE=Debug enabled.

With nanoem_test:

Reading symbols from nanoem_test...
Starting program: /home/dongdv/build/core/nanoem_test 
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".

Program received signal SIGSEGV, Segmentation fault.
0x0000000000000000 in ?? ()
(gdb) bt
#0  0x0000000000000000 in ?? ()
#1  0x000000000054156c in nanoemTestSuiteRun (argc=1, argv=0x7fffffffde28)
    at ../../emapp/test/common/entrypoint.cc:36
#2  0x00000000007580c2 in main (argc=1, argv=0x7fffffffde28)
    at ../../emapp/test/main.cc:12

With sapp/nanoem:

[New Thread 0x7ffff44b0640 (LWP 10282)]
[New Thread 0x7ffff3caf640 (LWP 10283)]
[New Thread 0x7ffff34ae640 (LWP 10284)]
[New Thread 0x7ffff2cad640 (LWP 10285)]

Thread 1 "nanoem" received signal SIGSEGV, Segmentation fault.
0x0000000000000000 in ?? ()
(gdb) bt
#0  0x0000000000000000 in ?? ()
#1  0x00007ffff23be5d7 in _sg_gl_setup_backend (desc=0x7ffff23da7d8 <_sg+8>)
    at ../../dependencies/sokol/sokol_gfx.h:5658
#2  0x00007ffff23b3fd5 in _sg_setup_backend (desc=0x7ffff23da7d8 <_sg+8>)
    at ../../dependencies/sokol/sokol_gfx.h:12292
#3  0x00007ffff23b39ee in sg_setup (desc=0x7fffffffb5c8)
    at ../../dependencies/sokol/sokol_gfx.h:14334
#4  0x00007ffff23bd7fd in sgx_setup (desc=0x7fffffffb5c8)
    at ../../emapp/bundle/sokol/sokol_glcore33.c:38
#5  0x000000000043de65 in nanoem::BaseApplicationService::handleCommandMessage (
    this=0x13bca18, command=0x13f0b90, project=0x0, error=...)
    at ../../emapp/src/BaseApplicationService.cc:2804
#6  0x000000000043b5a1 in nanoem::BaseApplicationService::dispatchCommandMessage (
    this=0x13bca18, data=0x13feb90 "\bЊ\233\003RJ\b", size=81, project=0x0, 
    forceUndo=false) at ../../emapp/src/BaseApplicationService.cc:2396
#7  0x0000000000416500 in nanoem::sapp::ApplicationService::consumeDispatchAllCommandMessages (this=0x13bca18) at ../../sapp/src/ApplicationService.cc:189
#8  0x0000000000417737 in nanoem::sapp::MainWindow::draw (this=0x13bc990)
    at ../../sapp/src/MainWindow.cc:60
#9  0x000000000040dca8 in sokol_main::$_2::operator() (this=0x7)
    at ../../sapp/main.cc:105
#10 0x000000000040dc89 in sokol_main::$_2::__invoke () at ../../sapp/main.cc:105
#11 0x00000000004151d2 in _sapp_call_frame ()
    at ../../dependencies/sokol/sokol_app.h:2465
#12 0x0000000000411f32 in _sapp_frame () at ../../dependencies/sokol/sokol_app.h:2641
#13 0x000000000040f347 in _sapp_linux_run (desc=0x7fffffffd9b0)
    at ../../dependencies/sokol/sokol_app.h:10098
#14 0x000000000040f14b in main (argc=1, argv=0x7fffffffdb58)
    at ../../dependencies/sokol/sokol_app.h:10121

from nanoem.

hkrn avatar hkrn commented on June 27, 2024

From the result of nanoem_test it seems running nanoem_test from unexpected path. Running nanoem_test directly is not recommended due to such path problem, instead cmake --build . --target test (GitHub Action uses this method) or ninja test should be used.

From the result of sapp/nanoem it seems glGetError function pointer cannot be resolved from libGL.so. Does ldconfig -p | grep libGL.so present?

from nanoem.

dottokuya avatar dottokuya commented on June 27, 2024

Here's what I got

dottokuya@dottokuya-Lenovo:/media/dottokuya/Storage/Setup/build/core/sapp$ ldconfig -p | grep libGL.so
        libGL.so.1 (libc6,x86-64) => /lib/x86_64-linux-gnu/libGL.so.1
        libGL.so.1 (libc6) => /lib/i386-linux-gnu/libGL.so.1

I think Ubuntu 20.10 and later version might broke some libraries compability, though it's unsure

from nanoem.

hkrn avatar hkrn commented on June 27, 2024

I don't know why this happens honestly, at least this is not the problem of nanoem. To isolate the problem, you should build and run sokol-samples. If you don't run sokol-samples, nanoem will not be able to run also.

from nanoem.

stale avatar stale commented on June 27, 2024

Is this still relevant? If so, what is blocking it? Is there anything you can do to help move it forward?

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

from nanoem.

Related Issues (20)

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.