Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Alpine linux error imgui #53

Closed
sodomon2 opened this issue Aug 14, 2019 · 7 comments
Closed

Alpine linux error imgui #53

sodomon2 opened this issue Aug 14, 2019 · 7 comments

Comments

@sodomon2
Copy link

I have a mistake in compiling with imgui Here's the mistake.

imgui.cpp
In file included from ../../../externals/imgui/imgui.cpp:977:
../../../externals/imgui/imgui.h:1205:56: error: 'operator new' takes type 'size_t' ('unsigned int') as first parameter [-fpermissive]
inline void* operator new(size_t, ImNewDummy, void* ptr) { return ptr; }
^
make[1]: *** [Makefile:187: obj/x86/debug/imgui.o] Error 1
make: *** [Makefile:89: imgui] Error 2

@JaCzekanski
Copy link
Owner

JaCzekanski commented Aug 14, 2019

Hello
I need more info about your build environment to reproduce this issue:

  • System version and processor architecture (x86/x64, other?)
  • Compilator type and version (gcc/clang)
  • What build commands are you using (make config=release_x64 avocado, something different).

@sodomon2
Copy link
Author

sodomon2 commented Aug 15, 2019

  • System version and processor architecture (x86/x64, other?)
    Alpine linux x86_64

  • Compilator type and version (gcc/clang)
    gcc

Well apparently I already found the bug was that it detected the x86 architecture and I have x86_64

and apparently passing this command

  • make config=release_x64 avocado
    the architecture changes to x86_64
    but it gives me another mistake

And here's the mistake.
==== Building core (release_x64) ====
voice.cpp
../../../src/device/spu/voice.cpp: In member function 'void spu::Voice::processEnvelope()':
../../../src/device/spu/voice.cpp:64:69: error: 'ceil' is not a member of 'std'
step = static_cast(static_cast(step) * std::ceil(static_cast(adsrVolume._reg) / static_cast(0x8000)));
^~~~
../../../src/device/spu/voice.cpp:64:69: note: suggested alternative: 'cend'
step = static_cast(static_cast(step) * std::ceil(static_cast(adsrVolume._reg) / static_cast(0x8000)));
^~~~
cend
make[1]: *** [Makefile:360: obj/x64/release/voice.o] Error 1
make: *** [Makefile:107: core] Error 2
make: *** Waiting for unfinished jobs....

@JaCzekanski
Copy link
Owner

JaCzekanski commented Aug 15, 2019

Please try building latest commit e106b75, there were few issues in code that prevented it from building on certain compilers.

In case of merge conflicts, reset branch to origin (I was rebasing the code):

git fetch
git reset --hard origin/develop

@sodomon2
Copy link
Author

apparently I cloned the code again and compile with these instructions

  • premake5 gmake
  • make config=release_x64 avocado

and I compile without errors but at the time of running the emulator says to me

Illegal instruction

@JaCzekanski
Copy link
Owner

It seems like you have older cpu which doesn't support AVX. You have to either build 32 bit version or remove this line from premake5.lua and rebuild the whole project (as 64 bit version)
vectorextensions "AVX"

@sodomon2
Copy link
Author

sodomon2 commented Aug 15, 2019

Thank you very much but now that I did it gives me another error here the error

[GL] Cannot load render shader: File doesn't exists.
Cannot setup graphics

@JaCzekanski
Copy link
Owner

Oops, I forgot to fix that. It will be fixed in future commits.

Simply comment line
chdir(workingDirectory.c_str());
in src/platform/windows/main.cpp

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants