MrSapps / alive

EFFORTS HAVE NOW MOVED TO https://github.com/AliveTeam/alive_reversing Unofficial open source implementation of ALIVE engine that powers Oddworld Abes Oddysee and Oddworld Abes Exoddus.
MIT License
104 stars 9 forks source link

make fatal error: sample.lvl.g.h: No such file or directory #77

Closed HisDudeness3008 closed 7 years ago

HisDudeness3008 commented 7 years ago

Sorry if the question is stupid, I'm really a newbie at these things. I followed the instructions in the readme.md. Inside my local folder for git repos I recursively cloned this one

git clone --recursive https://github.com/paulsapps/alive.git

I cded into the newly created alive folder, created a build folder inside it, cded into it and

cmake .. -G Unix\ Makefiles

However, when subsequently running make, I get this error at 81%

main.cpp:10:26: fatal error: sample.lvl.g.h: No such file or directory

include "sample.lvl.g.h"

Where should I get the missing header?

MrSapps commented 7 years ago

The headers with *.g.h are auto generated. What version of CMake are you using? Someone on IRC had this issue but I don't know what they did to fix it. I can't reproduce this with MSVC2015 and CMake 3.6.0

Travis on OSX is using cmake-3.7.0 and Linux is using version 3.2.2.

Its done here: https://github.com/paulsapps/alive/blob/dev/CMakeLists.txt#L409

Perhaps you could workaround it for now by checking what target is added to the make file that calls this? Then just invoke "make the_target_name"?

Edit: I think the workaround used by the person on IRC was to just run make twice..

HisDudeness3008 commented 7 years ago

My CMake is version 3.7.1. It should be the latest, as I use Arch Linux which is a rolling distribution. I tried running both cmake and make multiple times in a row, but to no avail.

Perhaps you could workaround it for now by checking what target is added to the make file that calls this? Then just invoke "make the_target_name"?

I'm sorry, I don't precisely understand what I should do... I'm a complete dummy as far as makefiles and building goes (and not only that).

MrSapps commented 7 years ago

Could you delete your build directory and try again and paste bin your CMake/make logs?

Edit: Also could you check if latest code fixes it? I've attempted to make tests depend on the generated header files and make the header generator depend on bin2h.

HisDudeness3008 commented 7 years ago

Thanks a lot! I deleted everything and restarted from scratch, cloning the repository, to get the latest version, and everything works now!