fix: zsh compile issues
This commit is contained in:
parent
615944e6cd
commit
defc9cb116
@ -1,22 +1,29 @@
|
|||||||
NAME="zsh"
|
NAME="zsh"
|
||||||
DESC="Z shell"
|
DESC="Z shell"
|
||||||
VERSION="5.9"
|
VERSION="5.9"
|
||||||
|
|
||||||
FILES=(
|
FILES=(
|
||||||
"https://www.zsh.org/pub/zsh-$VERSION.tar.xz"
|
"https://www.zsh.org/pub/zsh-${VERSION}.tar.xz"
|
||||||
"https://www.zsh.org/pub/zsh-$VERSION-doc.tar.xz"
|
"https://www.zsh.org/pub/zsh-${VERSION}-doc.tar.xz"
|
||||||
|
"zsh-${VERSION}-avoid-incompatible-pointer-types.patch"
|
||||||
)
|
)
|
||||||
HASHES=(
|
HASHES=(
|
||||||
"182e37ca3fe3fa6a44f69ad462c5c30e"
|
"182e37ca3fe3fa6a44f69ad462c5c30e"
|
||||||
"8db53446f613521fb4f9b0bd9f6adda1"
|
"8db53446f613521fb4f9b0bd9f6adda1"
|
||||||
|
"984c804bfa4c7c9b1ddba9f18bbd29846bf6f2b3171f39bb775c11c8b1c7b5ad2c68d2922a59265c58f6e83016d6d440d64862c529d82f90cad308fd2af757ce"
|
||||||
)
|
)
|
||||||
DEPENDS=()
|
|
||||||
|
DEPENDS=("gdbm" "libcap" "pcre2" "grep") # grep needed for INSTALL
|
||||||
|
BUILD=()
|
||||||
|
|
||||||
PACKAGE() {
|
PACKAGE() {
|
||||||
tar xf $NAME-$VERSION.tar.xz
|
tar xf "${NAME}-${VERSION}.tar.xz"
|
||||||
cd $NAME-$VERSION
|
cd "${NAME}-${VERSION}"
|
||||||
|
|
||||||
tar --strip-components=1 -xvf ../zsh-$VERSION-doc.tar.xz
|
patch -Np1 < "../zsh-${VERSION}-avoid-incompatible-pointer-types.patch"
|
||||||
./configure --prefix=/usr \
|
|
||||||
|
tar --strip-components=1 -xvf "../zsh-${VERSION}-doc.tar.xz"
|
||||||
|
./configure --prefix=/usr \
|
||||||
--sysconfdir=/etc/zsh \
|
--sysconfdir=/etc/zsh \
|
||||||
--enable-etcdir=/etc/zsh \
|
--enable-etcdir=/etc/zsh \
|
||||||
--enable-cap \
|
--enable-cap \
|
||||||
@ -27,16 +34,19 @@ PACKAGE() {
|
|||||||
makeinfo Doc/zsh.texi --html -o Doc/html
|
makeinfo Doc/zsh.texi --html -o Doc/html
|
||||||
makeinfo Doc/zsh.texi --html --no-split --no-headers -o Doc/zsh.html
|
makeinfo Doc/zsh.texi --html --no-split --no-headers -o Doc/zsh.html
|
||||||
|
|
||||||
make DESTDIR=${ROOTDIR} install
|
make DESTDIR="${ROOTDIR}" install
|
||||||
make DESTDIR=${ROOTDIR} infodir=/usr/share/info install.info
|
make DESTDIR="${ROOTDIR}" infodir=/usr/share/info install.info
|
||||||
|
|
||||||
install -v -m755 -d ${ROOTDIR}/usr/share/doc/zsh-$VERSION/html
|
install -v -m755 -d "${ROOTDIR}/usr/share/doc/zsh-${VERSION}/html"
|
||||||
install -v -m644 Doc/html/* ${ROOTDIR}/usr/share/doc/zsh-$VERSION/html
|
install -v -m644 Doc/html/* "${ROOTDIR}/usr/share/doc/zsh-${VERSION}/html"
|
||||||
install -v -m644 Doc/zsh.{html,txt} ${ROOTDIR}/usr/share/doc/zsh-$VERSION
|
install -v -m644 Doc/zsh.{html,txt} "${ROOTDIR}/usr/share/doc/zsh-${VERSION}"
|
||||||
|
|
||||||
cd .. && rm -rf $NAME-$VERSION
|
cd .. && rm -rf "${NAME}-${VERSION}"
|
||||||
}
|
}
|
||||||
|
|
||||||
INSTALL(){
|
INSTALL(){
|
||||||
echo /bin/zsh >> /etc/shells
|
# add zsh to /etc/shells if not already exists
|
||||||
|
if ! grep -q "/bin/zsh" "/etc/shells"; then
|
||||||
|
echo /bin/zsh >> /etc/shells
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
|
48
src/zsh/zsh-5.9-avoid-incompatible-pointer-types.patch
Normal file
48
src/zsh/zsh-5.9-avoid-incompatible-pointer-types.patch
Normal file
@ -0,0 +1,48 @@
|
|||||||
|
From 4c89849c98172c951a9def3690e8647dae76308f Mon Sep 17 00:00:00 2001
|
||||||
|
From: Florian Weimer <fweimer@redhat.com>
|
||||||
|
Date: Fri, 8 Dec 2023 21:58:07 +0100
|
||||||
|
Subject: [PATCH] 52383: Avoid incompatible pointer types in terminfo global
|
||||||
|
variable checks
|
||||||
|
|
||||||
|
---
|
||||||
|
configure.ac | 12 ++++++------
|
||||||
|
1 file changed, 6 insertions(+), 6 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/configure.ac b/configure.ac
|
||||||
|
index 2a8221e1f..2871dcb7c 100644
|
||||||
|
--- a/configure.ac
|
||||||
|
+++ b/configure.ac
|
||||||
|
@@ -1768,27 +1768,27 @@ if test x$zsh_cv_path_term_header != xnone; then
|
||||||
|
fi
|
||||||
|
|
||||||
|
AC_MSG_CHECKING(if boolcodes is available)
|
||||||
|
- AC_LINK_IFELSE([AC_LANG_PROGRAM([[$term_includes]], [[char **test = boolcodes; puts(*test);]])],[AC_DEFINE(HAVE_BOOLCODES) boolcodes=yes],[boolcodes=no])
|
||||||
|
+ AC_LINK_IFELSE([AC_LANG_PROGRAM([[$term_includes]], [[char **test = (char **)boolcodes; puts(*test);]])],[AC_DEFINE(HAVE_BOOLCODES) boolcodes=yes],[boolcodes=no])
|
||||||
|
AC_MSG_RESULT($boolcodes)
|
||||||
|
|
||||||
|
AC_MSG_CHECKING(if numcodes is available)
|
||||||
|
- AC_LINK_IFELSE([AC_LANG_PROGRAM([[$term_includes]], [[char **test = numcodes; puts(*test);]])],[AC_DEFINE(HAVE_NUMCODES) numcodes=yes],[numcodes=no])
|
||||||
|
+ AC_LINK_IFELSE([AC_LANG_PROGRAM([[$term_includes]], [[char **test = (char **)numcodes; puts(*test);]])],[AC_DEFINE(HAVE_NUMCODES) numcodes=yes],[numcodes=no])
|
||||||
|
AC_MSG_RESULT($numcodes)
|
||||||
|
|
||||||
|
AC_MSG_CHECKING(if strcodes is available)
|
||||||
|
- AC_LINK_IFELSE([AC_LANG_PROGRAM([[$term_includes]], [[char **test = strcodes; puts(*test);]])],[AC_DEFINE(HAVE_STRCODES) strcodes=yes],[strcodes=no])
|
||||||
|
+ AC_LINK_IFELSE([AC_LANG_PROGRAM([[$term_includes]], [[char **test = (char **)strcodes; puts(*test);]])],[AC_DEFINE(HAVE_STRCODES) strcodes=yes],[strcodes=no])
|
||||||
|
AC_MSG_RESULT($strcodes)
|
||||||
|
|
||||||
|
AC_MSG_CHECKING(if boolnames is available)
|
||||||
|
- AC_LINK_IFELSE([AC_LANG_PROGRAM([[$term_includes]], [[char **test = boolnames; puts(*test);]])],[AC_DEFINE(HAVE_BOOLNAMES) boolnames=yes],[boolnames=no])
|
||||||
|
+ AC_LINK_IFELSE([AC_LANG_PROGRAM([[$term_includes]], [[char **test = (char **)boolnames; puts(*test);]])],[AC_DEFINE(HAVE_BOOLNAMES) boolnames=yes],[boolnames=no])
|
||||||
|
AC_MSG_RESULT($boolnames)
|
||||||
|
|
||||||
|
AC_MSG_CHECKING(if numnames is available)
|
||||||
|
- AC_LINK_IFELSE([AC_LANG_PROGRAM([[$term_includes]], [[char **test = numnames; puts(*test);]])],[AC_DEFINE(HAVE_NUMNAMES) numnames=yes],[numnames=no])
|
||||||
|
+ AC_LINK_IFELSE([AC_LANG_PROGRAM([[$term_includes]], [[char **test = (char **)numnames; puts(*test);]])],[AC_DEFINE(HAVE_NUMNAMES) numnames=yes],[numnames=no])
|
||||||
|
AC_MSG_RESULT($numnames)
|
||||||
|
|
||||||
|
AC_MSG_CHECKING(if strnames is available)
|
||||||
|
- AC_LINK_IFELSE([AC_LANG_PROGRAM([[$term_includes]], [[char **test = strnames; puts(*test);]])],[AC_DEFINE(HAVE_STRNAMES) strnames=yes],[strnames=no])
|
||||||
|
+ AC_LINK_IFELSE([AC_LANG_PROGRAM([[$term_includes]], [[char **test = (char **)strnames; puts(*test);]])],[AC_DEFINE(HAVE_STRNAMES) strnames=yes],[strnames=no])
|
||||||
|
AC_MSG_RESULT($strnames)
|
||||||
|
|
||||||
|
dnl There are apparently defective terminal library headers on some
|
Loading…
Reference in New Issue
Block a user