From 7cade6f27f1585688dc2d4cba50abbb42fe2752e Mon Sep 17 00:00:00 2001 From: Loic Blot Date: Mon, 9 Oct 2023 09:08:00 +0200 Subject: [PATCH] cleanup: remove _IRR_COMPILE_ANDROID_ASSET_READER_ build flag it's enabled inconditionally on android also remove some _IRR_COMPILE_WITH_ANDROID_DEVICE_ which are useless because cmake is already properly configured --- source/Irrlicht/Android/CAndroidAssetFileArchive.cpp | 2 -- source/Irrlicht/Android/CAndroidAssetFileArchive.h | 4 ---- source/Irrlicht/Android/CAndroidAssetReader.cpp | 4 ---- source/Irrlicht/Android/CAndroidAssetReader.h | 4 ---- source/Irrlicht/Android/CIrrDeviceAndroid.cpp | 4 ---- source/Irrlicht/Android/CIrrDeviceAndroid.h | 2 -- source/Irrlicht/Android/CKeyEventWrapper.cpp | 5 ----- source/Irrlicht/Android/CKeyEventWrapper.h | 4 ---- source/Irrlicht/CMakeLists.txt | 2 +- 9 files changed, 1 insertion(+), 30 deletions(-) diff --git a/source/Irrlicht/Android/CAndroidAssetFileArchive.cpp b/source/Irrlicht/Android/CAndroidAssetFileArchive.cpp index 47186db7..e4c1b8ce 100644 --- a/source/Irrlicht/Android/CAndroidAssetFileArchive.cpp +++ b/source/Irrlicht/Android/CAndroidAssetFileArchive.cpp @@ -3,7 +3,6 @@ // For conditions of distribution and use, see copyright notice in irrlicht.h -#ifdef _IRR_COMPILE_ANDROID_ASSET_READER_ #include "CAndroidAssetReader.h" @@ -106,4 +105,3 @@ void CAndroidAssetFileArchive::addDirectoryToFileList(const io::path &dirname_) } // end namespace io } // end namespace irr -#endif // _IRR_COMPILE_ANDROID_ASSET_READER_ diff --git a/source/Irrlicht/Android/CAndroidAssetFileArchive.h b/source/Irrlicht/Android/CAndroidAssetFileArchive.h index 19ed81c5..cc61728c 100644 --- a/source/Irrlicht/Android/CAndroidAssetFileArchive.h +++ b/source/Irrlicht/Android/CAndroidAssetFileArchive.h @@ -4,9 +4,6 @@ #pragma once -#ifdef _IRR_COMPILE_ANDROID_ASSET_READER_ - - #include "IReadFile.h" #include "IFileArchive.h" #include "CFileList.h" @@ -61,4 +58,3 @@ namespace io } // end namespace io } // end namespace irr -#endif // _IRR_COMPILE_ANDROID_ASSET_READER_ diff --git a/source/Irrlicht/Android/CAndroidAssetReader.cpp b/source/Irrlicht/Android/CAndroidAssetReader.cpp index b36bd097..e535d886 100644 --- a/source/Irrlicht/Android/CAndroidAssetReader.cpp +++ b/source/Irrlicht/Android/CAndroidAssetReader.cpp @@ -2,9 +2,6 @@ // This file is part of the "Irrlicht Engine". // For conditions of distribution and use, see copyright notice in irrlicht.h - -#ifdef _IRR_COMPILE_ANDROID_ASSET_READER_ - #include "CAndroidAssetReader.h" #include "CReadFile.h" @@ -69,4 +66,3 @@ const io::path& CAndroidAssetReader::getFileName() const } // end namespace io } // end namespace irr -#endif // _IRR_COMPILE_ANDROID_ASSET_READER_ diff --git a/source/Irrlicht/Android/CAndroidAssetReader.h b/source/Irrlicht/Android/CAndroidAssetReader.h index 9a1e9b24..16bed853 100644 --- a/source/Irrlicht/Android/CAndroidAssetReader.h +++ b/source/Irrlicht/Android/CAndroidAssetReader.h @@ -4,9 +4,6 @@ #pragma once -#ifdef _IRR_COMPILE_ANDROID_ASSET_READER_ - - #include "IReadFile.h" struct AAssetManager; @@ -66,4 +63,3 @@ namespace io } // end namespace io } // end namespace irr -#endif // _IRR_COMPILE_ANDROID_ASSET_READER_ diff --git a/source/Irrlicht/Android/CIrrDeviceAndroid.cpp b/source/Irrlicht/Android/CIrrDeviceAndroid.cpp index 3a7e2a65..fe667315 100644 --- a/source/Irrlicht/Android/CIrrDeviceAndroid.cpp +++ b/source/Irrlicht/Android/CIrrDeviceAndroid.cpp @@ -5,8 +5,6 @@ #include "CIrrDeviceAndroid.h" -#ifdef _IRR_COMPILE_WITH_ANDROID_DEVICE_ - #include "os.h" #include "CFileSystem.h" #include "CAndroidAssetReader.h" @@ -858,5 +856,3 @@ bool CIrrDeviceAndroid::isGyroscopeAvailable() } } // end namespace irr - -#endif diff --git a/source/Irrlicht/Android/CIrrDeviceAndroid.h b/source/Irrlicht/Android/CIrrDeviceAndroid.h index c57173d3..656c4566 100644 --- a/source/Irrlicht/Android/CIrrDeviceAndroid.h +++ b/source/Irrlicht/Android/CIrrDeviceAndroid.h @@ -5,7 +5,6 @@ #pragma once -#ifdef _IRR_COMPILE_WITH_ANDROID_DEVICE_ #include "CIrrDeviceStub.h" #include "IrrlichtDevice.h" @@ -98,4 +97,3 @@ namespace irr } // end namespace irr -#endif // _IRR_COMPILE_WITH_ANDROID_DEVICE_ diff --git a/source/Irrlicht/Android/CKeyEventWrapper.cpp b/source/Irrlicht/Android/CKeyEventWrapper.cpp index e5a48842..f68e77db 100644 --- a/source/Irrlicht/Android/CKeyEventWrapper.cpp +++ b/source/Irrlicht/Android/CKeyEventWrapper.cpp @@ -3,8 +3,6 @@ #include "CKeyEventWrapper.h" -#ifdef _IRR_COMPILE_WITH_ANDROID_DEVICE_ - #include "os.h" namespace irr @@ -58,6 +56,3 @@ int CKeyEventWrapper::getUnicodeChar(int metaState) } // namespace jni } // namespace irr - - -#endif // _IRR_COMPILE_WITH_ANDROID_DEVICE_ diff --git a/source/Irrlicht/Android/CKeyEventWrapper.h b/source/Irrlicht/Android/CKeyEventWrapper.h index eee763e6..de21ffe2 100644 --- a/source/Irrlicht/Android/CKeyEventWrapper.h +++ b/source/Irrlicht/Android/CKeyEventWrapper.h @@ -3,8 +3,6 @@ #pragma once -#ifdef _IRR_COMPILE_WITH_ANDROID_DEVICE_ - #include struct android_app; @@ -35,5 +33,3 @@ private: } // namespace jni } // namespace irr - -#endif // _IRR_COMPILE_WITH_ANDROID_DEVICE_ diff --git a/source/Irrlicht/CMakeLists.txt b/source/Irrlicht/CMakeLists.txt index 21237369..75e8e324 100644 --- a/source/Irrlicht/CMakeLists.txt +++ b/source/Irrlicht/CMakeLists.txt @@ -88,7 +88,7 @@ elseif(APPLE) add_definitions(-D_IRR_OSX_PLATFORM_) set(DEVICE "OSX") elseif(ANDROID) - add_definitions(-D_IRR_ANDROID_PLATFORM_ -D_IRR_COMPILE_ANDROID_ASSET_READER_) + add_definitions(-D_IRR_ANDROID_PLATFORM_) if(USE_SDL2) message(FATAL_ERROR "SDL2 device is not (yet) supported on Android") endif()