OpenPKG CVS Repository
http://cvs.openpkg.org/
____________________________________________________________________________
Server: cvs.openpkg.org Name: Thomas Lotterer
Root: /e/openpkg/cvs Email: [EMAIL PROTECTED]
Module: openpkg-src Date: 19-Mar-2004 15:15:38
Branch: HEAD Handle: 2004031914153700
Modified files:
openpkg-src/flex flex.patch flex.spec
Log:
fix flex-beta run-time broken on solaris
Summary:
Revision Changes Path
1.9 +9 -3 openpkg-src/flex/flex.patch
1.69 +7 -3 openpkg-src/flex/flex.spec
____________________________________________________________________________
patch -p0 <<'@@ .'
Index: openpkg-src/flex/flex.patch
============================================================================
$ cvs diff -u -r1.8 -r1.9 flex.patch
--- openpkg-src/flex/flex.patch 8 Feb 2004 18:29:32 -0000 1.8
+++ openpkg-src/flex/flex.patch 19 Mar 2004 14:15:37 -0000 1.9
@@ -1,29 +1,35 @@
Index: filter.c
--- filter.c.orig 2003-03-25 17:39:08.000000000 +0100
-+++ filter.c 2004-02-07 13:21:59.000000000 +0100
-@@ -158,10 +158,10 @@
++++ filter.c 2004-03-19 14:43:31.317172000 +0100
+@@ -158,10 +158,13 @@
int r;
/* setup streams again */
++#ifdef NOTOUCHSTDIO
- if ((stdin = fdopen (0, "r")) == NULL)
- flexfatal (_("fdopen(0) failed"));
- if ((stdout = fdopen (1, "w")) == NULL)
- flexfatal (_("fdopen(1) failed"));
++#else
+ if ((freopen ("/dev/stdin", "r", stdin)) == NULL)
+ flexfatal (_("freopen(stdin) failed"));
+ if ((freopen ("/dev/stdout", "w", stdout)) == NULL)
+ flexfatal (_("freopen(stdout) failed"));
++#endif
if ((r = chain->filter_func (chain)) == -1)
flexfatal (_("filter_func failed"));
-@@ -181,8 +181,8 @@
+@@ -181,8 +188,11 @@
if (dup2 (pipes[1], 1) == -1)
flexfatal (_("dup2(pipes[1],1)"));
close (pipes[1]);
++#ifdef NOTOUCHSTDIO
- if ((stdout = fdopen (1, "w")) == NULL)
- flexfatal (_("fdopen(1) failed"));
++#else
+ if ((freopen ("/dev/stdout", "w", stdout)) == NULL)
+ flexfatal (_("freopen(stdout) failed"));
++#endif
return true;
}
@@ .
patch -p0 <<'@@ .'
Index: openpkg-src/flex/flex.spec
============================================================================
$ cvs diff -u -r1.68 -r1.69 flex.spec
--- openpkg-src/flex/flex.spec 12 Feb 2004 17:16:50 -0000 1.68
+++ openpkg-src/flex/flex.spec 19 Mar 2004 14:15:37 -0000 1.69
@@ -39,7 +39,7 @@
Group: Language
License: BSD
Version: %{V_release}
-Release: 20040212
+Release: 20040319
# package options
%option with_beta yes
@@ -88,10 +88,14 @@
%endif
%build
+ CFLAGS="%{l_cflags -O}"
+ case "%{l_platform -t}" in
+ *-sunos* ) CFLAGS="$CFLAGS -DNOTOUCHSTDIO" ;;
+ esac
# configure and build Flex (stable version)
( cd flex-%{V_release_maj}
CC="%{l_cc}" \
- CFLAGS="%{l_cflags -O}" \
+ CFLAGS="$CFLAGS" \
./configure \
--prefix=$RPM_BUILD_ROOT%{l_prefix}
%{l_make} %{l_mflags}
@@ -101,7 +105,7 @@
%if "%{with_beta}" == "yes"
( cd flex-%{V_beta}
CC="%{l_cc}" \
- CFLAGS="%{l_cflags -O}" \
+ CFLAGS="$CFLAGS" \
HELP2MAN=`type -P true` \
./configure \
--prefix=%{l_prefix} \
@@ .
______________________________________________________________________
The OpenPKG Project www.openpkg.org
CVS Repository Commit List [EMAIL PROTECTED]