This is the mail archive of the
libstdc++@sourceware.cygnus.com
mailing list for the libstdc++ project.
`Misc.' patches
- To: "libstdc++ at sourceware dot cygnus dot com" <libstdc++ at sourceware dot cygnus dot com>
- Subject: `Misc.' patches
- From: Petter Urkedal <petter at matfys dot lth dot se>
- Date: Thu, 02 Mar 2000 13:44:04 +0100
- Organization: Lund Institute of Technology
Can you consider these changes?
* When the library is reconfigured without removing the build
directory, mkc++config _appends_ to c++config.h, and changes
do not take effect due to include guards.
* `streamsize' and friends are not defined in `std'. It seems
to me that the whole contents of c_io_libio.h should be in std.
Is there any technical details behind this omission?
* Need to make types public in basic_string, as gcc now requires :).
* bash, or more precisely
[katsumoto:more]$ bash --version
GNU bash, version 2.03.0(1)-release (i686-pc-linux-gnu)
Copyright 1998 Free Software Foundation, Inc.
does not like empty `for' lists, as noted earier on this list.
See if my hack is not too ugly.
Cheers,
2000-03-02 Petter Urkedal <petter@matfys.lth.se>
* src/Makefile.am (myinstallheaders): Hack to avoid
`for i in ; do'.
* config/c_io_libio.h: Enclose it all in ::std.
* bits/basic_string.h (basic_string<>): Make types and
`npos' public.
* mkc++config: Truncate output file before writing.
Index: mkc++config
===================================================================
RCS file: /cvs/libstdc++/libstdc++/mkc++config,v
retrieving revision 1.2
diff -c -r1.2 mkc++config
*** mkc++config 2000/02/18 05:15:06 1.2
--- mkc++config 2000/03/02 12:23:20
***************
*** 43,49 ****
# Part 2
# cat this into generated bits/c++config.h
! cat $BASE_H temp-4 >> $OUT_H
rm temp-1 temp-2 temp-3 temp-4
--- 43,49 ----
# Part 2
# cat this into generated bits/c++config.h
! cat $BASE_H temp-4 > $OUT_H
rm temp-1 temp-2 temp-3 temp-4
Index: bits/basic_string.h
===================================================================
RCS file: /cvs/libstdc++/libstdc++/bits/basic_string.h,v
retrieving revision 1.52
diff -c -r1.52 basic_string.h
*** basic_string.h 2000/03/01 02:29:12 1.52
--- basic_string.h 2000/03/02 12:23:20
***************
*** 81,86 ****
--- 81,87 ----
class basic_string
{
// Types:
+ public:
typedef _Traits traits_type;
typedef typename _Traits::char_type value_type;
typedef _Alloc allocator_type;
***************
*** 95,101 ****
typedef reverse_iterator<const_iterator> const_reverse_iterator;
typedef reverse_iterator<iterator> reverse_iterator;
- public:
// (Public) Data Members:
// NB: This is an unsigned type, and thus represents the maximum
--- 96,101 ----
Index: config/c_io_libio.h
===================================================================
RCS file: /cvs/libstdc++/libstdc++/config/c_io_libio.h,v
retrieving revision 1.1
diff -c -r1.1 c_io_libio.h
*** c_io_libio.h 2000/02/25 23:54:18 1.1
--- c_io_libio.h 2000/03/02 12:23:20
***************
*** 34,39 ****
--- 34,41 ----
#include <libio.h>
+ namespace std {
+
// from fpos.h
typedef _IO_off_t streamoff;
typedef _IO_ssize_t streamsize; // Signed integral type
***************
*** 90,95 ****
--- 92,99 ----
static const __int_type _S_out = _IOS_OUTPUT;
static const __int_type _S_trunc = _IOS_TRUNC;
};
+
+ }
#endif // _CPP_IO_LIBIO_H
Index: src/Makefile.am
===================================================================
RCS file: /cvs/libstdc++/libstdc++/src/Makefile.am,v
retrieving revision 1.81
diff -c -r1.81 Makefile.am
*** Makefile.am 2000/03/01 02:29:13 1.81
--- Makefile.am 2000/03/02 12:23:20
***************
*** 201,209 ****
echo "$(INSTALL_DATA) $(top_builddir)/$$i $(myincludep)bits/"; \
$(INSTALL_DATA) $(top_builddir)/$$i $(myincludep)bits/; \
done; \
! for i in $(libio_headers); do \
! echo "$(INSTALL_DATA) $$i $(myincludep)"; \
! $(INSTALL_DATA) $$i $(myincludep); \
done; \
fi;
--- 201,210 ----
echo "$(INSTALL_DATA) $(top_builddir)/$$i $(myincludep)bits/"; \
$(INSTALL_DATA) $(top_builddir)/$$i $(myincludep)bits/; \
done; \
! for i in _none_ $(libio_headers); do \
! test $$i = _none_ \
! || ( echo "$(INSTALL_DATA) $$i $(myincludep)"; \
! $(INSTALL_DATA) $$i $(myincludep); ) \
done; \
fi;