JaCzekanski / Avocado

🥑 PlayStation 1 emulator
GNU General Public License v2.0
538 stars 31 forks source link

Alpine linux error imgui #53

Closed sodomon2 closed 5 years ago

sodomon2 commented 5 years ago

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 commented 5 years ago

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

sodomon2 commented 5 years ago

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

and apparently passing this command

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 commented 5 years ago

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 commented 5 years ago

apparently I cloned the code again and compile with these instructions

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

Illegal instruction

JaCzekanski commented 5 years ago

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 commented 5 years ago

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 commented 5 years ago

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