Commit 6fc3466f authored by Daniel Néri's avatar Daniel Néri
Browse files

testing/py3-libarchive-c: upgrade to 3.1

parent 45c7d281
Pipeline #87487 failed with stages
in 5 minutes and 23 seconds
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=py3-libarchive-c
pkgver=2.9
pkgrel=3
pkgver=3.1
pkgrel=0
pkgdesc="Python interface to libarchive"
url="https://github.com/Changaco/python-libarchive-c"
arch="noarch !mips !mips64" # essential tests fail on mips
......@@ -9,8 +9,7 @@ license="CC0-1.0"
depends="libarchive python3" # uses ffi
makedepends="python3-dev libarchive-dev py3-setuptools"
checkdepends="py3-pytest py3-mock"
source="python-libarchive-c-$pkgver.tar.gz::https://github.com/Changaco/python-libarchive-c/archive/$pkgver.tar.gz
time64.patch"
source="python-libarchive-c-$pkgver.tar.gz::https://github.com/Changaco/python-libarchive-c/archive/$pkgver.tar.gz"
builddir="$srcdir/python-libarchive-c-$pkgver"
prepare() {
......@@ -31,5 +30,4 @@ package() {
python3 setup.py install --prefix=/usr --root="$pkgdir"
}
sha512sums="282791cef6ff67aefc238ce1b40783e3952b366fc5c464fe99557e81d91e8057b9ec339c52535917c251f9a9bffdd3ec2773c91cbb6c9881d9ecb8572cf0fc5b python-libarchive-c-2.9.tar.gz
24cbdbfeeb8f375bfdf4061dbdbd6bd40fbe5cd6b2c9f15c6b15814062121ede938c90b2b73cb5540ee7fedf56062a748d5b9b21b3d35327ce583be1d6e164ba time64.patch"
sha512sums="1dc931681b0df5bd76ba5314155a8bbee0d2bf1582f4e439f922a6173c90346c1d84dceb0186f583016b00e5a078c8f45265c6a4dc4c790f9afb88204911f88e python-libarchive-c-3.1.tar.gz"
diff --git a/libarchive/ffi.py b/libarchive/ffi.py
index 26b383f..b089575 100644
--- a/libarchive/ffi.py
+++ b/libarchive/ffi.py
@@ -2,7 +2,7 @@ from __future__ import division, print_function, unicode_literals
from ctypes import (
c_char_p, c_int, c_uint, c_long, c_longlong, c_size_t, c_void_p,
- c_wchar_p, CFUNCTYPE, POINTER,
+ c_wchar_p, CFUNCTYPE, POINTER, c_int64
)
try:
@@ -56,6 +56,7 @@ VOID_CB = lambda *_: ARCHIVE_OK
c_archive_p = c_void_p
c_archive_entry_p = c_void_p
+c_time_t = c_int64
# Helper functions
@@ -113,10 +114,10 @@ error_string = ffi('error_string', [c_archive_p], c_char_p)
ffi('entry_new', [], c_archive_entry_p, check_null)
ffi('entry_filetype', [c_archive_entry_p], c_int)
-ffi('entry_atime', [c_archive_entry_p], c_int)
-ffi('entry_birthtime', [c_archive_entry_p], c_int)
-ffi('entry_mtime', [c_archive_entry_p], c_int)
-ffi('entry_ctime', [c_archive_entry_p], c_int)
+ffi('entry_atime', [c_archive_entry_p], c_time_t)
+ffi('entry_birthtime', [c_archive_entry_p], c_time_t)
+ffi('entry_mtime', [c_archive_entry_p], c_time_t)
+ffi('entry_ctime', [c_archive_entry_p], c_time_t)
ffi('entry_atime_nsec', [c_archive_entry_p], c_long)
ffi('entry_birthtime_nsec', [c_archive_entry_p], c_long)
ffi('entry_mtime_nsec', [c_archive_entry_p], c_long)
@@ -140,10 +141,10 @@ ffi('entry_gid', [c_archive_entry_p], c_longlong)
ffi('entry_set_size', [c_archive_entry_p, c_longlong], None)
ffi('entry_set_filetype', [c_archive_entry_p, c_uint], None)
ffi('entry_set_perm', [c_archive_entry_p, c_int], None)
-ffi('entry_set_atime', [c_archive_entry_p, c_int, c_long], None)
-ffi('entry_set_mtime', [c_archive_entry_p, c_int, c_long], None)
-ffi('entry_set_ctime', [c_archive_entry_p, c_int, c_long], None)
-ffi('entry_set_birthtime', [c_archive_entry_p, c_int, c_long], None)
+ffi('entry_set_atime', [c_archive_entry_p, c_time_t, c_long], None)
+ffi('entry_set_mtime', [c_archive_entry_p, c_time_t, c_long], None)
+ffi('entry_set_ctime', [c_archive_entry_p, c_time_t, c_long], None)
+ffi('entry_set_birthtime', [c_archive_entry_p, c_time_t, c_long], None)
ffi('entry_update_pathname_utf8', [c_archive_entry_p, c_char_p], None)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment