aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLily <47812810+LilyWangL@users.noreply.github.com>2020-05-16 07:39:54 +0800
committerGitHub <noreply@github.com>2020-05-15 16:39:54 -0700
commitfea58137280f53c56b86e36161b19a8727464aa6 (patch)
tree8c15682949149b4c4a6e96010c320245502804b6
parent184c7240337b0ab5ef39176e7eb304afaf8226aa (diff)
downloadvcpkg-fea58137280f53c56b86e36161b19a8727464aa6.tar.gz
vcpkg-fea58137280f53c56b86e36161b19a8727464aa6.zip
[ogre/ogre-next] Add conflict error message (#11325)
* [ogre/ogre-next] Add conflict error message * [ogre] Fix build error * [ogre/ogre-next] Fix deprecated function
-rw-r--r--ports/ogre-next/CONTROL2
-rw-r--r--ports/ogre-next/portfile.cmake8
-rw-r--r--ports/ogre/CONTROL2
-rw-r--r--ports/ogre/portfile.cmake44
4 files changed, 20 insertions, 36 deletions
diff --git a/ports/ogre-next/CONTROL b/ports/ogre-next/CONTROL
index 0ac635f0c..f2ebbddaf 100644
--- a/ports/ogre-next/CONTROL
+++ b/ports/ogre-next/CONTROL
@@ -1,5 +1,5 @@
Source: ogre-next
-Version: 2019-10-20
+Version: 2019-10-20-1
Build-Depends: zlib, freeimage, freetype, rapidjson, openvr, boost-thread, boost-date-time, poco, tbb, sdl2, tinyxml, zziplib
Homepage: https://github.com/OGRECave/ogre-next
Description: Ogre 2.1 & 2.2 - scene-oriented, flexible 3D engine written in C++
diff --git a/ports/ogre-next/portfile.cmake b/ports/ogre-next/portfile.cmake
index ade55bcc2..02f147ab8 100644
--- a/ports/ogre-next/portfile.cmake
+++ b/ports/ogre-next/portfile.cmake
@@ -1,6 +1,8 @@
# This portfile is based (shamelessly copied and adapted a bit) on 'ogre' portfile.
-include(vcpkg_common_functions)
+if (EXISTS "${CURRENT_INSTALLED_DIR}/Media/HLMS/Blendfunctions_piece_fs.glslt")
+ message(FATAL_ERROR "FATAL ERROR: ogre-next and ogre are incompatible.")
+endif()
if(NOT VCPKG_TARGET_IS_WINDOWS)
message("${PORT} currently requires the following library from the system package manager:\n Xaw\n\nIt can be installed on Ubuntu systems via apt-get install libxaw7-dev")
@@ -87,7 +89,7 @@ endif()
#Remove OgreMain*.lib from lib/ folder, because autolink would complain, since it defines a main symbol
#manual-link subfolder is here to the rescue!
-if(NOT VCPKG_CMAKE_SYSTEM_NAME OR VCPKG_CMAKE_SYSTEM_NAME STREQUAL "WindowsStore")
+if(VCPKG_TARGET_IS_WINDOWS)
if(NOT DEFINED VCPKG_BUILD_TYPE OR VCPKG_BUILD_TYPE STREQUAL "Release")
file(MAKE_DIRECTORY ${CURRENT_PACKAGES_DIR}/lib/manual-link)
if(VCPKG_LIBRARY_LINKAGE STREQUAL "dynamic")
@@ -114,6 +116,6 @@ if(NOT VCPKG_CMAKE_SYSTEM_NAME OR VCPKG_CMAKE_SYSTEM_NAME STREQUAL "WindowsStore
endif()
# Handle copyright
-file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/ogre-next RENAME copyright)
+file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright)
vcpkg_copy_pdbs()
diff --git a/ports/ogre/CONTROL b/ports/ogre/CONTROL
index 3522ff8c5..521f13f17 100644
--- a/ports/ogre/CONTROL
+++ b/ports/ogre/CONTROL
@@ -1,5 +1,5 @@
Source: ogre
-Version: 1.12.1
+Version: 1.12.1-1
Build-Depends: freeimage, freetype, zlib, zziplib
Homepage: https://github.com/OGRECave/ogre
Description: 3D Object-Oriented Graphics Rendering Engine
diff --git a/ports/ogre/portfile.cmake b/ports/ogre/portfile.cmake
index 898077c1e..f5faac14b 100644
--- a/ports/ogre/portfile.cmake
+++ b/ports/ogre/portfile.cmake
@@ -1,6 +1,8 @@
-include(vcpkg_common_functions)
+if (EXISTS "${CURRENT_INSTALLED_DIR}/Media/HLMS/Blendfunctions_piece_fs.glslt")
+ message(FATAL_ERROR "FATAL ERROR: ogre-next and ogre are incompatible.")
+endif()
-if(VCPKG_CMAKE_SYSTEM_NAME AND NOT VCPKG_CMAKE_SYSTEM_NAME STREQUAL "WindowsStore")
+if(NOT VCPKG_TARGET_IS_WINDOWS)
message("${PORT} currently requires the following library from the system package manager:\n Xaw\n\nIt can be installed on Ubuntu systems via apt-get install libxaw7-dev")
endif()
@@ -24,29 +26,12 @@ endif()
# Configure features
-if("d3d9" IN_LIST FEATURES)
- set(WITH_D3D9 ON)
-else()
- set(WITH_D3D9 OFF)
-endif()
-
-if("java" IN_LIST FEATURES)
- set(WITH_JAVA ON)
-else()
- set(WITH_JAVA OFF)
-endif()
-
-if("python" IN_LIST FEATURES)
- set(WITH_PYTHON ON)
-else()
- set(WITH_PYTHON OFF)
-endif()
-
-if("csharp" IN_LIST FEATURES)
- set(WITH_CSHARP ON)
-else()
- set(WITH_CSHARP OFF)
-endif()
+vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS
+ d3d9 OGRE_BUILD_RENDERSYSTEM_D3D9
+ java OGRE_BUILD_COMPONENT_JAVA
+ python OGRE_BUILD_COMPONENT_PYTHON
+ csharp OGRE_BUILD_COMPONENT_CSHARP
+)
vcpkg_configure_cmake(
SOURCE_PATH ${SOURCE_PATH}
@@ -73,10 +58,7 @@ vcpkg_configure_cmake(
-DOGRE_BUILD_RENDERSYSTEM_GLES=OFF
-DOGRE_BUILD_RENDERSYSTEM_GLES2=OFF
# Optional stuff
- -DOGRE_BUILD_COMPONENT_JAVA=${WITH_JAVA}
- -DOGRE_BUILD_COMPONENT_PYTHON=${WITH_PYTHON}
- -DOGRE_BUILD_COMPONENT_CSHARP=${WITH_CSHARP}
- -DOGRE_BUILD_RENDERSYSTEM_D3D9=${WITH_D3D9}
+ ${FEATURE_OPTIONS}
# vcpkg specific stuff
-DOGRE_CMAKE_DIR=share/ogre
)
@@ -105,7 +87,7 @@ endif()
#Remove OgreMain*.lib from lib/ folder, because autolink would complain, since it defines a main symbol
#manual-link subfolder is here to the rescue!
-if(NOT VCPKG_CMAKE_SYSTEM_NAME OR VCPKG_CMAKE_SYSTEM_NAME STREQUAL "WindowsStore")
+if(VCPKG_TARGET_IS_WINDOWS)
if(NOT DEFINED VCPKG_BUILD_TYPE OR VCPKG_BUILD_TYPE STREQUAL "Release")
file(MAKE_DIRECTORY ${CURRENT_PACKAGES_DIR}/lib/manual-link)
if(VCPKG_LIBRARY_LINKAGE STREQUAL "dynamic")
@@ -132,6 +114,6 @@ if(NOT VCPKG_CMAKE_SYSTEM_NAME OR VCPKG_CMAKE_SYSTEM_NAME STREQUAL "WindowsStore
endif()
# Handle copyright
-file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/ogre RENAME copyright)
+file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright)
vcpkg_copy_pdbs()