mirror of
https://github.com/yann64/haikuports.git
synced 2026-03-19 01:46:00 +01:00
xar: update to version 1.8.0.0~498. (#10995)
Gentoo patches from: https://gitweb.gentoo.org/repo/gentoo.git/tree/app-arch/xar and Fedora's from: https://src.fedoraproject.org/rpms/xar/tree/rawhide The tarball contains some more patches by Apple (under "patches/"). Haven't looked into applying them (at least hash.diff might be needed for compatibility with xar achives made with the macOS version, if I'm not mistaken). Surely there are cleaner ways to replace my "fixes". Exercise for the reader. Only tested in beta5 TC0, 64 bits.
This commit is contained in:
@@ -1,75 +0,0 @@
|
||||
From c91f2244727983ec77ddaca5618694bd88b00aa0 Mon Sep 17 00:00:00 2001
|
||||
From: Chris Roberts <cpr420@gmail.com>
|
||||
Date: Sun, 24 Nov 2013 20:46:25 -0700
|
||||
Subject: Search for xattr support on Haiku
|
||||
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 812b5ff..91a7f84 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -189,6 +189,7 @@ AC_SUBST([C99_FIXED_WIDTH_TYPE_HEADER])
|
||||
AC_TRY_COMPILE([#include <sys/types.h>
|
||||
#include <sys/acl.h>], [acl_t a], [AC_DEFINE([HAVE_SYS_ACL_H],[1], [define if you have sys/acl.h and it has a working acl_t type])])
|
||||
AC_CHECK_HEADERS(ext2fs/ext2_fs.h sys/statfs.h sys/xattr.h sys/param.h sys/extattr.h libutil.h)
|
||||
+AC_SEARCH_LIBS(getxattr, gnu)
|
||||
AC_CHECK_FUNCS(lgetxattr)
|
||||
AC_CHECK_FUNCS(lsetxattr)
|
||||
AC_CHECK_FUNCS(getxattr)
|
||||
@@ -202,6 +203,8 @@ AC_CHECK_FUNCS(statvfs)
|
||||
AC_CHECK_FUNCS(statfs)
|
||||
AC_CHECK_FUNCS(strmode)
|
||||
|
||||
+AC_SEARCH_LIBS(strsep, bsd)
|
||||
+
|
||||
AC_CHECK_MEMBERS([struct statfs.f_fstypename],,,[#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/mount.h>])
|
||||
diff --git a/lib/linuxattr.c b/lib/linuxattr.c
|
||||
index ba13ef6..3f42e23 100644
|
||||
--- a/lib/linuxattr.c
|
||||
+++ b/lib/linuxattr.c
|
||||
@@ -137,7 +137,7 @@ int32_t xar_linuxattr_write(xar_t x, xar_file_t f, void *buf, size_t len, void *
|
||||
|
||||
int32_t xar_linuxattr_archive(xar_t x, xar_file_t f, const char* file, const char *buffer, size_t len)
|
||||
{
|
||||
-#if defined(HAVE_SYS_XATTR_H) && defined(HAVE_LGETXATTR) && !defined(__APPLE__)
|
||||
+#if defined(HAVE_SYS_XATTR_H) && defined(HAVE_LGETXATTR) && !defined(__APPLE__) && !defined(__HAIKU__)
|
||||
char *i, *buf = NULL;
|
||||
int ret, retval=0, bufsz = 1024;
|
||||
struct statfs sfs;
|
||||
@@ -208,7 +208,7 @@ BAIL:
|
||||
|
||||
int32_t xar_linuxattr_extract(xar_t x, xar_file_t f, const char* file, char *buffer, size_t len)
|
||||
{
|
||||
-#if defined HAVE_SYS_XATTR_H && defined(HAVE_LSETXATTR) && !defined(__APPLE__)
|
||||
+#if defined HAVE_SYS_XATTR_H && defined(HAVE_LSETXATTR) && !defined(__APPLE__) && !defined(__HAIKU__)
|
||||
const char *fsname = "bogus";
|
||||
struct statfs sfs;
|
||||
int eaopt = 0;
|
||||
--
|
||||
2.28.0
|
||||
|
||||
|
||||
From f9ebf3abac0fce8e51699420189833951b3af5c9 Mon Sep 17 00:00:00 2001
|
||||
From: begasus <begasus@gmail.com>
|
||||
Date: Sun, 1 Nov 2020 11:32:14 +0000
|
||||
Subject: Fix build with openssl-1.1.1
|
||||
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 91a7f84..98a6507 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -332,7 +332,7 @@ dnl Configure libcrypto (part of OpenSSL).
|
||||
dnl
|
||||
have_libcrypto="1"
|
||||
AC_CHECK_HEADERS([openssl/evp.h], , [have_libcrypto="0"])
|
||||
-AC_CHECK_LIB([crypto], [OpenSSL_add_all_ciphers], , [have_libcrypto="0"])
|
||||
+AC_CHECK_LIB([crypto], [OPENSSL_init_crypto], , [have_libcrypto="0"])
|
||||
if test "x${have_libcrypto}" = "x0" ; then
|
||||
AC_MSG_ERROR([Cannot build without libcrypto (OpenSSL)])
|
||||
fi
|
||||
--
|
||||
2.28.0
|
||||
|
||||
@@ -0,0 +1,20 @@
|
||||
diff -rupN a/configure.ac b/configure.ac
|
||||
--- a/xar/configure.ac 2020-01-25 04:24:35.603846773 +0300
|
||||
+++ b/xar/configure.ac 2020-01-25 04:41:05.743109638 +0300
|
||||
@@ -320,6 +320,16 @@ if test "x${have_libxml2}" = "x0" ; then
|
||||
fi
|
||||
|
||||
dnl
|
||||
+dnl Configure libcrypto (part of OpenSSL).
|
||||
+dnl
|
||||
+have_libcrypto="1"
|
||||
+AC_CHECK_HEADERS([openssl/evp.h], , [have_libcrypto="0"])
|
||||
+AC_CHECK_LIB([crypto], [OPENSSL_init_crypto], , [have_libcrypto="0"])
|
||||
+if test "x${have_libcrypto}" = "x0" ; then
|
||||
+ AC_MSG_ERROR([Cannot build without libcrypto (OpenSSL)])
|
||||
+fi
|
||||
+
|
||||
+dnl
|
||||
dnl Configure libz.
|
||||
dnl
|
||||
have_libz="1"
|
||||
45
app-arch/xar/patches/xar-1.8-openssl-1.1.patch
Normal file
45
app-arch/xar/patches/xar-1.8-openssl-1.1.patch
Normal file
@@ -0,0 +1,45 @@
|
||||
lib/hash.c: fix compilation with OpenSSL-1.1+
|
||||
|
||||
EVP_MD_CTX has become an anonymous struct now, so can't allocate size
|
||||
for it anymore.
|
||||
|
||||
--- a/xar/lib/hash.c 2015-06-09 03:22:07.000000000 +0000
|
||||
+++ b/xar/lib/hash.c 2019-01-01 14:37:01.487775958 +0000
|
||||
@@ -102,7 +102,7 @@
|
||||
#ifdef __APPLE__
|
||||
CCDigestRef digest;
|
||||
#else
|
||||
- EVP_MD_CTX digest;
|
||||
+ EVP_MD_CTX *digest;
|
||||
const EVP_MD *type;
|
||||
#endif
|
||||
unsigned int length;
|
||||
@@ -123,7 +123,8 @@
|
||||
#else
|
||||
OpenSSL_add_all_digests();
|
||||
HASH_CTX(hash)->type = EVP_get_digestbyname(digest_name);
|
||||
- EVP_DigestInit(&HASH_CTX(hash)->digest, HASH_CTX(hash)->type);
|
||||
+ HASH_CTX(hash)->digest = EVP_MD_CTX_create();
|
||||
+ EVP_DigestInit(HASH_CTX(hash)->digest, HASH_CTX(hash)->type);
|
||||
#endif
|
||||
|
||||
HASH_CTX(hash)->digest_name = strdup(digest_name);
|
||||
@@ -143,7 +143,7 @@
|
||||
#ifdef __APPLE__
|
||||
CCDigestUpdate(HASH_CTX(hash)->digest, buffer, nbyte);
|
||||
#else
|
||||
- EVP_DigestUpdate(&HASH_CTX(hash)->digest, buffer, nbyte);
|
||||
+ EVP_DigestUpdate(HASH_CTX(hash)->digest, buffer, nbyte);
|
||||
#endif
|
||||
}
|
||||
|
||||
@@ -160,7 +160,8 @@
|
||||
CCDigestFinal(HASH_CTX(hash)->digest, buffer);
|
||||
CCDigestDestroy(HASH_CTX(hash)->digest);
|
||||
#else
|
||||
- EVP_DigestFinal(&HASH_CTX(hash)->digest, buffer, &HASH_CTX(hash)->length);
|
||||
+ EVP_DigestFinal(HASH_CTX(hash)->digest, buffer, &HASH_CTX(hash)->length);
|
||||
+ EVP_MD_CTX_destroy(HASH_CTX(hash)->digest);
|
||||
#endif
|
||||
|
||||
*nbyte = HASH_CTX(hash)->length;
|
||||
16
app-arch/xar/patches/xar-1.8-safe_dirname.patch
Normal file
16
app-arch/xar/patches/xar-1.8-safe_dirname.patch
Normal file
@@ -0,0 +1,16 @@
|
||||
linuxattr: fix missing symbol safe_dirname
|
||||
|
||||
This one was probably missed when they did a global rename to xar_
|
||||
prefixed variants.
|
||||
|
||||
--- a/xar/lib/linuxattr.c
|
||||
+++ b/xar/lib/linuxattr.c
|
||||
@@ -223,7 +223,7 @@
|
||||
if( statfs(file, &sfs) != 0 ) {
|
||||
char *tmp, *bname;
|
||||
tmp = strdup(file);
|
||||
- bname = safe_dirname(tmp);
|
||||
+ bname = xar_safe_dirname(tmp);
|
||||
statfs(bname, &sfs);
|
||||
free(tmp);
|
||||
free(bname);
|
||||
12
app-arch/xar/patches/xar-1.8.0.0.487-non-darwin.patch
Normal file
12
app-arch/xar/patches/xar-1.8.0.0.487-non-darwin.patch
Normal file
@@ -0,0 +1,12 @@
|
||||
don't do availability stuff on non-Darwin
|
||||
|
||||
--- a/xar/include/xar.h.in
|
||||
+++ b/xar/include/xar.h.in
|
||||
@@ -52,6 +52,7 @@
|
||||
#import <os/availability.h>
|
||||
#else
|
||||
#define API_DEPRECATED(...)
|
||||
+#define API_AVAILABLE(...)
|
||||
#endif
|
||||
|
||||
#pragma pack(4)
|
||||
@@ -0,0 +1,18 @@
|
||||
GCC doesn't like this:
|
||||
|
||||
filetree.c:744:9: error: variable-sized object may not be initialized
|
||||
|
||||
Since there's nothing changing at runtime at all, just make the compiler
|
||||
see it's always going to be 1.
|
||||
|
||||
--- a/xar/lib/filetree.c
|
||||
+++ b/xar/lib/filetree.c
|
||||
@@ -740,7 +740,7 @@
|
||||
size_t fspath1_size = 0, fspath2_size = 0;
|
||||
size_t ns1_size = 0, ns2_size = 0;
|
||||
const struct __xar_file_t * child1 = NULL, * child2 = NULL;
|
||||
- const uint keys_to_ignore_count = 1;
|
||||
+#define keys_to_ignore_count 1
|
||||
char * keys_to_ignore[keys_to_ignore_count] = { "id" }; // ID is allowed ot mismatch
|
||||
|
||||
// If the two pointers match, call it the same.
|
||||
24
app-arch/xar/patches/xar-1.8.0.0.498-impl-decls.patch
Normal file
24
app-arch/xar/patches/xar-1.8.0.0.498-impl-decls.patch
Normal file
@@ -0,0 +1,24 @@
|
||||
include stdlib.h for free and strtol
|
||||
silence format warning
|
||||
|
||||
--- a/xar/lib/ext2.c
|
||||
+++ b/xar/lib/ext2.c
|
||||
@@ -41,6 +41,7 @@
|
||||
#include "asprintf.h"
|
||||
#endif
|
||||
#include <stdio.h>
|
||||
+#include <stdlib.h>
|
||||
#include <unistd.h>
|
||||
#include "xar.h"
|
||||
#include "arcmod.h"
|
||||
--- a/xar/lib/ea.c
|
||||
+++ a/xar/lib/ea.c
|
||||
@@ -67,7 +67,7 @@
|
||||
xar_prop_setvalue(XAR_EA(ret)->prop, NULL);
|
||||
XAR_PROP(XAR_EA(ret)->prop)->attrs = xar_attr_new();
|
||||
XAR_ATTR(XAR_PROP(XAR_EA(ret)->prop)->attrs)->key = strdup("id");
|
||||
- asprintf((char **)&XAR_ATTR(XAR_PROP(XAR_EA(ret)->prop)->attrs)->value, "%lld", XAR_FILE(f)->nexteaid++);
|
||||
+ asprintf((char **)&XAR_ATTR(XAR_PROP(XAR_EA(ret)->prop)->attrs)->value, PRId64, XAR_FILE(f)->nexteaid++);
|
||||
|
||||
xar_prop_pset(f, XAR_EA(ret)->prop, "name", name);
|
||||
|
||||
153
app-arch/xar/patches/xar-1.8.0.0~498.patchset
Normal file
153
app-arch/xar/patches/xar-1.8.0.0~498.patchset
Normal file
@@ -0,0 +1,153 @@
|
||||
From 8687851307e2525cf7fdf5007ec8b5bda7d46e45 Mon Sep 17 00:00:00 2001
|
||||
From: Chris Roberts <cpr420@gmail.com>
|
||||
Date: Sun, 24 Nov 2013 20:46:25 -0700
|
||||
Subject: Search for xattr support on Haiku
|
||||
|
||||
|
||||
diff --git a/xar/configure.ac b/xar/configure.ac
|
||||
index c1f752b..2710f78 100644
|
||||
--- a/xar/configure.ac
|
||||
+++ b/xar/configure.ac
|
||||
@@ -184,6 +184,7 @@ AC_SUBST([enable_autogen])
|
||||
AC_TRY_COMPILE([#include <sys/types.h>
|
||||
#include <sys/acl.h>], [acl_t a], [AC_DEFINE([HAVE_SYS_ACL_H],[1], [define if you have sys/acl.h and it has a working acl_t type])])
|
||||
AC_CHECK_HEADERS(ext2fs/ext2_fs.h sys/statfs.h sys/xattr.h sys/param.h sys/extattr.h libutil.h)
|
||||
+AC_SEARCH_LIBS(getxattr, gnu)
|
||||
AC_CHECK_FUNCS(lgetxattr)
|
||||
AC_CHECK_FUNCS(lsetxattr)
|
||||
AC_CHECK_FUNCS(getxattr)
|
||||
@@ -197,6 +198,8 @@ AC_CHECK_FUNCS(statvfs)
|
||||
AC_CHECK_FUNCS(statfs)
|
||||
AC_CHECK_FUNCS(strmode)
|
||||
|
||||
+AC_SEARCH_LIBS(strsep, bsd)
|
||||
+
|
||||
AC_CHECK_MEMBERS([struct statfs.f_fstypename],,,[#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/mount.h>])
|
||||
diff --git a/xar/lib/linuxattr.c b/xar/lib/linuxattr.c
|
||||
index 58ee6a8..a00da8f 100644
|
||||
--- a/xar/lib/linuxattr.c
|
||||
+++ b/xar/lib/linuxattr.c
|
||||
@@ -135,7 +135,7 @@ int32_t xar_linuxattr_write(xar_t x, xar_file_t f, void *buf, size_t len, void *
|
||||
|
||||
int32_t xar_linuxattr_archive(xar_t x, xar_file_t f, const char* file, const char *buffer, size_t len)
|
||||
{
|
||||
-#if defined(HAVE_SYS_XATTR_H) && defined(HAVE_LGETXATTR) && !defined(__APPLE__)
|
||||
+#if defined(HAVE_SYS_XATTR_H) && defined(HAVE_LGETXATTR) && !defined(__APPLE__) && !defined(__HAIKU__)
|
||||
char *i, *buf = NULL;
|
||||
int ret, retval=0, bufsz = 1024;
|
||||
struct statfs sfs;
|
||||
@@ -206,7 +206,7 @@ BAIL:
|
||||
|
||||
int32_t xar_linuxattr_extract(xar_t x, xar_file_t f, const char* file, char *buffer, size_t len)
|
||||
{
|
||||
-#if defined HAVE_SYS_XATTR_H && defined(HAVE_LSETXATTR) && !defined(__APPLE__)
|
||||
+#if defined HAVE_SYS_XATTR_H && defined(HAVE_LSETXATTR) && !defined(__APPLE__) && !defined(__HAIKU__)
|
||||
const char *fsname = "bogus";
|
||||
struct statfs sfs;
|
||||
int eaopt = 0;
|
||||
--
|
||||
2.45.2
|
||||
|
||||
|
||||
From e350d71c1b3457a40b14bc229d336295fff9cfc0 Mon Sep 17 00:00:00 2001
|
||||
From: Oscar Lesta <oscar.lesta@gmail.com>
|
||||
Date: Fri, 30 Aug 2024 23:59:13 -0300
|
||||
Subject: Some hackish build "fixes".
|
||||
|
||||
|
||||
diff --git a/xar/configure.ac b/xar/configure.ac
|
||||
index 2710f78..60d6a56 100644
|
||||
--- a/xar/configure.ac
|
||||
+++ b/xar/configure.ac
|
||||
@@ -159,6 +159,12 @@ case "${host}" in
|
||||
dnl CPPFLAGS="$CPPFLAGS -D_POSIX_PTHREAD_SEMANTICS"
|
||||
dnl LIBS="$LIBS -lposix4 -lsocket -lnsl"
|
||||
;;
|
||||
+ *-*-haiku*)
|
||||
+ CFLAGS="$CFLAGS -Wno-unknown-pragmas"
|
||||
+ LIBS="$LIBS -lbsd"
|
||||
+ abi="elf"
|
||||
+ RPATH=
|
||||
+ ;;
|
||||
*)
|
||||
AC_MSG_RESULT([Unsupported operating system: ${host}])
|
||||
abi="elf"
|
||||
diff --git a/xar/lib/util.c b/xar/lib/util.c
|
||||
index 0ea661a..d98e79b 100644
|
||||
--- a/xar/lib/util.c
|
||||
+++ b/xar/lib/util.c
|
||||
@@ -38,19 +38,21 @@
|
||||
#include <stdio.h>
|
||||
#include <stdint.h>
|
||||
#include <sys/types.h>
|
||||
+#ifndef __HAIKU__
|
||||
#include <sys/mount.h>
|
||||
+#endif
|
||||
#include <sys/param.h>
|
||||
#include <arpa/inet.h>
|
||||
#include <string.h>
|
||||
#include <unistd.h>
|
||||
#include <errno.h>
|
||||
#include <time.h>
|
||||
-#include "config.h"
|
||||
+#include "../include/config.h"
|
||||
#include <ctype.h>
|
||||
#ifndef HAVE_ASPRINTF
|
||||
#include "asprintf.h"
|
||||
#endif
|
||||
-#include "xar.h"
|
||||
+#include "../include/xar.h"
|
||||
#include "archive.h"
|
||||
#include "filetree.h"
|
||||
|
||||
@@ -587,7 +589,8 @@ size_t xar_optimal_io_size_at_path(const char *path)
|
||||
{
|
||||
// Start at 1MiB
|
||||
size_t optimal_rsize = 1024 * 1024;
|
||||
-
|
||||
+
|
||||
+#ifndef __HAIKU__
|
||||
// Stat the destination of the archive to determine the optimal fs operation size
|
||||
struct statfs target_mount_stat_fs;
|
||||
if ( statfs(path, &target_mount_stat_fs) == 0 )
|
||||
@@ -615,6 +618,6 @@ size_t xar_optimal_io_size_at_path(const char *path)
|
||||
optimal_rsize = fs_iosize;
|
||||
}
|
||||
}
|
||||
-
|
||||
+#endif
|
||||
return optimal_rsize;
|
||||
}
|
||||
diff --git a/xar/src/xar.c b/xar/src/xar.c
|
||||
index 9977e8a..a33a643 100644
|
||||
--- a/xar/src/xar.c
|
||||
+++ b/xar/src/xar.c
|
||||
@@ -51,8 +51,8 @@
|
||||
#include <time.h>
|
||||
#include "xar_internal.h"
|
||||
#include "config.h"
|
||||
-#include "filetree.h"
|
||||
-#include "util.h"
|
||||
+#include "../lib/filetree.h"
|
||||
+#include "../lib/util.h"
|
||||
#define SYMBOLIC 1
|
||||
#define NUMERIC 2
|
||||
static int Perms = 0;
|
||||
diff --git a/xar/src/xar_internal.h b/xar/src/xar_internal.h
|
||||
index b78745c..b26d3da 100644
|
||||
--- a/xar/src/xar_internal.h
|
||||
+++ b/xar/src/xar_internal.h
|
||||
@@ -11,7 +11,7 @@
|
||||
#ifdef XARSIG_BUILDING_WITH_XAR
|
||||
#include "xar.h"
|
||||
#else
|
||||
-#include <xar/xar.h>
|
||||
+#include "xar.h"
|
||||
#endif // XARSIG_BUILDING_WITH_XAR
|
||||
|
||||
// Undeprecate these for internal usage
|
||||
--
|
||||
2.45.2
|
||||
|
||||
@@ -8,13 +8,27 @@ to choose independent encodings for individual files in the archive, the \
|
||||
ability to store checksums for individual files in both compressed and \
|
||||
uncompressed form, and the ability to query the table of content's rich \
|
||||
meta-data."
|
||||
HOMEPAGE="https://mackyle.github.io/xar/"
|
||||
HOMEPAGE="https://github.com/apple-oss-distributions/xar"
|
||||
COPYRIGHT="2005 Rob Braun"
|
||||
LICENSE="BSD (3-clause)"
|
||||
REVISION="2"
|
||||
SOURCE_URI="https://github.com/downloads/mackyle/xar/xar-$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="ee46089968457cf710b8cf1bdeb98b7ef232eb8a4cdeb34502e1f16ef4d2153e"
|
||||
PATCHES="xar-$portVersion.patchset"
|
||||
REVISION="1"
|
||||
shortVersion=${portVersion#*~} # get substring after ~
|
||||
SOURCE_URI="https://github.com/apple-oss-distributions/xar/archive/refs/tags/xar-$shortVersion.tar.gz"
|
||||
CHECKSUM_SHA256="9cee4f80b96cf592ccc545a4fdd51e4da4a5bd3b4734901637d67b043eff3c75"
|
||||
SOURCE_DIR="xar-xar-$shortVersion"
|
||||
|
||||
PATCHES="
|
||||
# Gentoo patches (with adjusted paths):
|
||||
xar-1.8-openssl-1.1.patch
|
||||
xar-1.8-safe_dirname.patch
|
||||
xar-1.8.0.0.487-non-darwin.patch
|
||||
xar-1.8.0.0.487-variable-sized-object.patch
|
||||
xar-1.8.0.0.498-impl-decls.patch
|
||||
# Fedora's (with adjusted paths):
|
||||
xar-1.8-Add-OpenSSL-To-Configuration.patch
|
||||
# Our's:
|
||||
xar-$portVersion.patchset
|
||||
"
|
||||
|
||||
ARCHITECTURES="all !x86_gcc2"
|
||||
SECONDARY_ARCHITECTURES="x86"
|
||||
@@ -26,23 +40,28 @@ if [ "$targetArchitecture" = x86_gcc2 ]; then
|
||||
commandBinDir=$prefix/bin
|
||||
fi
|
||||
|
||||
libVersion="$portVersion"
|
||||
libVersionCompat="$libVersion compat >= ${libVersion%%.*}"
|
||||
portVersionCompat="$portVersion compat >= ${portVersion%%.*}"
|
||||
|
||||
PROVIDES="
|
||||
xar$secondaryArchSuffix = $portVersion compat = 1.5.2
|
||||
cmd:xar$commandSuffix = $portVersion compat = 1.5.2
|
||||
lib:libxar$secondaryArchSuffix = $portVersion compat = 1.5.2
|
||||
xar$secondaryArchSuffix = $portVersionCompat
|
||||
cmd:xar$commandSuffix = $portVersionCompat
|
||||
lib:libxar$secondaryArchSuffix = $libVersionCompat
|
||||
"
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
lib:libbz2$secondaryArchSuffix
|
||||
lib:libcrypto$secondaryArchSuffix
|
||||
lib:libiconv$secondaryArchSuffix
|
||||
lib:liblzma$secondaryArchSuffix
|
||||
lib:libxml2$secondaryArchSuffix
|
||||
lib:libz$secondaryArchSuffix
|
||||
"
|
||||
|
||||
PROVIDES_devel="
|
||||
xar${secondaryArchSuffix}_devel = $portVersion compat = 1.5.2
|
||||
devel:libxar$secondaryArchSuffix = $portVersion compat = 1.5.2
|
||||
xar${secondaryArchSuffix}_devel = $portVersionCompat
|
||||
devel:libxar$secondaryArchSuffix = $libVersionCompat
|
||||
"
|
||||
REQUIRES_devel="
|
||||
xar$secondaryArchSuffix == $portVersion
|
||||
@@ -51,40 +70,42 @@ REQUIRES_devel="
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
devel:libbz2$secondaryArchSuffix
|
||||
devel:libcrypto$secondaryArchSuffix
|
||||
devel:libcrypto$secondaryArchSuffix >= 3
|
||||
devel:liblzma$secondaryArchSuffix
|
||||
devel:libxml2$secondaryArchSuffix
|
||||
devel:libz$secondaryArchSuffix
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:aclocal
|
||||
cmd:awk # needed by "./configure"
|
||||
cmd:autoconf
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:ld$secondaryArchSuffix
|
||||
cmd:libtoolize$secondaryArchSuffix
|
||||
cmd:make
|
||||
"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
libtoolize --force --copy --install
|
||||
aclocal
|
||||
cd xar
|
||||
|
||||
autoconf
|
||||
|
||||
runConfigure --omit-dirs binDir ./configure \
|
||||
--bindir=$commandBinDir \
|
||||
--disable-static
|
||||
make
|
||||
|
||||
make CFLAGS="-I$sourceDir/xar/include -I/system/develop/headers/libxml2"
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
cd xar
|
||||
|
||||
make install
|
||||
|
||||
# remove libtool file
|
||||
rm $libDir/libxar.la
|
||||
|
||||
prepareInstalledDevelLib libxar
|
||||
|
||||
packageEntries devel \
|
||||
$developDir
|
||||
$developDir
|
||||
}
|
||||
Reference in New Issue
Block a user