Merge pull request #2366 from blshkv/master

usbmuxd/
This commit is contained in:
github-actions[bot] 2025-06-03 11:14:29 +00:00 committed by GitHub
commit 3bc3c19ef4
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
15 changed files with 0 additions and 1042 deletions

View file

@ -1,3 +0,0 @@
DIST libplist-2.5.0.tar.bz2 155847 BLAKE2B b6530f0732db28759df160e77cf61a23c6b97c5e1d1aed7797fd4771bbe96be40f9ffe477c9cd3470e71280572559ece7868b0098d0472de84bf915502a05b71 SHA512 95bed7111b54a59331933491c1f0b8eb6eb2ab3b8958ca63166ae21cf8430a8b2badca2968b45ac90b8d0672e4035ac92969100881daaefc0339daf45dc49268
DIST libplist-2.6.0.tar.bz2 155575 BLAKE2B cee4d00eff0b7393f34dc0b1fdb1e473bbb849ac2a8b243bcc97bfbee36a884b5574b662fa5a1a2b9c86c4c03cf0be2b2b0c09a0008b64e8b2f564349bc6df54 SHA512 4e9f301979e57230d016acabb84b9c032e934bbb5d755aa4f374d477472340af35632c3080c480a140d1aafbe32df88a950ebae3f062bfe2aaad2935f063e6b6
DIST libplist-2.7.0.tar.bz2 484474 BLAKE2B 4ee37be5f39eeefb5273214fb211385fba1c23565c16b4a8a984bcf3ef8aa8c923d8d681a66979709f1e810b28bdccde4ae6864a5f7afdefdb0290ed9a8b29bd SHA512 83d0398b75ea9e610e49b4b96a7675b854c7551d4faf3e82e74c5c45cf04bbd95478cc40688f0995742e6a50601744d2a36641d0673aa7cc413f5ce2ec42f2d4

View file

@ -1,34 +0,0 @@
--- a/configure.ac
+++ b/configure.ac
@@ -79,19 +79,7 @@
esac
AM_CONDITIONAL(WIN32, test x$win32 = xtrue)
-# Check if we need libm for fmin
-CACHED_CFLAGS="$CFLAGS"
-CFLAGS="-O0"
-AC_CACHE_CHECK(if fmin is a builtin function, ac_cv_fmin_builtin,
- AC_TRY_LINK([
- #include <math.h>
- #include <float.h>
- ], [
- double val = 3.1415f * 0.55555f;
- double diff = fmin(val, DBL_MAX);
- if (diff > 0) return 1;
- ], ac_cv_fmin_builtin=yes, ac_cv_fmin_builtin=no))
-CFLAGS="$CACHED_CFLAGS"
+AC_SEARCH_LIBS([fmin],[m])
# Check if struct tm has a tm_gmtoff member
AC_CACHE_CHECK(for tm_gmtoff in struct tm, ac_cv_struct_tm_gmtoff,
@@ -153,10 +141,6 @@
AS_COMPILER_FLAGS(GLOBAL_CFLAGS, "-Wall -Wextra -Wredundant-decls -Wshadow -Wpointer-arith -Wwrite-strings -Wswitch-default -Wno-unused-parameter -Wno-strict-aliasing -fvisibility=hidden $PTHREAD_CFLAGS")
GLOBAL_LDFLAGS="$PTHREAD_LIBS"
-if test "x$ac_cv_fmin_builtin" != "xyes"; then
- GLOBAL_LDFLAGS+=" -lm"
-fi
-
AC_ARG_ENABLE(debug,
AS_HELP_STRING([--enable-debug],
[build debug message output code (default is no)]),

View file

@ -1,9 +0,0 @@
--- a/src/libplist-2.0.pc.in
+++ b/src/libplist-2.0.pc.in
@@ -6,5 +6,5 @@
Name: @PACKAGE_NAME@
Description: A library to handle Apple Property Lists whereas they are binary or XML
Version: @PACKAGE_VERSION@
-Libs: -L${libdir} -lplist-2.0
+Libs: -L${libdir} -lplist-2.0 -lplist
Cflags: -I${includedir}

View file

@ -1,32 +0,0 @@
https://bugs.gentoo.org/854837
https://github.com/libimobiledevice/libplist/pull/212
--- a/src/bplist.c
+++ b/src/bplist.c
@@ -998,18 +998,24 @@ static void write_real(bytearray_t * bplist, double val)
buff[7] = BPLIST_REAL | Log2(size);
if (size == sizeof(float)) {
float floatval = (float)val;
- *(uint32_t*)(buff+8) = float_bswap32(*(uint32_t*)&floatval);
+ uint32_t intval;
+ memcpy(&intval, &floatval, sizeof(float));
+ *(uint32_t*)(buff+8) = float_bswap32(intval);
} else {
- *(uint64_t*)(buff+8) = float_bswap64(*(uint64_t*)&val);
+ uint64_t intval;
+ memcpy(&intval, &val, sizeof(double));
+ *(uint64_t*)(buff+8) = float_bswap64(intval);
}
byte_array_append(bplist, buff+7, size+1);
}
static void write_date(bytearray_t * bplist, double val)
{
+ uint64_t intval;
+ memcpy(&intval, &val, sizeof(double));
uint8_t buff[16];
buff[7] = BPLIST_DATE | 3;
- *(uint64_t*)(buff+8) = float_bswap64(*(uint64_t*)&val);
+ *(uint64_t*)(buff+8) = float_bswap64(intval);
byte_array_append(bplist, buff+7, 9);
}

View file

@ -1,22 +0,0 @@
https://github.com/libimobiledevice/libplist/commit/b3cf5bec39de69bf06c7813689f03cbe58f45ca9
From b3cf5bec39de69bf06c7813689f03cbe58f45ca9 Mon Sep 17 00:00:00 2001
From: Florian Weimer <fweimer@redhat.com>
Date: Mon, 18 Dec 2023 11:14:40 +0100
Subject: [PATCH] configure: Use string for tm_zone assignment
This matches what the actual sources do. Clang 16 and GCC 14
no longer support converting ints to pointers implicitly, so the
configure probe always fails with these compilers.
--- a/configure.ac
+++ b/configure.ac
@@ -129,7 +129,7 @@ AC_CACHE_CHECK(for tm_zone in struct tm, ac_cv_struct_tm_zone,
#include <time.h>
], [
struct tm tm;
- tm.tm_zone = 1;
+ tm.tm_zone = (char*)"UTC";
])],
[ac_cv_struct_tm_zone=yes],
[ac_cv_struct_tm_zone=no]

View file

@ -1,471 +0,0 @@
From 2cd858c679d25633077ca78b67182a9b77653816 Mon Sep 17 00:00:00 2001
From: Sergei Trofimovich <slyich@gmail.com>
Date: Tue, 3 Oct 2023 10:41:32 +0100
Subject: [PATCH] test: use unique output file names across tests
Without the change tests ran in parallel occasionally clobber outputs of
one another and fail as:
$ make check -j16 VERBOSE=y
...
FAIL: huge
==========
Converting
File ../test/data/5.plist is open
PList XML parsing succeeded
PList BIN writing succeeded
PList BIN parsing succeeded
PList XML writing succeeded
Size of input and output is different
Input size : 4292380
Output size : 4305301
Comparing
PList parsing failed
FAIL huge.test (exit status: 3)
Closes: https://github.com/libimobiledevice/libplist/issues/234#issuecomment-1743820556
--- a/test/amp.test
+++ b/test/amp.test
@@ -3,7 +3,7 @@
DATASRC=$top_srcdir/test/data
TESTFILE=amp.plist
DATAIN0=$DATASRC/$TESTFILE
-DATAOUT0=$top_builddir/test/data/$TESTFILE.out
+DATAOUT0=$top_builddir/test/data/amp.test.out
rm -rf $DATAOUT0
$top_builddir/tools/plistutil -i $DATAIN0 -o $DATAOUT0
--- a/test/bigarray++.test
+++ b/test/bigarray++.test
@@ -9,7 +9,7 @@ if ! test -d "$DATAOUT"; then
fi
echo "Converting"
-$top_builddir/test/plist_test++ $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_test++ $DATASRC/$TESTFILE $DATAOUT/bigarray++.test.out
echo "Comparing"
-$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/bigarray++.test.out
--- a/test/bigarray.test
+++ b/test/bigarray.test
@@ -9,7 +9,7 @@ if ! test -d "$DATAOUT"; then
fi
echo "Converting"
-$top_builddir/test/plist_test $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_test $DATASRC/$TESTFILE $DATAOUT/bigarray.test.out
echo "Comparing"
-$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/bigarray.test.out
--- a/test/cdata.test
+++ b/test/cdata.test
@@ -5,7 +5,7 @@ set -e
DATASRC=$top_srcdir/test/data
TESTFILE=cdata.plist
DATAIN0=$DATASRC/$TESTFILE
-DATAOUT0=$top_builddir/test/data/$TESTFILE.bin
+DATAOUT0=$top_builddir/test/data/cdata.test.bin
$top_builddir/tools/plistutil -i $DATAIN0 -o $DATAOUT0
--- a/test/dates.test
+++ b/test/dates.test
@@ -5,8 +5,8 @@ set -e
DATASRC=$top_srcdir/test/data
TESTFILE=7.plist
DATAIN0=$DATASRC/$TESTFILE
-DATAOUT0=$top_builddir/test/data/$TESTFILE.bin
-DATAOUT1=$top_builddir/test/data/$TESTFILE.xml
+DATAOUT0=$top_builddir/test/data/dates.test.bin
+DATAOUT1=$top_builddir/test/data/dates.test.xml
$top_builddir/tools/plistutil -i $DATAIN0 -o $DATAOUT0
$top_builddir/tools/plistutil -i $DATAOUT0 -o $DATAOUT1
--- a/test/empty++.test
+++ b/test/empty++.test
@@ -9,7 +9,7 @@ if ! test -d "$DATAOUT"; then
fi
echo "Converting"
-$top_builddir/test/plist_test++ $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_test++ $DATASRC/$TESTFILE $DATAOUT/empty++.test.out
echo "Comparing"
-$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/empty++.test.out
--- a/test/empty.test
+++ b/test/empty.test
@@ -9,7 +9,7 @@ if ! test -d "$DATAOUT"; then
fi
echo "Converting"
-$top_builddir/test/plist_test $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_test $DATASRC/$TESTFILE $DATAOUT/empty.test.out
echo "Comparing"
-$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/empty.test.out
--- a/test/empty_keys.test
+++ b/test/empty_keys.test
@@ -5,7 +5,7 @@ set -e
DATASRC=$top_srcdir/test/data
TESTFILE=empty_keys.plist
DATAIN0=$DATASRC/$TESTFILE
-DATAOUT0=$top_builddir/test/data/$TESTFILE.bin
+DATAOUT0=$top_builddir/test/data/empty_keys.test.bin
$top_builddir/tools/plistutil -i $DATAIN0 -o $DATAOUT0
--- a/test/entities.test
+++ b/test/entities.test
@@ -5,7 +5,7 @@ set -e
DATASRC=$top_srcdir/test/data
TESTFILE=entities.plist
DATAIN0=$DATASRC/$TESTFILE
-DATAOUT0=$top_builddir/test/data/$TESTFILE.bin
+DATAOUT0=$top_builddir/test/data/entities.test.bin
$top_builddir/tools/plistutil -i $DATAIN0 -o $DATAOUT0
--- a/test/hex.test
+++ b/test/hex.test
@@ -5,7 +5,7 @@ set -e
DATASRC=$top_srcdir/test/data
TESTFILE=hex.plist
DATAIN0=$DATASRC/$TESTFILE
-DATAOUT0=$top_builddir/test/data/$TESTFILE.bin
+DATAOUT0=$top_builddir/test/data/hex.test.bin
$top_builddir/tools/plistutil -i $DATAIN0 -o $DATAOUT0
--- a/test/huge++.test
+++ b/test/huge++.test
@@ -9,7 +9,7 @@ if ! test -d "$DATAOUT"; then
fi
echo "Converting"
-$top_builddir/test/plist_test++ $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_test++ $DATASRC/$TESTFILE $DATAOUT/huge++.test.out
echo "Comparing"
-$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/huge++.test.out
--- a/test/huge.test
+++ b/test/huge.test
@@ -9,7 +9,7 @@ if ! test -d "$DATAOUT"; then
fi
echo "Converting"
-$top_builddir/test/plist_test $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_test $DATASRC/$TESTFILE $DATAOUT/huge.test.out
echo "Comparing"
-$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/huge.test.out
--- a/test/invalid_tag.test
+++ b/test/invalid_tag.test
@@ -3,7 +3,7 @@
DATASRC=$top_srcdir/test/data
TESTFILE=invalid_tag.plist
DATAIN0=$DATASRC/$TESTFILE
-DATAOUT0=$top_builddir/test/data/$TESTFILE.out
+DATAOUT0=$top_builddir/test/data/invalid_tag.test.out
rm -rf $DATAOUT0
$top_builddir/tools/plistutil -i $DATAIN0 -o $DATAOUT0
--- a/test/json-int64-min-max.test
+++ b/test/json-int64-min-max.test
@@ -13,7 +13,7 @@ fi
export PLIST_JSON_DEBUG=1
echo "Converting"
-$top_builddir/test/plist_jtest $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_jtest $DATASRC/$TESTFILE $DATAOUT/json-int64-min-max.test.out
echo "Comparing"
-$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/json-int64-min-max.test.out
--- a/test/json1.test
+++ b/test/json1.test
@@ -13,7 +13,7 @@ fi
export PLIST_JSON_DEBUG=1
echo "Converting"
-$top_builddir/test/plist_jtest $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_jtest $DATASRC/$TESTFILE $DATAOUT/json1.test.out
echo "Comparing"
-$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/json1.test.out
--- a/test/json2.test
+++ b/test/json2.test
@@ -13,7 +13,7 @@ fi
export PLIST_JSON_DEBUG=1
echo "Converting"
-$top_builddir/test/plist_jtest $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_jtest $DATASRC/$TESTFILE $DATAOUT/json2.test.out
echo "Comparing"
-$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/json2.test.out
--- a/test/json3.test
+++ b/test/json3.test
@@ -13,12 +13,12 @@ fi
export PLIST_JSON_DEBUG=1
echo "Converting input file to JSON"
-$top_builddir/tools/plistutil -f json -i $DATASRC/$TESTFILE -o $DATAOUT/$TESTFILE.json
+$top_builddir/tools/plistutil -f json -i $DATASRC/$TESTFILE -o $DATAOUT/json3.test.json
echo "Converting to binary and back to JSON"
-$top_builddir/test/plist_jtest $DATAOUT/$TESTFILE.json $DATAOUT/$TESTFILE.json.out
+$top_builddir/test/plist_jtest $DATAOUT/json3.test.json $DATAOUT/json3.test.json.out
echo "Comparing"
-$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.json.out
+$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/json3.test.json.out
-rm -f $DATAOUT/$TESTFILE.json
+rm -f $DATAOUT/json3.test.json
--- a/test/large++.test
+++ b/test/large++.test
@@ -9,7 +9,7 @@ if ! test -d "$DATAOUT"; then
fi
echo "Converting"
-$top_builddir/test/plist_test++ $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_test++ $DATASRC/$TESTFILE $DATAOUT/large++.test.out
echo "Comparing"
-$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/large++.test.out
--- a/test/large.test
+++ b/test/large.test
@@ -9,7 +9,7 @@ if ! test -d "$DATAOUT"; then
fi
echo "Converting"
-$top_builddir/test/plist_test $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_test $DATASRC/$TESTFILE $DATAOUT/large.test.out
echo "Comparing"
-$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/large.test.out
--- a/test/malformed_dict.test
+++ b/test/malformed_dict.test
@@ -3,7 +3,7 @@
DATASRC=$top_srcdir/test/data
TESTFILE=malformed_dict.bplist
DATAIN0=$DATASRC/$TESTFILE
-DATAOUT0=$top_builddir/test/data/$TESTFILE.out
+DATAOUT0=$top_builddir/test/data/malformed_dict.test.out
$top_builddir/tools/plistutil -i $DATAIN0 -o $DATAOUT0
--- a/test/medium++.test
+++ b/test/medium++.test
@@ -9,7 +9,7 @@ if ! test -d "$DATAOUT"; then
fi
echo "Converting"
-$top_builddir/test/plist_test++ $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_test++ $DATASRC/$TESTFILE $DATAOUT/medium++.test.out
echo "Comparing"
-$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/medium++.test.out
--- a/test/medium.test
+++ b/test/medium.test
@@ -9,7 +9,7 @@ if ! test -d "$DATAOUT"; then
fi
echo "Converting"
-$top_builddir/test/plist_test $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_test $DATASRC/$TESTFILE $DATAOUT/medium.test.out
echo "Comparing"
-$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/medium.test.out
--- a/test/order.test
+++ b/test/order.test
@@ -6,7 +6,7 @@ DATASRC=$top_srcdir/test/data
TESTFILE=order.bplist
DATAIN0=$DATASRC/$TESTFILE
DATAIN1=$DATASRC/order.plist
-DATAOUT0=$top_builddir/test/data/$TESTFILE.out
+DATAOUT0=$top_builddir/test/data/order.test.out
$top_builddir/tools/plistutil -i $DATAIN0 -o $DATAOUT0
--- a/test/ostep-comments.test
+++ b/test/ostep-comments.test
@@ -13,8 +13,8 @@ fi
export PLIST_OSTEP_DEBUG=1
echo "Converting"
-$top_builddir/test/plist_otest $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_otest $DATASRC/$TESTFILE $DATAOUT/ostep-comments.test.out
echo "Comparing"
export PLIST_OSTEP_DEBUG=1
-$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/ostep-comments.test.out
--- a/test/ostep-strings.test
+++ b/test/ostep-strings.test
@@ -13,8 +13,8 @@ fi
export PLIST_OSTEP_DEBUG=1
echo "Converting"
-$top_builddir/test/plist_otest $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_otest $DATASRC/$TESTFILE $DATAOUT/ostep-strings.test.out
echo "Comparing"
export PLIST_OSTEP_DEBUG=1
-$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/ostep-strings.test.out
--- a/test/ostep1.test
+++ b/test/ostep1.test
@@ -13,8 +13,8 @@ fi
export PLIST_OSTEP_DEBUG=1
echo "Converting"
-$top_builddir/test/plist_otest $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_otest $DATASRC/$TESTFILE $DATAOUT/ostep1.test.out
echo "Comparing"
export PLIST_OSTEP_DEBUG=1
-$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/ostep1.test.out
--- a/test/ostep2.test
+++ b/test/ostep2.test
@@ -13,7 +13,7 @@ fi
export PLIST_OTEST_DEBUG=1
echo "Converting"
-$top_builddir/test/plist_otest $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_otest $DATASRC/$TESTFILE $DATAOUT/ostep2.test.out
echo "Comparing"
-$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/ostep2.test.out
--- a/test/recursion.test
+++ b/test/recursion.test
@@ -3,7 +3,7 @@
DATASRC=$top_srcdir/test/data
TESTFILE=recursion.bplist
DATAIN0=$DATASRC/$TESTFILE
-DATAOUT0=$top_builddir/test/data/$TESTFILE.out
+DATAOUT0=$top_builddir/test/data/recursion.test.out
$top_builddir/tools/plistutil -i $DATAIN0 -o $DATAOUT0
--- a/test/signedunsigned1.test
+++ b/test/signedunsigned1.test
@@ -13,8 +13,8 @@ CMPFILE1=unsigned.bplist
DATACMP0=$DATASRC/$CMPFILE0
DATACMP1=$DATASRC/$CMPFILE1
-DATAOUT0=$top_builddir/test/data/$TESTFILE0.bin
-DATAOUT1=$top_builddir/test/data/$TESTFILE1.bin
+DATAOUT0=$top_builddir/test/data/signedunsigned1.test.signed.bin
+DATAOUT1=$top_builddir/test/data/signedunsigned1.test.unsigned.bin
$top_builddir/tools/plistutil -i $DATAIN0 -o $DATAOUT0
$top_builddir/tools/plistutil -i $DATAIN1 -o $DATAOUT1
--- a/test/signedunsigned2.test
+++ b/test/signedunsigned2.test
@@ -13,8 +13,8 @@ CMPFILE1=unsigned.plist
DATACMP0=$DATASRC/$CMPFILE0
DATACMP1=$DATASRC/$CMPFILE1
-DATAOUT0=$top_builddir/test/data/$TESTFILE0.bin
-DATAOUT1=$top_builddir/test/data/$TESTFILE1.bin
+DATAOUT0=$top_builddir/test/data/signedunsigned2.test.signed.bin
+DATAOUT1=$top_builddir/test/data/signedunsigned2.test.unsigned.bin
$top_builddir/tools/plistutil -i $DATAIN0 -o $DATAOUT0
$top_builddir/tools/plistutil -i $DATAIN1 -o $DATAOUT1
--- a/test/signedunsigned3.test
+++ b/test/signedunsigned3.test
@@ -13,8 +13,8 @@ CMPFILE1=signedunsigned.plist
DATACMP0=$DATASRC/$CMPFILE0
DATACMP1=$DATASRC/$CMPFILE1
-DATAOUT0=$top_builddir/test/data/$TESTFILE0.bin
-DATAOUT1=$top_builddir/test/data/$TESTFILE1.xml
+DATAOUT0=$top_builddir/test/data/signedunsigned3.test.signed.bin
+DATAOUT1=$top_builddir/test/data/signedunsigned3.test.unsigned.xml
$top_builddir/tools/plistutil -i $DATAIN0 -o $DATAOUT0
$top_builddir/tools/plistutil -i $DATAIN1 -o $DATAOUT1
--- a/test/small++.test
+++ b/test/small++.test
@@ -9,7 +9,7 @@ if ! test -d "$DATAOUT"; then
fi
echo "Converting"
-$top_builddir/test/plist_test++ $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_test++ $DATASRC/$TESTFILE $DATAOUT/small++.test.out
echo "Comparing"
-$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/small++.test.out
--- a/test/small.test
+++ b/test/small.test
@@ -9,7 +9,7 @@ if ! test -d "$DATAOUT"; then
fi
echo "Converting"
-$top_builddir/test/plist_test $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_test $DATASRC/$TESTFILE $DATAOUT/small.test.out
echo "Comparing"
-$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/small.test.out
--- a/test/timezone1.test
+++ b/test/timezone1.test
@@ -5,9 +5,9 @@ set -e
DATASRC=$top_srcdir/test/data
TESTFILE=7.plist
DATAIN0=$DATASRC/$TESTFILE
-DATAOUT0=$top_builddir/test/data/$TESTFILE.tz0.bin
-DATAOUT1=$top_builddir/test/data/$TESTFILE.tz1.bin
-DATAOUT2=$top_builddir/test/data/$TESTFILE.tz2.bin
+DATAOUT0=$top_builddir/test/data/timezone1.test.tz0.bin
+DATAOUT1=$top_builddir/test/data/timezone1.test.tz1.bin
+DATAOUT2=$top_builddir/test/data/timezone1.test.tz2.bin
TZ=UTC $top_builddir/tools/plistutil -i $DATAIN0 -o $DATAOUT0
TZ=Asia/Singapore $top_builddir/tools/plistutil -i $DATAIN0 -o $DATAOUT1
--- a/test/timezone2.test
+++ b/test/timezone2.test
@@ -5,10 +5,10 @@ set -e
DATASRC=$top_srcdir/test/data
TESTFILE=7.plist
DATAIN0=$DATASRC/$TESTFILE
-DATAOUT0=$top_builddir/test/data/$TESTFILE.bin
-DATAOUT1=$top_builddir/test/data/$TESTFILE.tz0.xml
-DATAOUT2=$top_builddir/test/data/$TESTFILE.tz1.xml
-DATAOUT3=$top_builddir/test/data/$TESTFILE.tz2.xml
+DATAOUT0=$top_builddir/test/data/timezone2.test.bin
+DATAOUT1=$top_builddir/test/data/timezone2.test.tz0.xml
+DATAOUT2=$top_builddir/test/data/timezone2.test.tz1.xml
+DATAOUT3=$top_builddir/test/data/timezone2.test.tz2.xml
TZ=UTC $top_builddir/tools/plistutil -i $DATAIN0 -o $DATAOUT0
--- a/test/uid.test
+++ b/test/uid.test
@@ -9,7 +9,7 @@ if ! test -d "$DATAOUT"; then
fi
echo "Converting"
-$top_builddir/test/plist_btest $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_btest $DATASRC/$TESTFILE $DATAOUT/uid.test.out
echo "Comparing"
-$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/$TESTFILE.out
+$top_builddir/test/plist_cmp $DATASRC/$TESTFILE $DATAOUT/uid.test.out

View file

@ -1,20 +0,0 @@
--- a/src/Makefile.am.orig 2024-05-14 01:42:53.000000000 +0800
+++ b/src/Makefile.am 2024-07-13 13:31:46.423729594 +0800
@@ -12,7 +12,7 @@
libplist++-2.0.la
libplist_2_0_la_LIBADD = $(top_builddir)/libcnary/libcnary.la
-libplist_2_0_la_LDFLAGS = $(AM_LDFLAGS) -version-info $(LIBPLIST_SO_VERSION) -no-undefined
+libplist_2_0_la_LDFLAGS = $(AM_LDFLAGS) -release $(PACKAGE_VERSION) -no-undefined
libplist_2_0_la_SOURCES = \
base64.c base64.h \
bytearray.c bytearray.h \
@@ -32,7 +32,7 @@
plist.c plist.h
libplist___2_0_la_LIBADD = libplist-2.0.la
-libplist___2_0_la_LDFLAGS = $(AM_LDFLAGS) -version-info $(LIBPLIST_SO_VERSION) -no-undefined
+libplist___2_0_la_LDFLAGS = $(AM_LDFLAGS) -release $(PACKAGE_VERSION) -no-undefined
libplist___2_0_la_SOURCES = \
Node.cpp \
Structure.cpp \

View file

@ -1,54 +0,0 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit autotools
DESCRIPTION="Support library to deal with Apple Property Lists (Binary & XML)"
HOMEPAGE="https://www.libimobiledevice.org/"
SRC_URI="https://cgit.libimobiledevice.org/${PN}.git/snapshot/${P}.tar.bz2"
LICENSE="GPL-2+ LGPL-2.1+"
SLOT="0/4"
KEYWORDS="~amd64 ~arm ~arm64 ~loong ~ppc ~ppc64 ~riscv ~x86"
DEPEND="${RDEPEND}"
BDEPEND="virtual/pkgconfig"
DOCS=( AUTHORS NEWS README.md )
PATCHES=(
"${FILESDIR}"/${PN}-2.2.0-pkgconfig-lib.patch
# "${FILESDIR}"/${PN}-2.3.0-test-rename.patch
# "${FILESDIR}"/${PN}-2.3.0-configure-c99.patch
)
src_prepare() {
default
RELEASE_VERSION=${PV} eautoreconf
}
src_configure() {
local myeconfargs=(
--disable-static
--without-cython
)
econf "${myeconfargs[@]}"
}
src_install() {
emake DESTDIR="${D}" install
einstalldocs
find "${ED}" -name '*.la' -delete || die
# bugs #733082, #915375
dosym ./libplist-2.0.pc /usr/$(get_libdir)/pkgconfig/libplist.pc
dosym ./libplist++-2.0.pc /usr/$(get_libdir)/pkgconfig/libplist++.pc
#configure.ac:
# CURRENT : REVISION : AGE
# LIBPLIST_SO_VERSION=8:0:4
# 2.0.so.4 + AGE + REVISION
dosym ./libplist++-2.0.so.4.5.0 /usr/$(get_libdir)/libplist++.so
dosym ./libplist-2.0.so.4.5.0 /usr/$(get_libdir)/libplist.so
}

View file

@ -1,52 +0,0 @@
# Copyright 1999-2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit autotools
DESCRIPTION="Support library to deal with Apple Property Lists (Binary & XML)"
HOMEPAGE="https://www.libimobiledevice.org/"
SRC_URI="https://cgit.libimobiledevice.org/${PN}.git/snapshot/${P}.tar.bz2"
LICENSE="GPL-2+ LGPL-2.1+"
SLOT="0/4"
KEYWORDS="~amd64 ~arm ~arm64 ~loong ~ppc ~ppc64 ~riscv ~x86"
DEPEND="${RDEPEND}"
BDEPEND="virtual/pkgconfig"
DOCS=( AUTHORS NEWS README.md )
PATCHES=(
"${FILESDIR}"/${PN}-2.2.0-pkgconfig-lib.patch
"${FILESDIR}"/${PN}-2.6.0-makefile.patch
# "${FILESDIR}"/${PN}-2.3.0-test-rename.patch
# "${FILESDIR}"/${PN}-2.3.0-configure-c99.patch
)
src_prepare() {
default
RELEASE_VERSION=${PV} eautoreconf
}
src_configure() {
local myeconfargs=(
--disable-static
--without-cython
)
econf "${myeconfargs[@]}"
}
src_install() {
RELEASE_VERSION=${PV} emake RELEASE_VERSION=${PV} DESTDIR="${D}" install
einstalldocs
find "${ED}" -name '*.la' -delete || die
# bugs #733082, #915375
dosym ./libplist-2.0.pc /usr/$(get_libdir)/pkgconfig/libplist.pc
dosym ./libplist++-2.0.pc /usr/$(get_libdir)/pkgconfig/libplist++.pc
# this is patched in using makefile.patch
dosym ./libplist++-2.0-${PV}.so /usr/$(get_libdir)/libplist++.so
dosym ./libplist-2.0-${PV}.so /usr/$(get_libdir)/libplist.so
}

View file

@ -1,41 +0,0 @@
# Copyright 2025 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
DESCRIPTION="Support library to deal with Apple Property Lists (Binary & XML)"
HOMEPAGE="https://libimobiledevice.org/"
SRC_URI="https://github.com/libimobiledevice/${PN}/releases/download/${PV}/${P}.tar.bz2"
LICENSE="GPL-2+ LGPL-2.1+"
SLOT="0/4"
KEYWORDS="amd64 ~arm arm64 ~hppa ~loong ppc ~ppc64 ~riscv ~s390 x86"
IUSE="test"
RESTRICT="!test? ( test )"
BDEPEND="virtual/pkgconfig"
PATCHES=(
"${FILESDIR}"/${PN}-2.2.0-pkgconfig-lib.patch
)
src_configure() {
local myeconfargs=(
--disable-static
--without-cython
$(use_with test tests)
)
econf "${myeconfargs[@]}"
}
src_install() {
emake DESTDIR="${D}" install
einstalldocs
find "${ED}" -name '*.la' -delete || die
# bugs #733082, #915375
dosym ./libplist-2.0.pc /usr/$(get_libdir)/pkgconfig/libplist.pc
dosym ./libplist++-2.0.pc /usr/$(get_libdir)/pkgconfig/libplist++.pc
dosym ./libplist++-2.0.so.4.7.0 /usr/$(get_libdir)/libplist++.so
dosym ./libplist-2.0.so.4.7.0 /usr/$(get_libdir)/libplist.so
}

View file

@ -1,11 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<maintainer type="person">
<email>unknown@pentoo.ch</email>
<name>Author Unknown</name>
</maintainer>
<upstream>
<remote-id type="github">libimobiledevice/libplist</remote-id>
</upstream>
</pkgmetadata>

View file

@ -1 +0,0 @@
DIST usbmuxd-1.1.1_p20231011.tar.gz 65638 BLAKE2B 68bfdcdf907241fbf3b8b41133e11f3b08c5007417a1ea86f5428a5c11f480f9e6a6a9073080976d84ed14b456f61e19ef2b2f161d5b1ec19367fe01eb89b435 SHA512 dfe2e39496aa6841aaa7c02dc5ad5425f4199d5e5ccf560438e5f07fff9050124918ce99a1b2e22fc5b8718e091aff81ff209467de16701a14279e994c5ceefe

View file

@ -1,220 +0,0 @@
From 881f59ab1202ea9f456f074d87612b9bb76f4a46 Mon Sep 17 00:00:00 2001
From: BalkanMadman <zurabid2016@gmail.com>
Date: Thu, 10 Aug 2023 02:05:58 +0300
Subject: [PATCH] Implement OpenRC support by providing RC service script
This commit adds a service script for an OpenRC init system.
It intends to mitigate "race" caused by a start of long-living process
(that is `usbmuxd` itself) by udev rules, which is highly discouraged by
the `udev` manpage:
"Starting daemons or other long-running processes is not allowed; the
forked processes, detached or not, will be unconditionally killed after
the event handling has finished."
There is a bug in `usbmuxd`, which causes the hang, but this is to be
handled in a different commit.
This adds two new `configure` flags:
* `--with-openrc`: toggles on or off (default - off) OpenRC service
installation and udev activation via that. Conflicts with systemd, so
the latter must be disabled explicitly:
`--with-openrc --without-systemd`
* `--with-rcservicedir=DIR`: specifies directory where to install service
file. Defaults to `$sysconfdir/init.d` (which is `/etc/init.d`)
Issue: https://github.com/libimobiledevice/usbmuxd/issues/210
Signed-off-by: BalkanMadman <zurabid2016@gmail.com>
---
Makefile.am | 4 ++--
configure.ac | 37 +++++++++++++++++++++++++++++++++++--
openrc/Makefile.am | 20 ++++++++++++++++++++
openrc/usbmuxd.in | 9 +++++++++
udev/39-usbmuxd.rules.in | 4 ++--
udev/Makefile.am | 2 ++
6 files changed, 70 insertions(+), 6 deletions(-)
create mode 100644 openrc/Makefile.am
create mode 100755 openrc/usbmuxd.in
diff --git a/Makefile.am b/Makefile.am
index 6da23b66..02a50226 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,6 +1,6 @@
AUTOMAKE_OPTIONS = foreign
ACLOCAL_AMFLAGS = -I m4
-SUBDIRS = src $(UDEV_SUB) $(SYSTEMD_SUB) docs
+SUBDIRS = src $(UDEV_SUB) $(SYSTEMD_SUB) $(OPENRC_SUB) docs
EXTRA_DIST = \
docs \
@@ -10,4 +10,4 @@ EXTRA_DIST = \
DISTCHECK_CONFIGURE_FLAGS = \
--with-udevrulesdir=$$dc_install_base/$(udevrulesdir) \
- --with-systemdsystemunitdir=$$dc_install_base/$(systemdsystemunitdir)
\ No newline at end of file
+ --with-systemdsystemunitdir=$$dc_install_base/$(systemdsystemunitdir)
diff --git a/configure.ac b/configure.ac
index baf98cae..45159948 100644
--- a/configure.ac.orig 2023-10-11 08:25:19.000000000 +0800
+++ b/configure.ac 2024-01-16 17:10:32.383639155 +0800
@@ -72,29 +72,56 @@
fi
fi
+AC_ARG_WITH([openrc],
+ [AS_HELP_STRING([--with-openrc],
+ [build with support for OpenRC init system @<:@default=no@:>@])],
+ [],
+ [with_openrc=no])
+
AC_ARG_WITH([systemd],
[AS_HELP_STRING([--without-systemd],
[do not build with systemd support @<:@default=yes@:>@])],
[with_systemd=$withval],
[with_systemd=yes])
+if test "x$with_systemd" = xyes -a "x$with_openrc" = xyes; then
+ AC_MSG_ERROR([Both systemd and OpenRC support can't be enabled at the same time])
+fi
+
AC_ARG_WITH([systemdsystemunitdir],
[AS_HELP_STRING([--with-systemdsystemunitdir=DIR],
[directory for systemd service files])],
[with_systemdsystemunitdir=$withval],
[with_systemdsystemunitdir=$($PKG_CONFIG --variable=systemdsystemunitdir systemd)])
-if test "x$with_systemdsystemunitdir" != xno; then
+if test "x$with_systemdsystemunitdir" != "xno"; then
AC_SUBST([systemdsystemunitdir], [$with_systemdsystemunitdir])
fi
+
+AC_ARG_WITH([rcservicedir],
+ [AS_HELP_STRING([--with-rcservicedir=DIR],
+ [directory for OpenRC service files])],
+ [rcservicedir="$withval"],
+ [rcservicedir="$sysconfdir/init.d"])
+if test "x$with_rcservicedir" != "xno"; then
+ AC_SUBST([rcservicedir], [$rcservicedir])
+fi
+
AM_CONDITIONAL(WANT_SYSTEMD, [test -n "$with_systemdsystemunitdir" -a "x$with_systemdsystemunitdir" != xno -a "x$with_systemd" = "xyes" ])
+AM_CONDITIONAL(WANT_OPENRC, [test "x$with_openrc" = xyes -a "x$with_rcservicedir" != "xno" ])
if test "x$with_systemd" = xyes; then
udev_activation_rule="ENV{SYSTEMD_WANTS}=\"usbmuxd.service\""
+ udev_deactivation_rule="RUN+=\"@sbindir@/usbmuxd --exit\""
+elif test "x$with_openrc" = "xyes" -a "x$with_rcservicedir" != "xno"; then
+ udev_activation_rule="RUN+=\"@rcservicedir@/usbmuxd start\""
+ udev_deactivation_rule="RUN+=\"@rcservicedir@/usbmuxd stop\""
else
udev_activation_rule="RUN+=\"@sbindir@/usbmuxd --user usbmux --udev\""
+ udev_deactivation_rule="RUN+=\"@sbindir@/usbmuxd --exit\""
fi
AC_SUBST(udev_activation_rule)
+AC_SUBST(udev_deactivation_rule)
# Checks for header files.
AC_CHECK_HEADERS([stdint.h stdlib.h string.h])
@@ -117,6 +144,7 @@
# Check for operating system
AC_MSG_CHECKING([whether to enable WIN32 build settings])
UDEV_SUB=
+OPENRC_SUB=
SYSTEMD_SUB=
case ${host_os} in
*mingw32*|*cygwin*)
@@ -142,6 +170,9 @@
if test "x$with_systemd" != "xyes"; then
echo "*** Note: support for systemd activation has been disabled, using udev activation instead ***"
activation_method="udev"
+ if test "x$with_openrc" = "xyes"; then
+ OPENRC_SUB=openrc
+ fi
else
AC_DEFINE(HAVE_SYSTEMD, 1, [Define to enable systemd support])
SYSTEMD_SUB=systemd
@@ -151,6 +182,7 @@
AM_CONDITIONAL(WIN32, test x$win32 = xtrue)
AC_SUBST([UDEV_SUB])
+AC_SUBST([OPENRC_SUB])
AC_SUBST([SYSTEMD_SUB])
AS_COMPILER_FLAGS(GLOBAL_CFLAGS, "-g -Wall -Wextra -Wmissing-declarations -Wredundant-decls -Wshadow -Wpointer-arith -Wwrite-strings -Wswitch-default -Wno-unused-parameter")
@@ -168,6 +200,7 @@
src/Makefile
udev/Makefile
systemd/Makefile
+openrc/Makefile
docs/Makefile
])
AC_OUTPUT
diff --git a/openrc/Makefile.am b/openrc/Makefile.am
new file mode 100644
index 00000000..4b57e933
--- /dev/null
+++ b/openrc/Makefile.am
@@ -0,0 +1,20 @@
+if WANT_OPENRC
+edit = \
+ $(SED) -r \
+ -e 's|@sbindir[@]|$(sbindir)|g' \
+ < $< > $@ || rm $@
+
+rcservice_SCRIPTS = usbmuxd
+
+usbmuxd: usbmuxd.in
+ $(edit)
+
+EXTRA_DIST = \
+ usbmuxd.in
+
+MAINTAINERCLEANFILES = \
+ usbmuxd
+
+CLEANFILES = \
+ usbmuxd
+endif
diff --git a/openrc/usbmuxd.in b/openrc/usbmuxd.in
new file mode 100755
index 00000000..5f651301
--- /dev/null
+++ b/openrc/usbmuxd.in
@@ -0,0 +1,9 @@
+#!/sbin/openrc-run
+# Copyright 2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+name="USB multiplexing daemon"
+description="Socket daemon for the usbmux protocol used by Apple devices"
+command="@sbindir@/usbmuxd"
+command_args="--user usbmux"
+pidfile="/run/${RC_SVCNAME}.pid"
diff --git a/udev/39-usbmuxd.rules.in b/udev/39-usbmuxd.rules.in
index ac15593e..0e3aaf1b 100644
--- a/udev/39-usbmuxd.rules.in
+++ b/udev/39-usbmuxd.rules.in
@@ -10,7 +10,7 @@ SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", ENV{PRODUCT}=="5ac/8600/*", ACTION
# Make sure properties don't get lost when bind action is called
-SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", ENV{PRODUCT}=="5ac/12[9a][0-9a-f]/*|5ac/190[1-5]/*|5ac/8600/*", ACTION=="bind", ENV{USBMUX_SUPPORTED}="1", OWNER="usbmux"
+SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", ENV{PRODUCT}=="5ac/12[9a][0-9a-f]/*|5ac/190[1-5]/*|5ac/8600/*", ACTION=="bind", ENV{USBMUX_SUPPORTED}="1", OWNER="usbmux", @udev_activation_rule@
# Exit usbmuxd when the last device is removed
-SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", ENV{PRODUCT}=="5ac/12[9a][0-9a-f]/*|5ac/190[1-5]/*|5ac/8600/*", ACTION=="remove", RUN+="@sbindir@/usbmuxd -x"
+SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", ENV{PRODUCT}=="5ac/12[9a][0-9a-f]/*|5ac/190[1-5]/*|5ac/8600/*", ACTION=="remove", @udev_deactivation_rule@
diff --git a/udev/Makefile.am b/udev/Makefile.am
index 95f565d4..727986fa 100644
--- a/udev/Makefile.am
+++ b/udev/Makefile.am
@@ -1,7 +1,9 @@
edit = \
$(SED) -r \
-e 's|@udev_activation_rule[@]|$(udev_activation_rule)|g' \
+ -e 's|@udev_deactivation_rule[@]|$(udev_deactivation_rule)|g' \
-e 's|@sbindir[@]|$(sbindir)|g' \
+ -e 's|@rcservicedir[@]|$(rcservicedir)|g' \
< $< > $@ || rm $@
udevrules_DATA = \

View file

@ -1,7 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<upstream>
<remote-id type="github">libimobiledevice/usbmuxd</remote-id>
</upstream>
</pkgmetadata>

View file

@ -1,65 +0,0 @@
# Copyright 1999-2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit autotools systemd udev
HASH_COMMIT="360619c5f721f93f0b9d8af1a2df0b926fbcf281"
DESCRIPTION="USB multiplex daemon for use with Apple iPhone/iPod Touch devices"
HOMEPAGE="https://libimobiledevice.org/"
SRC_URI="https://github.com/libimobiledevice/usbmuxd/archive/${HASH_COMMIT}.tar.gz -> ${P}.tar.gz"
S=${WORKDIR}/${PN}-${HASH_COMMIT}
# src/utils.h is LGPL-2.1+, rest is found in COPYING*
LICENSE="|| ( GPL-2 GPL-3 ) LGPL-2.1+"
SLOT="0"
KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86"
IUSE="selinux systemd"
#REQUIRED_USE="!systemd ( openrc )"
DEPEND="
acct-user/usbmux
>=app-pda/libimobiledevice-1.3.0:=
app-pda/libimobiledevice-glue:=
>=app-pda/libplist-2.3:=
virtual/libusb:1=
"
RDEPEND="
${DEPEND}
virtual/udev
selinux? ( sec-policy/selinux-usbmuxd )
systemd? ( sys-apps/systemd )
"
BDEPEND="virtual/pkgconfig"
PATCHES=(
"${FILESDIR}/227_openrc.patch"
)
src_prepare() {
default
#define git-version-gen $RELEASE_VERSION
echo ${PV} > "${S}"/.tarball-version
eautoreconf
}
src_configure() {
initsystem="--with-openrc --without-systemd"
use systemd && initsystem="--with-systemd --without-openrc"
econf \
$initsystem \
$(use_with systemd systemdsystemunitdir $(systemd_get_systemunitdir)) \
--with-udevrulesdir="$(get_udevdir)"/rules.d
}
pkg_postrm() {
udev_reload
}
pkg_postinst() {
udev_reload
}