diff --git a/devel/libdispatch/Makefile b/devel/libdispatch/Makefile index a082726bcf5b..9e985699fd3c 100644 --- a/devel/libdispatch/Makefile +++ b/devel/libdispatch/Makefile @@ -1,35 +1,35 @@ PORTNAME= libdispatch -DISTVERSION= 5.10.1 +DISTVERSION= 6.0.3 PORTEPOCH= 1 CATEGORIES= devel MAINTAINER= fluffy@FreeBSD.org COMMENT= Grand Central Dispatch API support library LICENSE= APACHE20 USES= cmake:testing compiler:c++17-lang USE_LDCONFIG= yes USE_CXXSTD= c++17 USE_GITHUB= yes GH_ACCOUNT= apple GH_PROJECT= swift-corelibs-libdispatch GH_TAGNAME= swift-${DISTVERSION}-RELEASE .include #.if ${OPSYS} == FreeBSD && ${OSVERSION} >= 1400000 && ${OSVERSION} < 1400079 #USES+= llvm:max=17,build #USES:= ${USES:Ncompiler\:*} # XXX avoid warnings #CC= ${_LLVM_MK_PREFIX}/bin/clang #CPP= ${_LLVM_MK_PREFIX}/bin/clang-cpp #CXX= ${_LLVM_MK_PREFIX}/bin/clang++ #LD?= ${_LLVM_MK_PREFIX}/bin/ld #.endif .if ${OPSYS} == FreeBSD && (${ARCH} == armv7 || ${ARCH} == i386 || ${ARCH} == powerpc) CFLAGS+= -Wno-incompatible-function-pointer-types .endif .include diff --git a/devel/libdispatch/distinfo b/devel/libdispatch/distinfo index b4d34f8de82d..65560e992d63 100644 --- a/devel/libdispatch/distinfo +++ b/devel/libdispatch/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1723281605 -SHA256 (apple-swift-corelibs-libdispatch-5.10.1-swift-5.10.1-RELEASE_GH0.tar.gz) = affa3544b0fdb60f8f175bc0d2846177436d5848ef8ca73e3e560d23986f38b3 -SIZE (apple-swift-corelibs-libdispatch-5.10.1-swift-5.10.1-RELEASE_GH0.tar.gz) = 594770 +TIMESTAMP = 1737150009 +SHA256 (apple-swift-corelibs-libdispatch-6.0.3-swift-6.0.3-RELEASE_GH0.tar.gz) = 444c0de5fe18e148548a3f3b60b3bac3d4d586285c21064346c7ca17ed1d4fac +SIZE (apple-swift-corelibs-libdispatch-6.0.3-swift-6.0.3-RELEASE_GH0.tar.gz) = 595115 diff --git a/devel/libdispatch/files/patch-CMakeLists.txt b/devel/libdispatch/files/patch-CMakeLists.txt new file mode 100644 index 000000000000..0460f0e62c51 --- /dev/null +++ b/devel/libdispatch/files/patch-CMakeLists.txt @@ -0,0 +1,13 @@ +--- CMakeLists.txt.orig 2024-06-13 00:13:26 UTC ++++ CMakeLists.txt +@@ -187,6 +187,10 @@ endif() + find_package(LibRT) + endif() + ++if(CMAKE_SYSTEM_NAME STREQUAL FreeBSD) ++ find_package(BlocksRuntime) ++endif() ++ + check_function_exists(_pthread_workqueue_init HAVE__PTHREAD_WORKQUEUE_INIT) + check_function_exists(getprogname HAVE_GETPROGNAME) + check_function_exists(mach_absolute_time HAVE_MACH_ABSOLUTE_TIME) diff --git a/devel/libdispatch/files/patch-cmake_modules_DispatchCompilerWarnings.cmake b/devel/libdispatch/files/patch-cmake_modules_DispatchCompilerWarnings.cmake index bc8ec4df8ca5..91a0b3738997 100644 --- a/devel/libdispatch/files/patch-cmake_modules_DispatchCompilerWarnings.cmake +++ b/devel/libdispatch/files/patch-cmake_modules_DispatchCompilerWarnings.cmake @@ -1,10 +1,10 @@ ---- cmake/modules/DispatchCompilerWarnings.cmake.orig 2021-09-17 04:54:52 UTC +--- cmake/modules/DispatchCompilerWarnings.cmake.orig 2024-06-13 00:13:26 UTC +++ cmake/modules/DispatchCompilerWarnings.cmake -@@ -2,7 +2,6 @@ else() - if("${CMAKE_C_SIMULATE_ID}" STREQUAL "MSVC") - # TODO: someone needs to provide the msvc equivalent warning flags +@@ -6,7 +6,6 @@ else() + # so that we can use __popcnt64 + add_compile_options($<$,$>:-fms-extensions>) else() - add_compile_options($<$,$>:-Werror>) add_compile_options($<$,$>:-Wall>) add_compile_options($<$,$>:-Wextra>) diff --git a/devel/libdispatch/files/patch-cmake_modules_FindBlocksRuntime.cmake b/devel/libdispatch/files/patch-cmake_modules_FindBlocksRuntime.cmake new file mode 100644 index 000000000000..1158b5c700ff --- /dev/null +++ b/devel/libdispatch/files/patch-cmake_modules_FindBlocksRuntime.cmake @@ -0,0 +1,20 @@ +--- cmake/modules/FindBlocksRuntime.cmake.orig 2024-06-13 00:13:26 UTC ++++ cmake/modules/FindBlocksRuntime.cmake +@@ -17,14 +17,14 @@ else() + else() + find_path(BlocksRuntime_INCLUDE_DIR + NAMES +- Blocks.h ++ Block.h + HINTS +- ${CMAKE_INSTALL_FULL_INCLUDEDIR}) ++ /usr/include ${CMAKE_INSTALL_FULL_INCLUDEDIR}) + find_library(BlocksRuntime_LIBRARIES + NAMES + BlocksRuntime libBlocksRuntime + HINTS +- ${CMAKE_INSTALL_FULL_LIBDIR}) ++ /usr/lib ${CMAKE_INSTALL_FULL_LIBDIR}) + + include(FindPackageHandleStandardArgs) + find_package_handle_standard_args(BlocksRuntime diff --git a/devel/libdispatch/files/patch-src_CMakeLists.txt b/devel/libdispatch/files/patch-src_CMakeLists.txt index ee85289310eb..5774cceae846 100644 --- a/devel/libdispatch/files/patch-src_CMakeLists.txt +++ b/devel/libdispatch/files/patch-src_CMakeLists.txt @@ -1,11 +1,30 @@ ---- src/CMakeLists.txt.orig 2021-09-17 04:54:52 UTC +--- src/CMakeLists.txt.orig 2024-06-13 00:13:26 UTC +++ src/CMakeLists.txt -@@ -127,7 +127,7 @@ target_compile_options(dispatch PRIVATE -fblocks) +@@ -1,6 +1,6 @@ if(NOT CMAKE_SYSTEM_NAME STREQUAL Darwin) + + if(NOT CMAKE_SYSTEM_NAME STREQUAL Darwin) +- add_subdirectory(BlocksRuntime) ++# add_subdirectory(BlocksRuntime) + endif() + + add_library(dispatch +@@ -145,7 +145,7 @@ target_compile_options(dispatch PRIVATE -fblocks) # FIXME(compnerd) add check for -fblocks? target_compile_options(dispatch PRIVATE -fblocks) -check_c_compiler_flag("-momit-leaf-frame-pointer -Werror -Wall -O3" C_SUPPORTS_OMIT_LEAF_FRAME_POINTER) +check_c_compiler_flag("-momit-leaf-frame-pointer -Wall" C_SUPPORTS_OMIT_LEAF_FRAME_POINTER) if (C_SUPPORTS_OMIT_LEAF_FRAME_POINTER) target_compile_options(dispatch PRIVATE -momit-leaf-frame-pointer) endif() +@@ -176,6 +176,10 @@ if(NOT CMAKE_SYSTEM_NAME MATCHES "Darwin|Windows") + + if(NOT CMAKE_SYSTEM_NAME MATCHES "Darwin|Windows") + set_target_properties(dispatch PROPERTIES INSTALL_RPATH "$ORIGIN") ++ set_target_properties(dispatch PROPERTIES ++ VERSION ${PROJECT_VERSION} ++ SOVERSION ${PROJECT_VERSION_MAJOR} ++ EXPORT_NAME dispatch ) + endif() + + if(ENABLE_SWIFT) diff --git a/devel/libdispatch/pkg-plist b/devel/libdispatch/pkg-plist index 33b2867e0f47..5443b321d338 100644 --- a/devel/libdispatch/pkg-plist +++ b/devel/libdispatch/pkg-plist @@ -1,36 +1,38 @@ -include/Block.h +@comment include/Block.h include/dispatch/base.h include/dispatch/block.h include/dispatch/data.h include/dispatch/dispatch.h include/dispatch/group.h include/dispatch/introspection.h include/dispatch/io.h include/dispatch/object.h include/dispatch/once.h include/dispatch/queue.h include/dispatch/semaphore.h include/dispatch/source.h include/dispatch/time.h include/os/generic_base.h include/os/generic_unix_base.h include/os/generic_win_base.h include/os/object.h -lib/libBlocksRuntime.so +@comment lib/libBlocksRuntime.so lib/libdispatch.so +lib/libdispatch.so.1 +lib/libdispatch.so.1.3 share/man/man3/dispatch.3.gz share/man/man3/dispatch_after.3.gz share/man/man3/dispatch_api.3.gz share/man/man3/dispatch_apply.3.gz share/man/man3/dispatch_async.3.gz share/man/man3/dispatch_data_create.3.gz share/man/man3/dispatch_group_create.3.gz share/man/man3/dispatch_io_create.3.gz share/man/man3/dispatch_io_read.3.gz share/man/man3/dispatch_object.3.gz share/man/man3/dispatch_once.3.gz share/man/man3/dispatch_queue_create.3.gz share/man/man3/dispatch_read.3.gz share/man/man3/dispatch_semaphore_create.3.gz share/man/man3/dispatch_source_create.3.gz share/man/man3/dispatch_time.3.gz