C++ fixes for gcc3; parts from Jack J. Woehr <jwoehr@attglobal.net>
This commit is contained in:
parent
26c4f762b2
commit
08eb2c7a60
@ -1,10 +1,9 @@
|
|||||||
# $OpenBSD: Makefile,v 1.33 2002/05/13 18:50:39 espie Exp $
|
# $OpenBSD: Makefile,v 1.34 2002/10/13 21:45:46 naddy Exp $
|
||||||
|
|
||||||
COMMENT= "Data Display Debugger, graphical front-end for GDB, etc"
|
COMMENT= "Data Display Debugger, graphical front-end for GDB, etc"
|
||||||
|
|
||||||
DISTNAME= ddd-3.3
|
DISTNAME= ddd-3.3
|
||||||
CATEGORIES= devel
|
CATEGORIES= devel
|
||||||
NEED_VERSION= 1.402
|
|
||||||
MASTER_SITES= ${MASTER_SITE_GNU:=ddd/}
|
MASTER_SITES= ${MASTER_SITE_GNU:=ddd/}
|
||||||
|
|
||||||
HOMEPAGE= http://www.gnu.org/software/ddd/
|
HOMEPAGE= http://www.gnu.org/software/ddd/
|
||||||
@ -19,8 +18,6 @@ USE_GMAKE= Yes
|
|||||||
CONFIGURE_STYLE=gnu
|
CONFIGURE_STYLE=gnu
|
||||||
MODGNU_CONFIG_GUESS_DIRS= ${WRKSRC} ${WRKSRC}/libiberty \
|
MODGNU_CONFIG_GUESS_DIRS= ${WRKSRC} ${WRKSRC}/libiberty \
|
||||||
${WRKSRC}/readline/support
|
${WRKSRC}/readline/support
|
||||||
CONFIGURE_ENV= INSTALL_PROGRAM="${INSTALL_PROGRAM}" \
|
|
||||||
INSTALL_DATA="${INSTALL_DATA}"
|
|
||||||
CONFIGURE_ARGS= --with-readline-libraries=/usr/lib
|
CONFIGURE_ARGS= --with-readline-libraries=/usr/lib
|
||||||
|
|
||||||
MAKE_FLAGS= MAINTAINER="'${MAINTAINER}'"
|
MAKE_FLAGS= MAINTAINER="'${MAINTAINER}'"
|
||||||
|
15
devel/ddd/patches/patch-ddd_aclocal_m4
Normal file
15
devel/ddd/patches/patch-ddd_aclocal_m4
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
$OpenBSD: patch-ddd_aclocal_m4,v 1.1 2002/10/13 21:45:46 naddy Exp $
|
||||||
|
--- ddd/aclocal.m4.orig Sun Oct 13 21:35:46 2002
|
||||||
|
+++ ddd/aclocal.m4 Sun Oct 13 21:43:58 2002
|
||||||
|
@@ -941,7 +941,10 @@ AC_LANG_CPLUSPLUS
|
||||||
|
AC_TRY_COMPILE([#include <iostream.h>],
|
||||||
|
[streampos scan_start;],
|
||||||
|
ice_cv_have_streampos=yes,
|
||||||
|
-ice_cv_have_streampos=no)
|
||||||
|
+AC_TRY_COMPILE([#include <fstream.h>],
|
||||||
|
+[streampos scan_start;],
|
||||||
|
+ice_cv_have_streampos=yes,
|
||||||
|
+ice_cv_have_streampos=no))
|
||||||
|
AC_LANG_RESTORE
|
||||||
|
])
|
||||||
|
AC_MSG_RESULT($ice_cv_have_streampos)
|
@ -1,6 +1,6 @@
|
|||||||
$OpenBSD: patch-ddd_comm-manag_C,v 1.2 2002/03/21 05:28:21 fgsch Exp $
|
$OpenBSD: patch-ddd_comm-manag_C,v 1.3 2002/10/13 21:45:46 naddy Exp $
|
||||||
--- ddd/comm-manag.C.orig Tue Jan 16 09:51:37 2001
|
--- ddd/comm-manag.C.orig Tue Jan 16 05:51:37 2001
|
||||||
+++ ddd/comm-manag.C Wed Mar 13 04:38:32 2002
|
+++ ddd/comm-manag.C Fri Oct 11 12:13:38 2002
|
||||||
@@ -85,6 +85,7 @@ char comm_manager_rcsid[] =
|
@@ -85,6 +85,7 @@ char comm_manager_rcsid[] =
|
||||||
|
|
||||||
#include <ctype.h>
|
#include <ctype.h>
|
||||||
@ -9,7 +9,7 @@ $OpenBSD: patch-ddd_comm-manag_C,v 1.2 2002/03/21 05:28:21 fgsch Exp $
|
|||||||
|
|
||||||
|
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
@@ -800,13 +801,15 @@ void init_session(const string& restart,
|
@@ -800,13 +801,16 @@ void init_session(const string& restart,
|
||||||
info = new InitSessionInfo;
|
info = new InitSessionInfo;
|
||||||
info->restart = restart;
|
info->restart = restart;
|
||||||
info->settings = settings;
|
info->settings = settings;
|
||||||
@ -23,7 +23,8 @@ $OpenBSD: patch-ddd_comm-manag_C,v 1.2 2002/03/21 05:28:21 fgsch Exp $
|
|||||||
|
|
||||||
{
|
{
|
||||||
- ofstream os(info->tempfile);
|
- ofstream os(info->tempfile);
|
||||||
+ ofstream os(temp_fd);
|
+ close(temp_fd); // hack but how to mix mkstemp & ofstream ...
|
||||||
|
+ ofstream os(info->tempfile); // without a ctor ofstream(fd) ?
|
||||||
while (init_commands != "")
|
while (init_commands != "")
|
||||||
{
|
{
|
||||||
string cmd = init_commands.before('\n');
|
string cmd = init_commands.before('\n');
|
||||||
|
27
devel/ddd/patches/patch-ddd_configure
Normal file
27
devel/ddd/patches/patch-ddd_configure
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
$OpenBSD: patch-ddd_configure,v 1.1 2002/10/13 21:45:46 naddy Exp $
|
||||||
|
--- ddd/configure.orig Sun Oct 13 21:34:55 2002
|
||||||
|
+++ ddd/configure Sun Oct 13 21:45:43 2002
|
||||||
|
@@ -6121,7 +6121,23 @@ else
|
||||||
|
echo "configure: failed program was:" >&5
|
||||||
|
cat conftest.$ac_ext >&5
|
||||||
|
rm -rf conftest*
|
||||||
|
+ cat > conftest.$ac_ext <<EOF
|
||||||
|
+#include "confdefs.h"
|
||||||
|
+#include <fstream.h>
|
||||||
|
+int main() {
|
||||||
|
+streampos scan_start;
|
||||||
|
+; return 0; }
|
||||||
|
+EOF
|
||||||
|
+if { (eval echo configure:6133: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
|
||||||
|
+ rm -rf conftest*
|
||||||
|
+ ice_cv_have_streampos=yes
|
||||||
|
+else
|
||||||
|
+ echo "configure: failed program was:" >&5
|
||||||
|
+ cat conftest.$ac_ext >&5
|
||||||
|
+ rm -rf conftest*
|
||||||
|
ice_cv_have_streampos=no
|
||||||
|
+fi
|
||||||
|
+rm -f conftest*
|
||||||
|
fi
|
||||||
|
rm -f conftest*
|
||||||
|
ac_ext=C
|
@ -1,7 +1,7 @@
|
|||||||
$OpenBSD: patch-ddd_exit_C,v 1.2 2002/03/21 05:28:21 fgsch Exp $
|
$OpenBSD: patch-ddd_exit_C,v 1.3 2002/10/13 21:45:46 naddy Exp $
|
||||||
--- ddd/exit.C.orig Tue Dec 19 12:45:49 2000
|
--- ddd/exit.C.orig Tue Dec 19 08:45:49 2000
|
||||||
+++ ddd/exit.C Wed Mar 13 04:32:03 2002
|
+++ ddd/exit.C Fri Oct 11 12:20:34 2002
|
||||||
@@ -1149,8 +1149,10 @@ void report_core(ostream& log)
|
@@ -1149,8 +1149,11 @@ void report_core(ostream& log)
|
||||||
if (!is_core_file("core"))
|
if (!is_core_file("core"))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
@ -10,7 +10,8 @@ $OpenBSD: patch-ddd_exit_C,v 1.2 2002/03/21 05:28:21 fgsch Exp $
|
|||||||
+ char temp_name[] = "/tmp/ddd.XXXXXXXXXX";
|
+ char temp_name[] = "/tmp/ddd.XXXXXXXXXX";
|
||||||
+ int temp_fd = mkstemp(temp_name);
|
+ int temp_fd = mkstemp(temp_name);
|
||||||
+ string tempfile = temp_name;
|
+ string tempfile = temp_name;
|
||||||
+ ofstream os(temp_fd);
|
+ close(temp_fd); // hack ...
|
||||||
|
+ ofstream os(temp_name); // ... no ofstream(fd) ctor
|
||||||
os <<
|
os <<
|
||||||
"set verbose off\n"
|
"set verbose off\n"
|
||||||
"set height 0\n"
|
"set height 0\n"
|
||||||
|
12
devel/ddd/patches/patch-ddd_strclass_C
Normal file
12
devel/ddd/patches/patch-ddd_strclass_C
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
$OpenBSD: patch-ddd_strclass_C,v 1.1 2002/10/13 21:45:46 naddy Exp $
|
||||||
|
--- ddd/strclass.C.orig Sun Oct 13 19:56:55 2002
|
||||||
|
+++ ddd/strclass.C Sun Oct 13 19:59:42 2002
|
||||||
|
@@ -1431,7 +1431,7 @@ istream& operator>>(istream& s, string&
|
||||||
|
}
|
||||||
|
x.rep->s[i] = 0;
|
||||||
|
x.rep->len = i;
|
||||||
|
- int new_state = s.rdstate();
|
||||||
|
+ ios::iostate new_state = s.rdstate();
|
||||||
|
if (i == 0)
|
||||||
|
new_state |= ios::failbit;
|
||||||
|
if (ch == EOF)
|
Loading…
Reference in New Issue
Block a user