aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorsfan5 <sfan5@live.de>2021-03-25 14:14:44 +0100
committersfan5 <sfan5@live.de>2021-03-25 15:47:33 +0100
commitf05f84b33b19ed11fc1d6eef48286a06c59b06ce (patch)
tree2ae6273b52d0e154af26f6780fa18b46bde536c9
parent3006362e250b08de381a6d2add52526dacc815fb (diff)
downloadirrlicht-f05f84b33b19ed11fc1d6eef48286a06c59b06ce.tar.xz
Rename library to IrrlichtMt
for clarity and to avoid conflicts closes #16
-rw-r--r--.github/workflows/build.yml2
-rw-r--r--CMakeLists.txt2
-rw-r--r--README.md10
-rwxr-xr-xscripts/ci-build-mingw.sh6
-rw-r--r--source/Irrlicht/CMakeLists.txt20
5 files changed, 25 insertions, 15 deletions
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
index 62780a0..ea1ca20 100644
--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -70,7 +70,7 @@ jobs:
- name: Build
run: |
- ./scripts/ci-build-mingw.sh --64
+ ./scripts/ci-build-mingw.sh
env:
CC: x86_64-w64-mingw32-gcc
CXX: x86_64-w64-mingw32-g++
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 8a9b651..7b6a2f0 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -7,7 +7,7 @@ set(IRRLICHT_VERSION_MINOR 9)
set(IRRLICHT_VERSION_RELEASE 0)
set(VERSION "${IRRLICHT_VERSION_MAJOR}.${IRRLICHT_VERSION_MINOR}.${IRRLICHT_VERSION_RELEASE}")
-message(STATUS "*** Building Irrlicht ${VERSION} ***")
+message(STATUS "*** Building IrrlichtMt ${VERSION} ***")
if(ANDROID)
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib/Android)
diff --git a/README.md b/README.md
index 81d007a..aedc073 100644
--- a/README.md
+++ b/README.md
@@ -1,7 +1,9 @@
-The Irrlicht engine version 1.9
-===============================
+IrrlichtMt version 1.9
+======================
-This is a fork of the Irrlicht engine by the [Minetest](https://github.com/minetest) developers that contains features, customizations and fixes specifically for use in Minetest.
+The Irrlicht Engine is an open source realtime 3D engine written in C++.
+
+This is a fork by the [Minetest](https://github.com/minetest) developers that contains features, customizations and fixes specifically for use in Minetest.
Build
-----
@@ -15,7 +17,7 @@ The following libraries are required to be installed:
* on Unix: X11
Aside from standard search options (`ZLIB_INCLUDE_DIR`, `ZLIB_LIBRARY`, ...) the following options are available:
-* `BUILD_SHARED_LIBS` (default: `ON`) - Build Irrlicht as a shared library
+* `BUILD_SHARED_LIBS` (default: `ON`) - Build IrrlichtMt as a shared library
e.g. on a Linux system you might want to build for local use like this:
diff --git a/scripts/ci-build-mingw.sh b/scripts/ci-build-mingw.sh
index edf63b7..58b7a82 100755
--- a/scripts/ci-build-mingw.sh
+++ b/scripts/ci-build-mingw.sh
@@ -1,10 +1,10 @@
#!/bin/bash -e
-variant=win32
-[[ "$1" == "--64" ]] && variant=win64
-
[[ -z "$CC" || -z "$CXX" ]] && exit 255
+variant=win32
+[[ "$CXX" == "x86_64-"* ]] && variant=win64
+
libjpeg_version=2.0.6
libpng_version=1.6.37
zlib_version=1.2.11
diff --git a/source/Irrlicht/CMakeLists.txt b/source/Irrlicht/CMakeLists.txt
index 46db82a..7198bb2 100644
--- a/source/Irrlicht/CMakeLists.txt
+++ b/source/Irrlicht/CMakeLists.txt
@@ -14,7 +14,7 @@ if(CMAKE_CXX_COMPILER_ID MATCHES "^(GNU|Clang|AppleClang)$")
set(CMAKE_CXX_FLAGS_RELEASE "-O3")
set(CMAKE_C_FLAGS_RELEASE ${CMAKE_CXX_FLAGS_RELEASE})
set(CMAKE_CXX_FLAGS_DEBUG "-g")
- set(CMAKE_C_FLAGS_DEBUG ${CMAKE_C_FLAGS_DEBUG})
+ set(CMAKE_C_FLAGS_DEBUG ${CMAKE_CXX_FLAGS_DEBUG})
add_compile_options(-Wall -pipe -fno-exceptions -fno-rtti)
elseif(MSVC)
@@ -22,7 +22,7 @@ elseif(MSVC)
set(CMAKE_CXX_FLAGS_RELEASE "/GL /MT /Ox")
set(CMAKE_C_FLAGS_RELEASE ${CMAKE_CXX_FLAGS_RELEASE})
set(CMAKE_CXX_FLAGS_DEBUG "/MTd /RTC1 /Zi")
- set(CMAKE_C_FLAGS_DEBUG ${CMAKE_C_FLAGS_DEBUG})
+ set(CMAKE_C_FLAGS_DEBUG ${CMAKE_CXX_FLAGS_DEBUG})
set(CMAKE_CXX_FLAGS "/Gd /GF /GR- /GS /Gy /Zl")
set(CMAKE_EXE_LINKER_FLAGS "/nologo")
@@ -41,6 +41,9 @@ link_libraries(${ZLIB_LIBRARY} ${JPEG_LIBRARY} ${PNG_LIBRARY})
# include/IrrCompileConfig.h and re-run CMake from a clean state
include(CheckSymbolExists)
set(CMAKE_REQUIRED_INCLUDES ${CMAKE_SOURCE_DIR}/include)
+unset(OGLES1_ENABLED CACHE)
+unset(OGLES2_ENABLED CACHE)
+unset(OGL_ENABLED CACHE)
check_symbol_exists(_IRR_COMPILE_WITH_OGLES1_ "IrrCompileConfig.h" OGLES1_ENABLED)
if(OGLES1_ENABLED)
@@ -385,7 +388,7 @@ add_library(IRRGUIOBJ OBJECT
option(BUILD_SHARED_LIBS "Build shared library" TRUE)
-add_library(Irrlicht
+add_library(IrrlichtMt
$<TARGET_OBJECTS:IRRMESHOBJ>
$<TARGET_OBJECTS:IRROBJ>
$<TARGET_OBJECTS:IRRPARTICLEOBJ>
@@ -397,12 +400,17 @@ add_library(Irrlicht
$<TARGET_OBJECTS:IRRGUIOBJ>
)
-set_target_properties(Irrlicht PROPERTIES
+set_target_properties(IrrlichtMt PROPERTIES
VERSION ${VERSION}
SOVERSION ${IRRLICHT_VERSION_MAJOR}.${IRRLICHT_VERSION_MINOR}
)
+if(WIN32)
+ set_target_properties(IrrlichtMt PROPERTIES PREFIX "") # for DLL name
+endif()
+
+# Installation
include(GNUInstallDirs)
-install(TARGETS Irrlicht DESTINATION "${CMAKE_INSTALL_LIBDIR}")
-install(DIRECTORY "${CMAKE_SOURCE_DIR}/include/" DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}/irrlicht")
+install(TARGETS IrrlichtMt DESTINATION "${CMAKE_INSTALL_LIBDIR}")
+install(DIRECTORY "${CMAKE_SOURCE_DIR}/include/" DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}/irrlichtmt")