commit 575c0706845c40b004159c14667eb2331ff73ef1
Author: Marcin Krol <[email protected]>
Date:   Sun Aug 28 12:42:41 2022 +0200

    - bcond R: libtextstyle too, disable looking for libtexstyle if
      no libtextyle was requested

 bison.spec            |  8 +++++++-
 no_libtextstyle.patch | 21 +++++++++++++++++++++
 2 files changed, 28 insertions(+), 1 deletion(-)
---
diff --git a/bison.spec b/bison.spec
index 928384d..8723b89 100644
--- a/bison.spec
+++ b/bison.spec
@@ -17,6 +17,7 @@ Source0:      
https://ftp.gnu.org/gnu/bison/%{name}-%{version}.tar.lz
 # Source0-md5: 26e76218c2a50a0dd307286d42eb0af9
 Source1:       %{name}.1.pl
 Patch0:                %{name}-info.patch
+Patch1:                no_libtextstyle.patch
 URL:           http://www.gnu.org/software/bison/
 BuildRequires: flex
 BuildRequires: gcc >= 5:3.2
@@ -31,7 +32,7 @@ BuildRequires:        rpmbuild(find_lang) >= 1.31
 BuildRequires: tar >= 1:1.22
 BuildRequires: texinfo >= 4.0
 Requires:      %{name}-runtime = %{version}-%{release}
-Requires:      libtextstyle >= 0.20.5
+%{?with_libtextstyle:Requires: libtextstyle >= 0.20.5}
 Requires:      m4 >= 1.4.6
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
@@ -107,10 +108,15 @@ zawierajacych parsery wygenerowane przez bisona.
 %prep
 %setup -q
 %patch0 -p1
+%{!?with_libtextstyle:%patch1 -p1}
 
 %{__rm} po/stamp-po
 
 %build
+%{__aclocal} -I m4
+%{__autoconf}
+%{__autoheader}
+%{__automake}
 %configure \
        --disable-silent-rules
 %{__make}
diff --git a/no_libtextstyle.patch b/no_libtextstyle.patch
new file mode 100644
index 0000000..d5aa64b
--- /dev/null
+++ b/no_libtextstyle.patch
@@ -0,0 +1,21 @@
+diff -ur bison-3.8.2.orig/m4/libtextstyle-optional.m4 
bison-3.8.2/m4/libtextstyle-optional.m4
+--- bison-3.8.2.orig/m4/libtextstyle-optional.m4       2021-03-10 
06:41:25.000000000 +0100
++++ bison-3.8.2/m4/libtextstyle-optional.m4    2022-08-28 12:38:58.097300031 
+0200
+@@ -21,14 +21,9 @@
+ 
+ AC_DEFUN([gl_LIBTEXTSTYLE_OPTIONAL],
+ [
+-  gl_LIBTEXTSTYLE([$1])
+-  if test $HAVE_LIBTEXTSTYLE = yes; then
+-    TEXTSTYLE_H=
+-  else
+-    TEXTSTYLE_H=textstyle.h
+-    AC_REQUIRE([AC_C_INLINE])
+-    AC_CHECK_FUNCS_ONCE([tcdrain])
+-  fi
++  TEXTSTYLE_H=textstyle.h
++  AC_REQUIRE([AC_C_INLINE])
++  AC_CHECK_FUNCS_ONCE([tcdrain])
+   AC_SUBST([TEXTSTYLE_H])
+   AM_CONDITIONAL([GL_GENERATE_TEXTSTYLE_H], [test -n "$TEXTSTYLE_H"])
+ ])
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/bison.git/commitdiff/575c0706845c40b004159c14667eb2331ff73ef1

_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit

Reply via email to