1
0
mirror of https://github.com/SerenityOS/serenity synced 2024-07-09 14:50:45 +00:00

Ports: Add GNU cpio archive utility port

This commit is contained in:
Liav A 2022-06-25 05:52:44 +03:00 committed by Linus Groh
parent 1cd610072a
commit f8611ec7bd
4 changed files with 51 additions and 0 deletions

View File

@ -31,6 +31,7 @@ This list is also available at [ports.serenityos.net](https://ports.serenityos.n
| [`cmatrix`](cmatrix/) | cmatrix | 3112b12 | https://github.com/abishekvashok/cmatrix |
| [`composer`](composer/) | Composer | 2.3.5 | https://getcomposer.org/ |
| [`coreutils`](coreutils/) | GNU core utilities | 9.1 | https://www.gnu.org/software/coreutils/ |
| [`cpio`](cpio/) | GNU cpio archive utility | 2.13 | https://www.gnu.org/software/cpio/ |
| [`curl`](curl/) | curl | 7.83.1 | https://curl.se/ |
| [`dash`](dash/) | DASH | 0.5.10.2 | http://gondor.apana.org.au/~herbert/dash |
| [`dialog`](dialog/) | Dialog | 1.3-20220526 | https://invisible-island.net/dialog/ |

8
Ports/cpio/package.sh Executable file
View File

@ -0,0 +1,8 @@
#!/usr/bin/env -S bash ../.port_include.sh
port='cpio'
version='2.13'
useconfigure='true'
use_fresh_config_sub='true'
config_sub_paths=('build-aux/config.sub')
files="https://ftp.gnu.org/gnu/cpio/cpio-${version}.tar.gz cpio-${version}.tar.gz e87470d9c984317f658567c03bfefb6b0c829ff17dbf6b0de48d71a4c8f3db88"
auth_type='sha256'

View File

@ -0,0 +1,34 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Liav A <liavalb@gmail.com>
Date: Sat, 25 Jun 2022 05:45:29 +0300
Subject: [PATCH] Use global program_name variable from gnu dir
Without this patch being applied, there would be a conflict between the
variables between the 2 locations, so it will not compile otherwise.
---
src/global.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/src/global.c b/src/global.c
index fb3abe9..9ea63aa 100644
--- a/src/global.c
+++ b/src/global.c
@@ -20,6 +20,7 @@
#include <system.h>
#include <sys/types.h>
+#include "gnu/progname.h"
#include "cpiohdr.h"
#include "dstring.h"
#include "extern.h"
@@ -184,9 +185,6 @@ unsigned int warn_option = 0;
/* Extract to standard output? */
bool to_stdout_option = false;
-/* The name this program was run with. */
-char *program_name;
-
/* A pointer to either lstat or stat, depending on whether
dereferencing of symlinks is done for input files. */
int (*xstat) ();

View File

@ -0,0 +1,8 @@
# Patches for cpio on SerenityOS
## `0001-Use-global-program_name-variable-from-gnu-dir.patch`
Use global program_name variable from gnu dir
Without this patch being applied, there would be a conflict between the
variables between the 2 locations, so it will not compile otherwise.