Initial Commit
- initial default booting image
This commit is contained in:
@@ -0,0 +1,41 @@
|
||||
From e27fe4b483194ee57736c228b7a6c56696ae8a06 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Martin=20Hundeb=C3=B8ll?= <martin@geanix.com>
|
||||
Date: Thu, 16 Mar 2023 09:29:20 +0100
|
||||
Subject: [PATCH] archcommon: define GNU-only FNM_EXTMATCH to zero on non-glibc
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
FNM_EXTMATCH is a GNU extension that enables extended pattern matching
|
||||
for fnmatch(3). Defining it to zero on non-glibc builds makes ifupdown
|
||||
usable, albeit with a sligthy reduced pattern matching feature set.
|
||||
|
||||
Signed-off-by: Martin Hundebøll <martin@geanix.com>
|
||||
Upstream-status: Denied [https://salsa.debian.org/debian/ifupdown/-/merge_requests/5]
|
||||
---
|
||||
archcommon.h | 10 ++++++++++
|
||||
1 file changed, 10 insertions(+)
|
||||
|
||||
diff --git a/archcommon.h b/archcommon.h
|
||||
index 818b0b6..981e84f 100644
|
||||
--- a/archcommon.h
|
||||
+++ b/archcommon.h
|
||||
@@ -1,5 +1,15 @@
|
||||
#include "header.h"
|
||||
|
||||
+/*
|
||||
+ * FNM_EXTMATCH is a GNU extension, so it isn't available when compiling
|
||||
+ * with MUSL. Defining FNM_EXTMATCH to zero is safe, as the flag merely
|
||||
+ * enables extended pattern matching, which MUSL users should be able to
|
||||
+ * live without.
|
||||
+ */
|
||||
+#ifndef FNM_EXTMATCH
|
||||
+#define FNM_EXTMATCH 0
|
||||
+#endif
|
||||
+
|
||||
bool execable(const char *);
|
||||
|
||||
#define iface_is_link() (!_iface_has(ifd->real_iface, ":."))
|
||||
--
|
||||
2.39.2
|
||||
|
||||
17
package/ifupdown/0001-dont-use-dpkg-architecture.patch
Normal file
17
package/ifupdown/0001-dont-use-dpkg-architecture.patch
Normal file
@@ -0,0 +1,17 @@
|
||||
Drop the need for dpkg-architecture, we only build for linux.
|
||||
Thanks to Károly Kasza for catching this one.
|
||||
|
||||
Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
|
||||
|
||||
diff -Nura ifupdown.orig/defn2c.pl ifupdown/defn2c.pl
|
||||
--- ifupdown.orig/defn2c.pl 2014-11-18 16:39:28.878772655 -0300
|
||||
+++ ifupdown/defn2c.pl 2014-11-18 16:43:41.120456676 -0300
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
use strict;
|
||||
|
||||
-my $DEB_HOST_ARCH_OS = `dpkg-architecture -qDEB_HOST_ARCH_OS`;
|
||||
+my $DEB_HOST_ARCH_OS = "linux";
|
||||
|
||||
$DEB_HOST_ARCH_OS =~ s/\n//;
|
||||
|
||||
18
package/ifupdown/Config.in
Normal file
18
package/ifupdown/Config.in
Normal file
@@ -0,0 +1,18 @@
|
||||
config BR2_PACKAGE_IFUPDOWN
|
||||
bool "ifupdown"
|
||||
depends on BR2_USE_MMU # fork()
|
||||
depends on BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_4 # iproute2
|
||||
depends on BR2_PACKAGE_BUSYBOX_SHOW_OTHERS
|
||||
# runtime for ip binary
|
||||
select BR2_PACKAGE_IPROUTE2 if !BR2_PACKAGE_BUSYBOX
|
||||
# runtime for run-parts
|
||||
select BR2_PACKAGE_DEBIANUTILS if !BR2_PACKAGE_BUSYBOX
|
||||
help
|
||||
High level tools to configure network interfaces.
|
||||
|
||||
https://tracker.debian.org/pkg/ifupdown
|
||||
|
||||
comment "ifupdown needs a toolchain w/ headers >= 3.4"
|
||||
depends on BR2_USE_MMU
|
||||
depends on !BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_4
|
||||
depends on BR2_PACKAGE_BUSYBOX_SHOW_OTHERS
|
||||
4
package/ifupdown/ifupdown.hash
Normal file
4
package/ifupdown/ifupdown.hash
Normal file
@@ -0,0 +1,4 @@
|
||||
# From http://snapshot.debian.org/archive/debian/20240917T144520Z/pool/main/i/ifupdown/ifupdown_0.8.44.dsc
|
||||
sha256 6121a19702e2e86b8f3aaac90d486ae8d557477f769718f3eb838945b697bcad ifupdown_0.8.44.tar.xz
|
||||
# Locally computed
|
||||
sha256 32b1062f7da84967e7019d01ab805935caa7ab7321a7ced0e30ebe75e5df1670 COPYING
|
||||
36
package/ifupdown/ifupdown.mk
Normal file
36
package/ifupdown/ifupdown.mk
Normal file
@@ -0,0 +1,36 @@
|
||||
################################################################################
|
||||
#
|
||||
# ifupdown
|
||||
#
|
||||
################################################################################
|
||||
|
||||
IFUPDOWN_VERSION = 0.8.44
|
||||
IFUPDOWN_SOURCE = ifupdown_$(IFUPDOWN_VERSION).tar.xz
|
||||
IFUPDOWN_SITE = http://snapshot.debian.org/archive/debian/20240917T144520Z/pool/main/i/ifupdown
|
||||
IFUPDOWN_LICENSE = GPL-2.0+
|
||||
IFUPDOWN_LICENSE_FILES = COPYING
|
||||
IFUPDOWN_CPE_ID_VENDOR = debian
|
||||
|
||||
define IFUPDOWN_BUILD_CMDS
|
||||
$(TARGET_MAKE_ENV) $(MAKE) $(TARGET_CONFIGURE_OPTS) \
|
||||
CFLAGS="$(TARGET_CFLAGS) -std=gnu99 -D'PKGLIBDIR=\"/lib/ifupdown\"' -D'IFUPDOWN_VERSION=\"$(IFUPDOWN_VERSION)\"'" \
|
||||
ARCH=linux \
|
||||
-C $(@D)
|
||||
endef
|
||||
|
||||
# install doesn't overwrite
|
||||
define IFUPDOWN_INSTALL_TARGET_CMDS
|
||||
$(RM) $(TARGET_DIR)/sbin/{ifdown,ifquery}
|
||||
$(TARGET_MAKE_ENV) $(MAKE) BASEDIR=$(TARGET_DIR) -C $(@D) install
|
||||
endef
|
||||
|
||||
# We need to switch from /bin/ip to /sbin/ip
|
||||
IFUPDOWN_DEFN_FILES = can inet inet6 ipx link meta
|
||||
define IFUPDOWN_MAKE_IP_IN_SBIN
|
||||
for f in $(IFUPDOWN_DEFN_FILES) ; do \
|
||||
$(SED) 's,/bin/ip,/sbin/ip,' $(@D)/$$f.defn ; \
|
||||
done
|
||||
endef
|
||||
IFUPDOWN_POST_PATCH_HOOKS += IFUPDOWN_MAKE_IP_IN_SBIN
|
||||
|
||||
$(eval $(generic-package))
|
||||
Reference in New Issue
Block a user