diff options
| author | Robert Schumacher <roschuma@microsoft.com> | 2019-11-22 09:47:40 -0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2019-11-22 09:47:40 -0800 |
| commit | 45f4b820e5743b89bca3508ba2028cdd5d8bbd17 (patch) | |
| tree | f874a8c4a7392309bdbb86447288597ec0a4a281 /ports/io2d | |
| parent | 62d67d3bf8eeff1afa8009041fd08b8822676b7b (diff) | |
| parent | 8831e8f25f1ff6546ee4a5291b91d599421637b3 (diff) | |
| download | vcpkg-45f4b820e5743b89bca3508ba2028cdd5d8bbd17.tar.gz vcpkg-45f4b820e5743b89bca3508ba2028cdd5d8bbd17.zip | |
Merge branch 'master' into vcpkg_nuget
Diffstat (limited to 'ports/io2d')
| -rw-r--r-- | ports/io2d/CONTROL | 4 | ||||
| -rw-r--r-- | ports/io2d/find-package.patch | 47 | ||||
| -rw-r--r-- | ports/io2d/fix-linux-build.patch | 22 | ||||
| -rw-r--r-- | ports/io2d/portfile.cmake | 16 |
4 files changed, 29 insertions, 60 deletions
diff --git a/ports/io2d/CONTROL b/ports/io2d/CONTROL index 2376ce6de..c48e73334 100644 --- a/ports/io2d/CONTROL +++ b/ports/io2d/CONTROL @@ -1,4 +1,4 @@ Source: io2d -Version: 0.1-2 +Version: 2019-07-11-1 Description: a lightweight, cross platform drawing library -Build-Depends: cairo (!osx), graphicsmagick (!osx) +Build-Depends: cairo (!osx), cairo[x11] (linux), graphicsmagick (!osx) diff --git a/ports/io2d/find-package.patch b/ports/io2d/find-package.patch deleted file mode 100644 index 10d83f95b..000000000 --- a/ports/io2d/find-package.patch +++ /dev/null @@ -1,47 +0,0 @@ -diff --git a/P0267_RefImpl/P0267_RefImpl/cairo/CMakeLists.txt b/P0267_RefImpl/P0267_RefImpl/cairo/CMakeLists.txt
-index 3d4791c..1864b7a 100644
---- a/P0267_RefImpl/P0267_RefImpl/cairo/CMakeLists.txt
-+++ b/P0267_RefImpl/P0267_RefImpl/cairo/CMakeLists.txt
-@@ -23,7 +23,15 @@ target_compile_features(io2d_cairo PUBLIC cxx_std_17)
-
- target_link_libraries(io2d_cairo PUBLIC io2d_core)
-
--if(MSVC)
-+if(DEFINED VCPKG_TARGET_TRIPLET)
-+ find_package(unofficial-cairo CONFIG REQUIRED)
-+ set(CAIRO_INCLUDE_DIR)
-+ set(CAIRO_LIB_DEBUG "CAIRO_LIB_DEBUG-NOTFOUND")
-+ set(CAIRO_LIB_RELEASE unofficial::cairo::cairo)
-+ find_package(unofficial-graphicsmagick CONFIG REQUIRED)
-+ set(GRAPHICSMAGICK_INCLUDE_DIR)
-+ set(GRAPHICSMAGICK_LIB unofficial::graphicsmagick::graphicsmagick)
-+elseif(MSVC)
- find_path(CAIRO_INCLUDE_DIR cairo.h)
- find_path(GRAPHICSMAGICK_INCLUDE_DIR magick/api.h)
- find_library(CAIRO_LIB_DEBUG cairod)
-diff --git a/P0267_RefImpl/P0267_RefImpl/cairo/win32/CMakeLists.txt b/P0267_RefImpl/P0267_RefImpl/cairo/win32/CMakeLists.txt
-index abb1501..b7a6e71 100644
---- a/P0267_RefImpl/P0267_RefImpl/cairo/win32/CMakeLists.txt
-+++ b/P0267_RefImpl/P0267_RefImpl/cairo/win32/CMakeLists.txt
-@@ -24,20 +24,7 @@ target_compile_features(io2d_cairo_win32 PUBLIC cxx_std_17)
- target_link_libraries(io2d_cairo_win32 PUBLIC io2d_cairo)
-
- if(MSVC)
-- target_compile_definitions(io2d_cairo_win32 PUBLIC -DUNICODE -D_UNICODE -D_CRT_SECURE_NO_WARNINGS)
--
-- find_library(PIXMAN_LIB pixman-1)
-- find_library(FREETYPE_LIB freetype)
-- find_library(FONTCONFIG_LIB fontconfig)
-- find_library(BZ_LIB bz2)
-- find_library(JPEG_LIB jpeg)
-- find_library(TIFF_LIB tiff)
-- find_library(EXPAT_LIB expat)
-- find_library(LZMA_LIB lzma)
-- find_library(ICONV_LIB libiconv)
-- find_library(CHARSET_LIB libcharset)
--
-- target_link_libraries(io2d_cairo_win32 PUBLIC ${PIXMAN_LIB} ${FREETYPE_LIB} ${FONTCONFIG_LIB} ${BZ_LIB} ${JPEG_LIB} ${TIFF_LIB} ${EXPAT_LIB} ${LZMA_LIB} ${ICONV_LIB} ${CHARSET_LIB})
-+ target_compile_definitions(io2d_cairo_win32 PRIVATE -DUNICODE -D_UNICODE -D_CRT_SECURE_NO_WARNINGS)
- endif()
-
- install(
diff --git a/ports/io2d/fix-linux-build.patch b/ports/io2d/fix-linux-build.patch new file mode 100644 index 000000000..be038fab4 --- /dev/null +++ b/ports/io2d/fix-linux-build.patch @@ -0,0 +1,22 @@ +diff --git a/P0267_RefImpl/P0267_RefImpl/cairo/CMakeLists.txt b/P0267_RefImpl/P0267_RefImpl/cairo/CMakeLists.txt +index 5ebeb6a..d0e9176 100644 +--- a/P0267_RefImpl/P0267_RefImpl/cairo/CMakeLists.txt ++++ b/P0267_RefImpl/P0267_RefImpl/cairo/CMakeLists.txt +@@ -3,7 +3,7 @@ cmake_minimum_required(VERSION 3.8) + project(io2d CXX) + + find_package(Cairo REQUIRED) +-find_package(GraphicsMagick REQUIRED) ++find_package(unofficial-graphicsmagick REQUIRED) + + add_library(io2d_cairo + cairo_renderer-graphicsmagickinit.cpp +@@ -24,7 +24,7 @@ target_include_directories(io2d_cairo PUBLIC + + target_compile_features(io2d_cairo PUBLIC cxx_std_17) + +-target_link_libraries(io2d_cairo PUBLIC io2d_core Cairo::Cairo GraphicsMagick::GraphicsMagick) ++target_link_libraries(io2d_cairo PUBLIC io2d_core Cairo::Cairo unofficial::graphicsmagick::graphicsmagick) + + install( + TARGETS io2d_cairo EXPORT io2d_targets diff --git a/ports/io2d/portfile.cmake b/ports/io2d/portfile.cmake index 3411620f5..da0b23c88 100644 --- a/ports/io2d/portfile.cmake +++ b/ports/io2d/portfile.cmake @@ -1,20 +1,17 @@ - -# Allow use of vcpkg functions include(vcpkg_common_functions) -# For now, io2d is always a static library. vcpkg_check_linkage(ONLY_STATIC_LIBRARY) vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO cpp-io2d/P0267_RefImpl - REF 21ae92c8be6916034e6e18f08aa57899a975dfb0 - SHA512 5b674f98ca7705d6901af339a4189d5ce4f2c3118bfb99430734f355159602f177bc8d1b345c3a2f17947a62547553f7b91747a1f16da063707a4da7f990391d + REF add3c9792dcd3f08c497ae3adafb2a3b5b5fc338 + SHA512 2727342fbb31523583374ab6df6ff7542e80b4f94319cf0f293e8c085711fa10ed312b4fc4b91391112b5e27eaaae519cb4141ea9d4108ffb5b7383a043b38b8 HEAD_REF master - PATCHES find-package.patch + PATCHES + fix-linux-build.patch ) -# Configure the library, using CMake if (VCPKG_CMAKE_SYSTEM_NAME STREQUAL Darwin) set(IO2D_DEFAULT_OPTION "-DIO2D_DEFAULT=COREGRAPHICS_MAC") endif() @@ -29,11 +26,8 @@ vcpkg_configure_cmake( ${IO2D_DEFAULT_OPTION} ) -# Build + install the library, using CMake vcpkg_install_cmake() -# Don't have duplicate header files in both include/ and debug/include/ folders -# (within <vcpkg-root>/installed/io2d_*/, as installed by vcpkg_install_cmake()): file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include) vcpkg_fixup_cmake_targets(CONFIG_PATH lib/cmake/io2d) @@ -49,6 +43,6 @@ if (NOT VCPKG_CMAKE_SYSTEM_NAME STREQUAL Darwin) ") endif() -file(INSTALL ${SOURCE_PATH}/LICENSE.md DESTINATION ${CURRENT_PACKAGES_DIR}/share/io2d RENAME copyright) +file(INSTALL ${SOURCE_PATH}/LICENSE.md DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright) vcpkg_test_cmake(PACKAGE_NAME io2d) |
