From 05e3c1e40572dbc06aa3c46f12bdfef9f73c2b44 Mon Sep 17 00:00:00 2001 From: Ron Olson Date: Thu, 3 Jun 2021 10:12:46 -0500 Subject: [PATCH] Updated to libDispatch-5.4.1 --- asprintf.patch | 104 ----------------------------------------------- libdispatch.spec | 27 ++++++------ sources | 2 +- 3 files changed, 13 insertions(+), 120 deletions(-) delete mode 100644 asprintf.patch diff --git a/asprintf.patch b/asprintf.patch deleted file mode 100644 index 6573607..0000000 --- a/asprintf.patch +++ /dev/null @@ -1,104 +0,0 @@ -diff -Naur ./swift-corelibs-libdispatch-swift-5.3.2-RELEASE-orig/tests/bsdtests.c ./swift-corelibs-libdispatch-swift-5.3.2-RELEASE/tests/bsdtests.c ---- ./swift-corelibs-libdispatch-swift-5.3.2-RELEASE-orig/tests/bsdtests.c 2020-09-02 02:28:48.000000000 -0500 -+++ ./swift-corelibs-libdispatch-swift-5.3.2-RELEASE/tests/bsdtests.c 2021-01-19 11:17:43.952112327 -0600 -@@ -347,8 +347,8 @@ - { - char* actual_str; - char* expected_str; -- asprintf(&actual_str, "%d\t%s", actual, actual ? strerror(actual) : ""); -- asprintf(&expected_str, "%d\t%s", expected, expected ? strerror(expected) : ""); -+ (void)asprintf(&actual_str, "%d\t%s", actual, actual ? strerror(actual) : ""); -+ (void)asprintf(&expected_str, "%d\t%s", expected, expected ? strerror(expected) : ""); - _test_print(file, line, desc, - (actual == expected), "%s", actual_str, "%s", expected_str); - free(actual_str); -@@ -369,8 +369,8 @@ - { - char* actual_str; - char* expected_str; -- asprintf(&actual_str, "%d %s", actual, actual ? mach_error_string(actual) : ""); -- asprintf(&expected_str, "%d %s", expected, expected ? mach_error_string(expected) : ""); -+ (void)asprintf(&actual_str, "%d %s", actual, actual ? mach_error_string(actual) : ""); -+ (void)asprintf(&expected_str, "%d %s", expected, expected ? mach_error_string(expected) : ""); - _test_print(file, line, desc, - (actual == expected), "%s", actual_str, "%s", expected_str); - free(actual_str); -@@ -416,12 +416,12 @@ - if (code != expectedCode) { - char buffer[BUFSIZ]; - CFStringGetCString(errDesc, buffer, sizeof(buffer), kCFStringEncodingUTF8); -- asprintf(&actual_str, "%ld\t%s", code, buffer); -+ (void)asprintf(&actual_str, "%ld\t%s", code, buffer); - } else { -- asprintf(&actual_str, "%ld", code); -+ (void)asprintf(&actual_str, "%ld", code); - } - -- asprintf(&expected_str, "%ld", expectedCode); -+ (void)asprintf(&expected_str, "%ld", expectedCode); - _test_print("", (long) 0, desc, - (code == expectedCode), "%s", actual_str, "%s", expected_str); - -diff -Naur ./swift-corelibs-libdispatch-swift-5.3.2-RELEASE-orig/tests/dispatch_io.c ./swift-corelibs-libdispatch-swift-5.3.2-RELEASE/tests/dispatch_io.c ---- ./swift-corelibs-libdispatch-swift-5.3.2-RELEASE-orig/tests/dispatch_io.c 2020-09-02 02:28:48.000000000 -0500 -+++ ./swift-corelibs-libdispatch-swift-5.3.2-RELEASE/tests/dispatch_io.c 2021-01-19 11:19:09.286850562 -0600 -@@ -255,7 +255,7 @@ - test_stop(); - } - char *path_out = NULL; -- asprintf(&path_out, "%s\\dispatchtest_io.XXXXXX", temp_dir); -+ (void)asprintf(&path_out, "%s\\dispatchtest_io.XXXXXX", temp_dir); - #else - char path_out[] = "/tmp/dispatchtest_io.XXXXXX"; - #endif -@@ -486,7 +486,7 @@ - #if defined(_WIN32) - for (size_t i = 0; paths[i]; i++) { - char *search_path = NULL; -- asprintf(&search_path, "%s\\*", paths[i]); -+ (void)asprintf(&search_path, "%s\\*", paths[i]); - WIN32_FIND_DATAA node; - HANDLE find = FindFirstFileA(search_path, &node); - free(search_path); -@@ -503,7 +503,7 @@ - continue; - } - char *node_path = NULL; -- asprintf(&node_path, "%s\\%s", paths[i], node.cFileName); -+ (void)asprintf(&node_path, "%s\\%s", paths[i], node.cFileName); - if (node.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) { - char *subdir_paths[] = {node_path, NULL}; - test_enumerate_dir_trees(subdir_paths, process_file); -@@ -590,7 +590,7 @@ - test_ptr_notnull("SystemRoot", system_root); - test_stop(); - } -- asprintf(&paths[0], "%s\\System32", system_root); -+ (void)asprintf(&paths[0], "%s\\System32", system_root); - #else - char *paths[] = {"/usr/lib", NULL}; - #endif -diff -Naur ./swift-corelibs-libdispatch-swift-5.3.2-RELEASE-orig/tests/dispatch_io_muxed.c ./swift-corelibs-libdispatch-swift-5.3.2-RELEASE/tests/dispatch_io_muxed.c ---- ./swift-corelibs-libdispatch-swift-5.3.2-RELEASE-orig/tests/dispatch_io_muxed.c 2020-09-02 02:28:48.000000000 -0500 -+++ ./swift-corelibs-libdispatch-swift-5.3.2-RELEASE/tests/dispatch_io_muxed.c 2021-01-19 11:18:19.122416587 -0600 -@@ -64,7 +64,7 @@ - const char *path_separator = "/"; - #endif - char *path = NULL; -- asprintf(&path, "%s%sdispatchtest_io.XXXXXX", temp_dir, path_separator); -+ (void)asprintf(&path, "%s%sdispatchtest_io.XXXXXX", temp_dir, path_separator); - dispatch_fd_t fd = mkstemp(path); - if (fd == -1) { - test_errno("mkstemp", errno, 0); -diff -Naur ./swift-corelibs-libdispatch-swift-5.3.2-RELEASE-orig/tests/dispatch_overcommit.c ./swift-corelibs-libdispatch-swift-5.3.2-RELEASE/tests/dispatch_overcommit.c ---- ./swift-corelibs-libdispatch-swift-5.3.2-RELEASE-orig/tests/dispatch_overcommit.c 2020-09-02 02:28:48.000000000 -0500 -+++ ./swift-corelibs-libdispatch-swift-5.3.2-RELEASE/tests/dispatch_overcommit.c 2021-01-19 11:16:37.385536454 -0600 -@@ -48,7 +48,7 @@ - int i; - for (i = 0; i < final; ++i) { - char* name; -- asprintf(&name, "test.overcommit.%d", i); -+ (void)asprintf(&name, "test.overcommit.%d", i); - - dispatch_queue_t queue = dispatch_queue_create(name, NULL); - test_ptr_notnull("dispatch_queue_create", queue); diff --git a/libdispatch.spec b/libdispatch.spec index f5ea23b..8394d6d 100644 --- a/libdispatch.spec +++ b/libdispatch.spec @@ -1,18 +1,15 @@ -%global toolchain clang -%global reltag 5.3.3-RELEASE - +%global debug_package %{nil} +%global reltag 5.4.1-RELEASE Name: libdispatch -Version: 5.3.3 -Release: 2%{?dist} +Version: 5.4.1 +Release: 1%{?dist} Summary: Apple's Grand Central Dispatch library License: ASL 2.0 URL: https://github.com/apple/swift-corelibs-libdispatch Source0: https://github.com/apple/swift-corelibs-libdispatch/archive/swift-%{reltag}.tar.gz#/corelibs-libdispatch.tar.gz -Patch0: asprintf.patch - BuildRequires: clang BuildRequires: libbsd-devel BuildRequires: ninja-build @@ -59,16 +56,13 @@ Development files for libdispatch %prep %setup -q -n swift-corelibs-libdispatch-swift-%{reltag} -%patch0 -p2 - %build -%cmake -G Ninja . -%cmake_build - +cmake -G Ninja -DCMAKE_INSTALL_PREFIX=%{buildroot}%{_usr} -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ . +ninja %install -%cmake_install +ninja install chrpath --delete %{buildroot}%{_libdir}/libdispatch.so @@ -86,7 +80,10 @@ chrpath --delete %{buildroot}%{_libdir}/libdispatch.so %changelog -* Mon Feb 08 2021 Ron Olson 5.3.3-2 -- Fixed issue with devel package not finding parent +* Tue Jun 01 2021 Ron Olson 5.4.1-1 +- Updated to 5.4.1-RELEASE +* Sat May 01 2021 Ron Olson 5.4-1 +- Updated to 5.4-RELEASE also added explicit CMake step + for EPEL8 * Wed Feb 03 2021 Ron Olson 5.3.3-1 - Initial version based on version 5.3.3-RELEASE diff --git a/sources b/sources index f362882..81b5909 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (corelibs-libdispatch.tar.gz) = b76071e8fac19ef5aed8cb3998b903a17a4f2b9e6b992d22d394212f4d48c4a547fb7a8cf16e4ce2ef17d6b58e253c2d52c6b176c3a874132410215b73332909 +SHA512 (corelibs-libdispatch.tar.gz) = a6ce5381d3776db5884ed691e2c22c0563da69cd3925c10f9de089a7f0e33dcbaec9d3afea4d58fa5cae819d104f9db7e81241b31ccc1bf8218d7923b2811a62