mirror of
https://github.com/fosslinux/live-bootstrap.git
synced 2026-03-22 11:06:32 +01:00
Setup to remove pregenerated header files from musl 1.1
This commit is contained in:
parent
c5175b46c5
commit
68d396ef8f
12 changed files with 144 additions and 41 deletions
53
steps/musl-1.1.24/files/disable_ctype_headers.patch
Normal file
53
steps/musl-1.1.24/files/disable_ctype_headers.patch
Normal file
|
|
@ -0,0 +1,53 @@
|
|||
SPDX-FileCopyrightText: 2024 fosslinux <fosslinux@aussies.space>
|
||||
|
||||
SPDX-License-Identifier: MIT
|
||||
|
||||
diff --color -ru include/wchar.h include/wchar.h
|
||||
--- musl-chartable-tools-44d780e03e78efcb3168ceab068170206dc92e85/include/wchar.h 2024-12-21 11:29:46.207537390 +1100
|
||||
+++ musl-chartable-tools-44d780e03e78efcb3168ceab068170206dc92e85/include/wchar.h 2024-12-21 12:03:00.494377416 +1100
|
||||
@@ -175,10 +175,7 @@
|
||||
#if defined(_XOPEN_SOURCE) || defined(_GNU_SOURCE) || defined(_BSD_SOURCE)
|
||||
int wcwidth (wchar_t);
|
||||
int wcswidth (const wchar_t *, size_t);
|
||||
-int iswalnum(wint_t);
|
||||
-int iswalpha(wint_t);
|
||||
int iswblank(wint_t);
|
||||
-int iswcntrl(wint_t);
|
||||
int iswdigit(wint_t);
|
||||
int iswgraph(wint_t);
|
||||
int iswlower(wint_t);
|
||||
@@ -187,9 +184,6 @@
|
||||
int iswspace(wint_t);
|
||||
int iswupper(wint_t);
|
||||
int iswxdigit(wint_t);
|
||||
-int iswctype(wint_t, wctype_t);
|
||||
-wint_t towlower(wint_t);
|
||||
-wint_t towupper(wint_t);
|
||||
wctype_t wctype(const char *);
|
||||
|
||||
#ifndef __cplusplus
|
||||
diff --color -ru include/wctype.h include/wctype.h
|
||||
--- musl-chartable-tools-44d780e03e78efcb3168ceab068170206dc92e85/include/wctype.h 2024-12-21 11:29:46.207537390 +1100
|
||||
+++ musl-chartable-tools-44d780e03e78efcb3168ceab068170206dc92e85/include/wctype.h 2024-12-21 12:07:48.030354351 +1100
|
||||
@@ -24,10 +24,7 @@
|
||||
|
||||
#undef iswdigit
|
||||
|
||||
-int iswalnum(wint_t);
|
||||
-int iswalpha(wint_t);
|
||||
int iswblank(wint_t);
|
||||
-int iswcntrl(wint_t);
|
||||
int iswdigit(wint_t);
|
||||
int iswgraph(wint_t);
|
||||
int iswlower(wint_t);
|
||||
@@ -36,10 +33,6 @@
|
||||
int iswspace(wint_t);
|
||||
int iswupper(wint_t);
|
||||
int iswxdigit(wint_t);
|
||||
-int iswctype(wint_t, wctype_t);
|
||||
-wint_t towctrans(wint_t, wctrans_t);
|
||||
-wint_t towlower(wint_t);
|
||||
-wint_t towupper(wint_t);
|
||||
wctrans_t wctrans(const char *);
|
||||
wctype_t wctype(const char *);
|
||||
|
||||
|
|
@ -5,6 +5,13 @@
|
|||
src_prepare() {
|
||||
default
|
||||
|
||||
# meslibc is insufficient to regenerate src/ctype or src/iconv
|
||||
# disable everything using a generated header
|
||||
patch -Np1 -i ../../files/disable_ctype_headers.patch
|
||||
rm src/ctype/iswalpha.c src/ctype/iswalnum.c src/ctype/iswctype.c \
|
||||
src/ctype/towctrans.c
|
||||
rm include/iconv.h src/locale/iconv.c src/locale/iconv_close.c
|
||||
|
||||
# tcc does not support complex types
|
||||
rm -rf src/complex
|
||||
|
||||
|
|
|
|||
|
|
@ -7,6 +7,9 @@ src_prepare() {
|
|||
|
||||
# tcc does not support complex types
|
||||
rm -rf src/complex
|
||||
|
||||
# Configure fails without this
|
||||
mkdir -p /dev
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
|
|
@ -15,7 +18,7 @@ src_configure() {
|
|||
--disable-shared \
|
||||
--prefix="${PREFIX}" \
|
||||
--libdir="${LIBDIR}" \
|
||||
--includedir="${PREFIX}/include"
|
||||
--includedir="${PREFIX}/include/"
|
||||
|
||||
# configure script creates this file
|
||||
if test -f /dev/null; then
|
||||
|
|
@ -24,9 +27,5 @@ src_configure() {
|
|||
}
|
||||
|
||||
src_compile() {
|
||||
make "${MAKEJOBS}" PREFIX="${PREFIX}" CROSS_COMPILE= CFLAGS="-DSYSCALL_NO_TLS" AS_CMD='as -o $@ $<'
|
||||
}
|
||||
|
||||
src_install() {
|
||||
make PREFIX="${PREFIX}" DESTDIR="${DESTDIR}" install
|
||||
make "${MAKEJOBS}" CROSS_COMPILE= AR="tcc -ar" RANLIB=true CFLAGS="-DSYSCALL_NO_TLS"
|
||||
}
|
||||
|
|
|
|||
32
steps/musl-1.1.24/pass4.sh
Executable file
32
steps/musl-1.1.24/pass4.sh
Executable file
|
|
@ -0,0 +1,32 @@
|
|||
# SPDX-FileCopyrightText: 2021 Andrius Štikonas <andrius@stikonas.eu>
|
||||
#
|
||||
# SPDX-License-Identifier: GPL-3.0-or-later
|
||||
|
||||
src_prepare() {
|
||||
default
|
||||
|
||||
# tcc does not support complex types
|
||||
rm -rf src/complex
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
CC=tcc ./configure \
|
||||
--host=i386 \
|
||||
--disable-shared \
|
||||
--prefix="${PREFIX}" \
|
||||
--libdir="${LIBDIR}" \
|
||||
--includedir="${PREFIX}/include"
|
||||
|
||||
# configure script creates this file
|
||||
if test -f /dev/null; then
|
||||
rm /dev/null
|
||||
fi
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
make "${MAKEJOBS}" PREFIX="${PREFIX}" CROSS_COMPILE= CFLAGS="-DSYSCALL_NO_TLS" AS_CMD='as -o $@ $<'
|
||||
}
|
||||
|
||||
src_install() {
|
||||
make PREFIX="${PREFIX}" DESTDIR="${DESTDIR}" install
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue