Difference between revisions of "Compiling with Make (OpenXcom)"
Jump to navigation
Jump to search
Winterheart (talk | contribs) m |
m (s/SupSuper/OpenXcom/) |
||
(9 intermediate revisions by 6 users not shown) | |||
Line 1: | Line 1: | ||
+ | Although using CMake is recommended to generate more robust Makefiles, OpenXcom also provides a basic Makefile for compilation. It tends to work well on Linux, but you may have to pass some custom flags to get things working on other operating systems. | ||
+ | |||
== Required packages == | == Required packages == | ||
* [http://git-scm.com/ git] (git) | * [http://git-scm.com/ git] (git) | ||
Line 5: | Line 7: | ||
* [http://www.libsdl.org/projects/SDL_image/ SDL_image] (libsdl-image1.2-dev) | * [http://www.libsdl.org/projects/SDL_image/ SDL_image] (libsdl-image1.2-dev) | ||
* [http://www.ferzkopp.net/joomla/content/view/19/14/ SDL_gfx] (libsdl-gfx1.2-dev), version 2.0.22 or later | * [http://www.ferzkopp.net/joomla/content/view/19/14/ SDL_gfx] (libsdl-gfx1.2-dev), version 2.0.22 or later | ||
− | * [http://code.google.com/p/yaml-cpp/ yaml-cpp] (libyaml-cpp-dev), version 0. | + | * [http://code.google.com/p/yaml-cpp/ yaml-cpp] (libyaml-cpp-dev), version '''0.5 or later''' |
+ | * [http://www.boost.org boost] (libboost-dev), required as dependency for yaml-cpp 0.5. | ||
− | Check the library websites if you can't find them | + | Check the library websites if you can't find them with your distribution's package manager. |
+ | |||
+ | '''Don't forget to copy the X-Com resources to your ''bin'' folder as shown in [[Installing (OpenXcom)|Installing]].''' | ||
== Commands == | == Commands == | ||
− | + | git clone https://github.com/OpenXcom/OpenXcom.git | |
− | + | cd OpenXcom/src | |
− | + | make -f Makefile.simple | |
− | + | ||
− | + | On OSX, that last command (for me, at least) is: | |
− | + | ||
− | + | PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/usr/local/lib/pkgconfig CXX=/usr/bin/clang++ CXXFLAGS="-O2 -I/usr/local/Cellar/boost/1.57.0/include" make -f Makefile.simple -j10 | |
+ | |||
+ | You can now run the game from <code>OpenXcom/bin/openxcom</code> | ||
[[Category:OpenXcom]] | [[Category:OpenXcom]] |
Latest revision as of 15:34, 10 November 2020
Although using CMake is recommended to generate more robust Makefiles, OpenXcom also provides a basic Makefile for compilation. It tends to work well on Linux, but you may have to pass some custom flags to get things working on other operating systems.
Required packages
- git (git)
- SDL (libsdl1.2-dev)
- SDL_mixer (libsdl-mixer1.2-dev)
- SDL_image (libsdl-image1.2-dev)
- SDL_gfx (libsdl-gfx1.2-dev), version 2.0.22 or later
- yaml-cpp (libyaml-cpp-dev), version 0.5 or later
- boost (libboost-dev), required as dependency for yaml-cpp 0.5.
Check the library websites if you can't find them with your distribution's package manager.
Don't forget to copy the X-Com resources to your bin folder as shown in Installing.
Commands
git clone https://github.com/OpenXcom/OpenXcom.git cd OpenXcom/src make -f Makefile.simple
On OSX, that last command (for me, at least) is:
PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/usr/local/lib/pkgconfig CXX=/usr/bin/clang++ CXXFLAGS="-O2 -I/usr/local/Cellar/boost/1.57.0/include" make -f Makefile.simple -j10
You can now run the game from OpenXcom/bin/openxcom