Ancurio / mkxp

Free Software implementation of the Ruby Game Scripting System (RGSS)
GNU General Public License v2.0
515 stars 132 forks source link

Cmake doesn't read my installed packages #74

Closed Derpface360 closed 9 years ago

Derpface360 commented 9 years ago

-- The C compiler identification is GNU 4.9.1 -- The CXX compiler identification is GNU 4.9.1 -- Check for working C compiler: /usr/bin/cc -- Check for working C compiler: /usr/bin/cc -- works -- Detecting C compiler ABI info -- Detecting C compiler ABI info - done -- Check for working CXX compiler: /usr/bin/c++ -- Check for working CXX compiler: /usr/bin/c++ -- works -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Found PkgConfig: /usr/bin/pkg-config (found version "0.28") -- checking for module 'sigc++-2.0' -- found sigc++-2.0, version 2.4.0 -- checking for module 'pixman-1' -- found pixman-1, version 0.32.6 -- checking for module 'physfs>=2.1' -- package 'physfs>=2.1' not found CMake Error at /usr/share/cmake/Modules/FindPkgConfig.cmake:341 (message): A required package was not found Call Stack (most recent call first): /usr/share/cmake/Modules/FindPkgConfig.cmake:395 (_pkg_check_modules_internal) CMakeLists.txt:88 (pkg_check_modules)

-- checking for module 'vorbisfile' -- found vorbisfile, version 1.3.4 -- checking for module 'sdl2' -- found sdl2, version 2.0.3 -- checking for module 'SDL2_ttf' -- found SDL2_ttf, version 2.0.12 -- checking for module 'SDL2_image' -- found SDL2_image, version 2.0.0 -- checking for module 'SDL_sound' -- package 'SDL_sound' not found CMake Error at /usr/share/cmake/Modules/FindPkgConfig.cmake:341 (message): A required package was not found Call Stack (most recent call first): /usr/share/cmake/Modules/FindPkgConfig.cmake:395 (_pkg_check_modules_internal) CMakeLists.txt:93 (pkg_check_modules)

-- Boost version: 1.55.0 -- Found the following Boost libraries: -- program_options -- Found OpenAL: /usr/lib64/libopenal.so
-- Found ZLIB: /usr/lib64/libz.so (found version "1.2.8") -- checking for module 'ruby-2.1' -- package 'ruby-2.1' not found CMake Error at /usr/share/cmake/Modules/FindPkgConfig.cmake:341 (message): A required package was not found Call Stack (most recent call first): /usr/share/cmake/Modules/FindPkgConfig.cmake:395 (_pkg_check_modules_internal) CMakeLists.txt:284 (pkg_check_modules)

-- Configuring incomplete, errors occurred!

I have the libraries and development files of all of these packages, but cmake is unable to read it. I would try using qmake, but Fedora 21 doesn't yet have a package for it. Is there a way you can add a normal configure script into the master branch?

Ancurio commented 9 years ago

I have the libraries and development files of all of these packages, but cmake is unable to read it.

cmake is using pkg-config for both these packages, so if pkg-config --exists --print-errors physfs ruby-2.1 is giving you errors, your pkg-config environment is not setup properly. This is stated in the readme, but you need the latest hg tip of physfs.

I would try using qmake, but Fedora 21 doesn't yet have a package for it.

I believe in Fedora, qmake is part of the qt-devel package. Regardless, qmake uses pkg-config just the same, so you'd run into the exact same issue.

Is there a way you can add a normal configure script into the master branch?

mkxp already has two build systems (and only one I'm familiar with); I'm not sure if a third is a good idea.. but I wouldn't reject patches to add it, as long as maintaining it isn't too big of a deal.

Btw. if you're not too familiar with building software on linux and just want to use mkxp, it's easier to download the precompiled binaries linked at the top of the readme.

moocow1452 commented 9 years ago

It's not me, @Ancurio.

Ancurio commented 9 years ago

Ok, nvm.

carstene1ns commented 9 years ago

Adding autotools support should not be too difficult, as mkxp targets modern environments (uses sdl2, etc.), so most of the quirks needed for broken/outdated autotools versions are not necessary. However I also see no reason to do it, as maintaining 3 build systems is a tedious task and will likely take away time from actual developing. Also, autotools can also use pkg-config where available, so it will likely not help in this particular case.


@Derpface360: You should check, which version of ruby you have, you can adjust it when you call cmake with -DMRIVERSION=2.0. Also, you need the added pkg-config support in physfs and sdl_sound, provided by the latest development version from mercurial repository and the patch inside this repository. If you do not want to patch your installed version of the libraries, it is also possible to use a local version of them (or only use the pkg-config file and set PKG_CONFIG_PATH variable before invoking cmake) If you need any further help, just ask here.

Derpface360 commented 9 years ago

I know I sound like an idiot, but I just don't understand this. I deleted Fedora 21 off of my computer and installed Fedora 20 yesterday for better stability, and all went well at first.

Now that I try to install MKXP after installing all of the dependencies (and the 2 ones that needed Mercurial) and built and installed them. Now I get this error:

-- checking for module 'physfs>=2.1' -- package 'physfs>=2.1' not found CMake Error at /usr/share/cmake/Modules/FindPkgConfig.cmake:279 (message): A required package was not found Call Stack (most recent call first): /usr/share/cmake/Modules/FindPkgConfig.cmake:333 (_pkg_check_modules_internal) CMakeLists.txt:88 (pkg_check_modules)

-- checking for module 'vorbisfile' -- package 'vorbisfile' not found CMake Error at /usr/share/cmake/Modules/FindPkgConfig.cmake:279 (message): A required package was not found Call Stack (most recent call first): /usr/share/cmake/Modules/FindPkgConfig.cmake:333 (_pkg_check_modules_internal) CMakeLists.txt:89 (pkg_check_modules)

-- checking for module 'SDL_sound' -- package 'SDL_sound' not found CMake Error at /usr/share/cmake/Modules/FindPkgConfig.cmake:279 (message): A required package was not found Call Stack (most recent call first): /usr/share/cmake/Modules/FindPkgConfig.cmake:333 (_pkg_check_modules_internal) CMakeLists.txt:93 (pkg_check_modules)

-- Boost version: 1.54.0 -- Found the following Boost libraries: -- program_options -- checking for module 'ruby-2.1' -- package 'ruby-2.1' not found CMake Error at /usr/share/cmake/Modules/FindPkgConfig.cmake:279 (message): A required package was not found Call Stack (most recent call first): /usr/share/cmake/Modules/FindPkgConfig.cmake:333 (_pkg_check_modules_internal) CMakeLists.txt:285 (pkg_check_modules)

-- Configuring incomplete, errors occurred!

It is definitely my OS's doing, and not your package's, but I don't know what I have done wrong.

On another note, @Ancurio, do you have any plans for support with RPG Maker 2000 and 3000, or should I just use EasyRPG?

Ancurio commented 9 years ago

@Derpface360, are you planning on contributing to mkxp? Because otherwise you should really try the precompiled binaries first.

As for your errors, they're almost the same, it's just purely pkg-config not being setup correctly, you're either completely missing certain packages (as with vorbisfile, which is in the Fedora package libvorbis-devel by the way) or not setting up your PKG_CONFIG_PATH to point to where your physfs/SDL_sound/ruby-2.1 .pc files are located.

On another note, @Ancurio, do you have any plans for support with RPG Maker 2000 and 3000, or should I just use EasyRPG?

The RPG Maker 2k series are a completely different engine architecture, so they don't fit into mkxp. And even if, I'd just be reinventing the wheel since EasyRPG has been in development for years and is making very good progress, so definitely check that out.

carstene1ns commented 9 years ago

Just a random guess in addition to Ancurio's remark: If you compiled and installed physfs and sdl_sound by yourself, they likely will be located at /usr/local/.... You need to point pkg-config to that location before running cmake: export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig