Date: Tuesday, August 16, 2022 @ 14:00:41 Author: dvzrv Revision: 453001
upgpkg: libgit2 1:1.5.0-1: Upgrade to 1.5.0. Apply cmake package guidelines. Disable broken tests and those requiring the internet. Update patch to remove tests incompatible with upstream http-parser. Added: libgit2/trunk/libgit2-1.5.0-remove_http-parse_incompatible_tests.patch Modified: libgit2/trunk/PKGBUILD Deleted: libgit2/trunk/libgit2-1.2.0-remove_http-parse_incompatible_tests.patch ----------------------------------------------------------+ PKGBUILD | 21 +- libgit2-1.2.0-remove_http-parse_incompatible_tests.patch | 117 ------------- libgit2-1.5.0-remove_http-parse_incompatible_tests.patch | 117 +++++++++++++ 3 files changed, 128 insertions(+), 127 deletions(-) Modified: PKGBUILD =================================================================== --- PKGBUILD 2022-08-16 10:09:40 UTC (rev 453000) +++ PKGBUILD 2022-08-16 14:00:41 UTC (rev 453001) @@ -4,7 +4,7 @@ # Contributor: Dave Reisner <d...@falconindy.com> pkgname=libgit2 -pkgver=1.4.4 +pkgver=1.5.0 pkgrel=1 epoch=1 pkgdesc="A linkable library for Git" @@ -17,17 +17,17 @@ options=(debug) source=( $pkgname-$pkgver.tar.gz::https://github.com/$pkgname/$pkgname/archive/v$pkgver.tar.gz - $pkgname-1.2.0-remove_http-parse_incompatible_tests.patch + $pkgname-1.5.0-remove_http-parse_incompatible_tests.patch ) -sha512sums=('8f4cc43de9b92866ac12e01613efe0ff808deca29ff82b6da98a38c814bb711ff3133145d0219210af7015955fbe381be6f1cb98915811d3c37e92b01eb522e9' - '01bf3a960b2e6d441017af363bff267bd1513915ebefda95012d7feb38f7020778ea0908664cc479da82f441a4dd2788772005006a9c19e87cfc234268dc3785') -b2sums=('2668e351521e1cd9d2998c45c65e2a8c30f3436d94f86ebaa10382d01afb136bbde28c71d359fb57757ebbd44b1cef1bacd302023d0803a23697aee10f03ebac' - 'e725fb41c9bdfd9952693c9c47be90c10a16a78ab91f80e74c40c5510a83325575ce95674a2e21282e9c300f2bc8d430c896fa379ef744b8a8a912729fa88827') +sha512sums=('7a32b27cd32bd03ce7be6c127317f82a4ac6f16615c3234699676781f4858d057edb0410b2fe36fd2e634b00748a8b0be17f23809e09a7602ba48185134300f7' + 'f9bb9ad7eb0f43003f5f72c81575ef5751b893fdf257d888b56818ee2c136b496b7cf72627a53dbd01319e33d0dd373e9d6df887360f7bec367419ef0c7ab711') +b2sums=('4108de0e8fc6a02e4172f47cb69cdfe8c85a0a72235432ca58b02d94e0bcb8390caf0c710060772551cc3a392291778ae14b561256c6d88058d0ae5a277f2fbf' + 'b3c2386ba84664318573e5c24797d28db914d60782397d8b39a21b54b4fb19502945fa8fcc0d8bbe8949349b5ec705d3e1345b0cbbb51b7d9631fec922f3ac41') prepare() { # remove tests that are only compatible with the (modified) vendored version # of http-parser, but not with upstream http-parser - patch -d $pkgname-$pkgver -Np1 -i ../$pkgname-1.2.0-remove_http-parse_incompatible_tests.patch + patch -d $pkgname-$pkgver -Np1 -i ../$pkgname-1.5.0-remove_http-parse_incompatible_tests.patch } build() { @@ -39,16 +39,17 @@ -Wno-dev \ -B build \ -S $pkgname-$pkgver - make VERBOSE=1 -C build + cmake --build build } check() { - make VERBOSE=1 test -C build + # NOTE: disable tests requiring the internet and relying on non-existent resources + ctest --test-dir build --output-on-failure -E "invasive|online" } package() { depends+=(libssh2.so) - make VERBOSE=1 DESTDIR="$pkgdir" install -C build + DESTDIR="$pkgdir" cmake --install build install -vDm 644 $pkgname-$pkgver/{AUTHORS,README.md} -t "$pkgdir/usr/share/doc/$pkgname" } Deleted: libgit2-1.2.0-remove_http-parse_incompatible_tests.patch =================================================================== --- libgit2-1.2.0-remove_http-parse_incompatible_tests.patch 2022-08-16 10:09:40 UTC (rev 453000) +++ libgit2-1.2.0-remove_http-parse_incompatible_tests.patch 2022-08-16 14:00:41 UTC (rev 453001) @@ -1,117 +0,0 @@ -diff -ruN a/tests/network/url/parse.c b/tests/network/url/parse.c ---- a/tests/network/url/parse.c 2021-09-02 05:06:19.000000000 +0200 -+++ b/tests/network/url/parse.c 2021-09-10 09:17:34.775074427 +0200 -@@ -63,18 +63,6 @@ - cl_assert_equal_i(git_net_url_is_default_port(&conndata), 0); - } - --void test_network_url_parse__hostname_implied_root_empty_port(void) --{ -- cl_git_pass(git_net_url_parse(&conndata, "http://example.com:")); -- cl_assert_equal_s(conndata.scheme, "http"); -- cl_assert_equal_s(conndata.host, "example.com"); -- cl_assert_equal_s(conndata.port, "80"); -- cl_assert_equal_s(conndata.path, "/"); -- cl_assert_equal_p(conndata.username, NULL); -- cl_assert_equal_p(conndata.password, NULL); -- cl_assert_equal_i(git_net_url_is_default_port(&conndata), 1); --} -- - void test_network_url_parse__hostname_encoded_password(void) - { - cl_git_pass(git_net_url_parse(&conndata, -@@ -129,18 +117,6 @@ - cl_assert_equal_i(git_net_url_is_default_port(&conndata), 0); - } - --void test_network_url_parse__hostname_empty_port(void) --{ -- cl_git_pass(git_net_url_parse(&conndata, "http://example.com:/resource")); -- cl_assert_equal_s(conndata.scheme, "http"); -- cl_assert_equal_s(conndata.host, "example.com"); -- cl_assert_equal_s(conndata.port, "80"); -- cl_assert_equal_s(conndata.path, "/resource"); -- cl_assert_equal_p(conndata.username, NULL); -- cl_assert_equal_p(conndata.password, NULL); -- cl_assert_equal_i(git_net_url_is_default_port(&conndata), 1); --} -- - void test_network_url_parse__hostname_user_port(void) - { - /* u...@hostname.tld:port/resource */ -@@ -219,18 +195,6 @@ - cl_assert_equal_i(git_net_url_is_default_port(&conndata), 0); - } - --void test_network_url_parse__ipv4_implied_root_empty_port(void) --{ -- cl_git_pass(git_net_url_parse(&conndata, "http://192.168.1.1:")); -- cl_assert_equal_s(conndata.scheme, "http"); -- cl_assert_equal_s(conndata.host, "192.168.1.1"); -- cl_assert_equal_s(conndata.port, "80"); -- cl_assert_equal_s(conndata.path, "/"); -- cl_assert_equal_p(conndata.username, NULL); -- cl_assert_equal_p(conndata.password, NULL); -- cl_assert_equal_i(git_net_url_is_default_port(&conndata), 1); --} -- - void test_network_url_parse__ipv4_encoded_password(void) - { - cl_git_pass(git_net_url_parse(&conndata, -@@ -283,18 +247,6 @@ - cl_assert_equal_i(git_net_url_is_default_port(&conndata), 0); - } - --void test_network_url_parse__ipv4_empty_port(void) --{ -- cl_git_pass(git_net_url_parse(&conndata, "http://192.168.1.1:/resource")); -- cl_assert_equal_s(conndata.scheme, "http"); -- cl_assert_equal_s(conndata.host, "192.168.1.1"); -- cl_assert_equal_s(conndata.port, "80"); -- cl_assert_equal_s(conndata.path, "/resource"); -- cl_assert_equal_p(conndata.username, NULL); -- cl_assert_equal_p(conndata.password, NULL); -- cl_assert_equal_i(git_net_url_is_default_port(&conndata), 1); --} -- - void test_network_url_parse__ipv4_user_port(void) - { - cl_git_pass(git_net_url_parse(&conndata, -@@ -371,18 +323,6 @@ - cl_assert_equal_i(git_net_url_is_default_port(&conndata), 0); - } - --void test_network_url_parse__ipv6_implied_root_empty_port(void) --{ -- cl_git_pass(git_net_url_parse(&conndata, "http://[fe80::dcad:beff:fe00:0001]:")); -- cl_assert_equal_s(conndata.scheme, "http"); -- cl_assert_equal_s(conndata.host, "fe80::dcad:beff:fe00:0001"); -- cl_assert_equal_s(conndata.port, "80"); -- cl_assert_equal_s(conndata.path, "/"); -- cl_assert_equal_p(conndata.username, NULL); -- cl_assert_equal_p(conndata.password, NULL); -- cl_assert_equal_i(git_net_url_is_default_port(&conndata), 1); --} -- - void test_network_url_parse__ipv6_encoded_password(void) - { - cl_git_pass(git_net_url_parse(&conndata, -@@ -435,18 +375,6 @@ - cl_assert_equal_i(git_net_url_is_default_port(&conndata), 0); - } - --void test_network_url_parse__ipv6_empty_port(void) --{ -- cl_git_pass(git_net_url_parse(&conndata, "http://[fe80::dcad:beff:fe00:0001]:/resource")); -- cl_assert_equal_s(conndata.scheme, "http"); -- cl_assert_equal_s(conndata.host, "fe80::dcad:beff:fe00:0001"); -- cl_assert_equal_s(conndata.port, "80"); -- cl_assert_equal_s(conndata.path, "/resource"); -- cl_assert_equal_p(conndata.username, NULL); -- cl_assert_equal_p(conndata.password, NULL); -- cl_assert_equal_i(git_net_url_is_default_port(&conndata), 1); --} -- - void test_network_url_parse__ipv6_user_port(void) - { - cl_git_pass(git_net_url_parse(&conndata, Added: libgit2-1.5.0-remove_http-parse_incompatible_tests.patch =================================================================== --- libgit2-1.5.0-remove_http-parse_incompatible_tests.patch (rev 0) +++ libgit2-1.5.0-remove_http-parse_incompatible_tests.patch 2022-08-16 14:00:41 UTC (rev 453001) @@ -0,0 +1,117 @@ +diff -ruN a/tests/libgit2/network/url/parse.c b/tests/libgit2/network/url/parse.c +--- a/tests/libgit2/network/url/parse.c 2022-07-14 02:06:59.000000000 +0200 ++++ b/tests/libgit2/network/url/parse.c 2022-08-07 14:28:45.012518372 +0200 +@@ -63,18 +63,6 @@ + cl_assert_equal_i(git_net_url_is_default_port(&conndata), 0); + } + +-void test_network_url_parse__hostname_implied_root_empty_port(void) +-{ +- cl_git_pass(git_net_url_parse(&conndata, "http://example.com:")); +- cl_assert_equal_s(conndata.scheme, "http"); +- cl_assert_equal_s(conndata.host, "example.com"); +- cl_assert_equal_s(conndata.port, "80"); +- cl_assert_equal_s(conndata.path, "/"); +- cl_assert_equal_p(conndata.username, NULL); +- cl_assert_equal_p(conndata.password, NULL); +- cl_assert_equal_i(git_net_url_is_default_port(&conndata), 1); +-} +- + void test_network_url_parse__hostname_encoded_password(void) + { + cl_git_pass(git_net_url_parse(&conndata, +@@ -129,18 +117,6 @@ + cl_assert_equal_i(git_net_url_is_default_port(&conndata), 0); + } + +-void test_network_url_parse__hostname_empty_port(void) +-{ +- cl_git_pass(git_net_url_parse(&conndata, "http://example.com:/resource")); +- cl_assert_equal_s(conndata.scheme, "http"); +- cl_assert_equal_s(conndata.host, "example.com"); +- cl_assert_equal_s(conndata.port, "80"); +- cl_assert_equal_s(conndata.path, "/resource"); +- cl_assert_equal_p(conndata.username, NULL); +- cl_assert_equal_p(conndata.password, NULL); +- cl_assert_equal_i(git_net_url_is_default_port(&conndata), 1); +-} +- + void test_network_url_parse__hostname_user_port(void) + { + /* u...@hostname.tld:port/resource */ +@@ -219,18 +195,6 @@ + cl_assert_equal_i(git_net_url_is_default_port(&conndata), 0); + } + +-void test_network_url_parse__ipv4_implied_root_empty_port(void) +-{ +- cl_git_pass(git_net_url_parse(&conndata, "http://192.168.1.1:")); +- cl_assert_equal_s(conndata.scheme, "http"); +- cl_assert_equal_s(conndata.host, "192.168.1.1"); +- cl_assert_equal_s(conndata.port, "80"); +- cl_assert_equal_s(conndata.path, "/"); +- cl_assert_equal_p(conndata.username, NULL); +- cl_assert_equal_p(conndata.password, NULL); +- cl_assert_equal_i(git_net_url_is_default_port(&conndata), 1); +-} +- + void test_network_url_parse__ipv4_encoded_password(void) + { + cl_git_pass(git_net_url_parse(&conndata, +@@ -283,18 +247,6 @@ + cl_assert_equal_i(git_net_url_is_default_port(&conndata), 0); + } + +-void test_network_url_parse__ipv4_empty_port(void) +-{ +- cl_git_pass(git_net_url_parse(&conndata, "http://192.168.1.1:/resource")); +- cl_assert_equal_s(conndata.scheme, "http"); +- cl_assert_equal_s(conndata.host, "192.168.1.1"); +- cl_assert_equal_s(conndata.port, "80"); +- cl_assert_equal_s(conndata.path, "/resource"); +- cl_assert_equal_p(conndata.username, NULL); +- cl_assert_equal_p(conndata.password, NULL); +- cl_assert_equal_i(git_net_url_is_default_port(&conndata), 1); +-} +- + void test_network_url_parse__ipv4_user_port(void) + { + cl_git_pass(git_net_url_parse(&conndata, +@@ -371,18 +323,6 @@ + cl_assert_equal_i(git_net_url_is_default_port(&conndata), 0); + } + +-void test_network_url_parse__ipv6_implied_root_empty_port(void) +-{ +- cl_git_pass(git_net_url_parse(&conndata, "http://[fe80::dcad:beff:fe00:0001]:")); +- cl_assert_equal_s(conndata.scheme, "http"); +- cl_assert_equal_s(conndata.host, "fe80::dcad:beff:fe00:0001"); +- cl_assert_equal_s(conndata.port, "80"); +- cl_assert_equal_s(conndata.path, "/"); +- cl_assert_equal_p(conndata.username, NULL); +- cl_assert_equal_p(conndata.password, NULL); +- cl_assert_equal_i(git_net_url_is_default_port(&conndata), 1); +-} +- + void test_network_url_parse__ipv6_encoded_password(void) + { + cl_git_pass(git_net_url_parse(&conndata, +@@ -435,18 +375,6 @@ + cl_assert_equal_i(git_net_url_is_default_port(&conndata), 0); + } + +-void test_network_url_parse__ipv6_empty_port(void) +-{ +- cl_git_pass(git_net_url_parse(&conndata, "http://[fe80::dcad:beff:fe00:0001]:/resource")); +- cl_assert_equal_s(conndata.scheme, "http"); +- cl_assert_equal_s(conndata.host, "fe80::dcad:beff:fe00:0001"); +- cl_assert_equal_s(conndata.port, "80"); +- cl_assert_equal_s(conndata.path, "/resource"); +- cl_assert_equal_p(conndata.username, NULL); +- cl_assert_equal_p(conndata.password, NULL); +- cl_assert_equal_i(git_net_url_is_default_port(&conndata), 1); +-} +- + void test_network_url_parse__ipv6_user_port(void) + { + cl_git_pass(git_net_url_parse(&conndata,