mkxp.pro: Shorten keyword lenght to choose binding

'BINDING=BINDING_MRI' => 'BINDING=MRI'

Also error out if multiple bindings are chosen.
This commit is contained in:
Jonas Kulla 2013-12-29 18:01:57 +01:00
parent 7f4e58fd6e
commit 5b736bcfd6
2 changed files with 49 additions and 25 deletions

View File

@ -50,11 +50,11 @@ qmake will use pkg-config to locate the respective include/library paths. If you
The exception is boost, which is weird in that it still hasn't managed to pull off pkg-config support (seriously?). *If you installed boost in a non-standard prefix*, you will need to pass its include path via `BOOST_I` and library path via `BOOST_L`, either as direct arguments to qmake (`qmake BOOST_I="/usr/include" ...`) or via environment variables. The exception is boost, which is weird in that it still hasn't managed to pull off pkg-config support (seriously?). *If you installed boost in a non-standard prefix*, you will need to pass its include path via `BOOST_I` and library path via `BOOST_L`, either as direct arguments to qmake (`qmake BOOST_I="/usr/include" ...`) or via environment variables.
**MRI-Binding**: pkg-config will look for `ruby-2.1.pc`, but you can modify mkxp.pro to use 2.0 instead. This is the default binding, so no arguments to qmake needed (`BINDING=BINDING_MRI` to be explicit). **MRI-Binding**: pkg-config will look for `ruby-2.1.pc`, but you can modify mkxp.pro to use 2.0 instead. This is the default binding, so no arguments to qmake needed (`BINDING=MRI` to be explicit).
**MRuby-Binding**: place the "mruby" folder into the project folder and build it first. Add `BINDING=BINDING_MRUBY` to qmake's arguments. **MRuby-Binding**: place the "mruby" folder into the project folder and build it first. Add `BINDING=MRUBY` to qmake's arguments.
**Null-Binding**: Add `BINDING=BINDING_NULL` to qmake's arguments. **Null-Binding**: Add `BINDING=NULL` to qmake's arguments.
### Supported image/audio formats ### Supported image/audio formats
These depend on the SDL auxiliary libraries. For maximum RGSS compliance, build SDL2_image with png/jpg support, and SDL_sound with oggvorbis/wav/mp3 support. These depend on the SDL auxiliary libraries. For maximum RGSS compliance, build SDL2_image with png/jpg support, and SDL_sound with oggvorbis/wav/mp3 support.

View File

@ -7,6 +7,52 @@ DEPENDPATH += src shader assets
INCLUDEPATH += . src INCLUDEPATH += . src
LIBS += -lGL LIBS += -lGL
CONFIG(release, debug|release): DEFINES += NDEBUG
isEmpty(BINDING) {
BINDING = MRI
}
contains(BINDING, MRI) {
contains(_HAVE_BINDING, YES) {
error("Only one binding may be selected")
}
_HAVE_BINDING = YES
CONFIG += BINDING_MRI
}
contains(BINDING, MRUBY) {
contains(_HAVE_BINDING, YES) {
error("Only one binding may be selected")
}
_HAVE_BINDING = YES
CONFIG += BINDING_MRUBY
}
contains(BINDING, NULL) {
contains(_HAVE_BINDING, YES) {
error("Only one binding may be selected")
}
_HAVE_BINDING = YES
CONFIG += BINDING_NULL
}
RGSS2 {
DEFINES += RGSS2
}
unix {
CONFIG += link_pkgconfig
PKGCONFIG += sigc++-2.0 glew pixman-1 zlib physfs \
sdl2 SDL2_image SDL2_ttf SDL_sound openal
RGSS2 {
PKGCONFIG += vorbisfile
}
# Deal with boost paths... # Deal with boost paths...
isEmpty(BOOST_I) { isEmpty(BOOST_I) {
BOOST_I = $$(BOOST_I) BOOST_I = $$(BOOST_I)
@ -25,28 +71,6 @@ else {
} }
LIBS += -lboost_program_options LIBS += -lboost_program_options
CONFIG(release, debug|release): DEFINES += NDEBUG
isEmpty(BINDING) {
BINDING = BINDING_MRI
}
CONFIG += $$BINDING
RGSS2 {
DEFINES += RGSS2
}
unix {
CONFIG += link_pkgconfig
PKGCONFIG += sigc++-2.0 glew pixman-1 zlib physfs \
sdl2 SDL2_image SDL2_ttf SDL_sound openal
RGSS2 {
PKGCONFIG += vorbisfile
}
} }
# Input # Input