View | Details | Raw Unified | Return to issue 13632
Collapse All | Expand All

(-)misc/build/STLport-4.0/src/fstream.cpp (+15 lines)
Lines 30-35 Link Here
30
#  include <sys/mman.h>           // For mmap
30
#  include <sys/mman.h>           // For mmap
31
#  include <unistd.h>
31
#  include <unistd.h>
32
#  include <fcntl.h>
32
#  include <fcntl.h>
33
# ifdef __APPLE__
34
#  include <sys/sysctl.h>
35
# endif
33
#elif defined (__STL_USE_WIN32_IO)
36
#elif defined (__STL_USE_WIN32_IO)
34
# define WIN32_LEAN_AND_MEAN
37
# define WIN32_LEAN_AND_MEAN
35
#  include <windows.h>
38
#  include <windows.h>
Lines 326-332 Link Here
326
{
329
{
327
  if (!_M_page_size)
330
  if (!_M_page_size)
328
#if defined (__STL_UNIX)
331
#if defined (__STL_UNIX)
332
#  if defined (__APPLE__)
333
  {
334
  int mib[2];
335
  size_t pagesize, len;
336
  mib[0] = CTL_HW;
337
  mib[1] = HW_PAGESIZE;
338
  len = sizeof(pagesize);
339
  sysctl(mib, 2, &pagesize, &len, NULL, 0);
340
  _M_page_size = pagesize;
341
  }
342
#  else
329
  _M_page_size = sysconf(_SC_PAGESIZE);
343
  _M_page_size = sysconf(_SC_PAGESIZE);
344
#  endif
330
# elif defined (__STL_USE_WIN32_IO)
345
# elif defined (__STL_USE_WIN32_IO)
331
  {
346
  {
332
  SYSTEM_INFO SystemInfo;
347
  SYSTEM_INFO SystemInfo;
(-)misc/build/STLport-4.0/src/gcc-apple-macosx.mak (+70 lines)
Line 0 Link Here
1
#
2
# Note : this makefile is for gcc-2.95 and later !
3
#
4
5
#
6
# compiler
7
#
8
CC = cc
9
CXX = cc
10
11
#
12
# Basename for libraries
13
#
14
LIB_BASENAME = libstlport_gcc
15
16
#
17
# guts for common stuff
18
#
19
#
20
LINK=libtool -static -o
21
# 2.95 flag
22
DYN_LINK=libtool -dynamic -framework System -lcc_dynamic -lstdc++ -install_name @executable_path/$(@F) -o
23
24
OBJEXT=o
25
DYNEXT=dylib
26
STEXT=a
27
RM=rm -Rf
28
PATH_SEP=/
29
MKDIR=mkdir -p
30
COMP=GCC$(ARCH)
31
32
all: all_dynamic all_static
33
34
include common_macros.mak
35
36
WARNING_FLAGS= -W -Wno-sign-compare -Wno-unused -Wno-uninitialized -Wno-long-double
37
38
CXXFLAGS_COMMON = -I${STLPORT_DIR} ${WARNING_FLAGS} -D_REENTRANT -D_PTHREADS
39
40
ifneq ("$(shell uname -r)", "1.2")
41
CXXFLAGS_COMMON += -fno-coalesce
42
endif
43
44
CXXFLAGS_RELEASE_static = $(CXXFLAGS_COMMON) -O2
45
CXXFLAGS_RELEASE_dynamic = $(CXXFLAGS_COMMON) -O2 -fPIC 
46
47
CXXFLAGS_DEBUG_static = $(CXXFLAGS_COMMON) -g
48
CXXFLAGS_DEBUG_dynamic = $(CXXFLAGS_COMMON) -g -fPIC
49
50
CXXFLAGS_STLDEBUG_static = $(CXXFLAGS_DEBUG_static) -D__STL_DEBUG
51
CXXFLAGS_STLDEBUG_dynamic = $(CXXFLAGS_DEBUG_dynamic) -D__STL_DEBUG -fPIC
52
53
# Add a single source file where all static data members for template classes
54
# are initialized
55
RELEASE_OBJECTS_static += \
56
	$(RELEASE_OBJDIR_static)$(PATH_SEP)static_instances.o
57
DEBUG_OBJECTS_static += \
58
	$(DEBUG_OBJDIR_static)$(PATH_SEP)static_instances.o
59
STLDEBUG_OBJECTS_static += \
60
	$(STLDEBUG_OBJDIR_static)$(PATH_SEP)static_instances.o
61
RELEASE_OBJECTS_dynamic += \
62
	$(RELEASE_OBJDIR_dynamic)$(PATH_SEP)static_instances.o
63
DEBUG_OBJECTS_dynamic += \
64
	$(DEBUG_OBJDIR_dynamic)$(PATH_SEP)static_instances.o
65
STLDEBUG_OBJECTS_dynamic += \
66
	$(STLDEBUG_OBJDIR_dynamic)$(PATH_SEP)static_instances.o
67
68
include common_percent_rules.mak
69
include common_rules.mak
70
(-)misc/build/STLport-4.0/src/message_facets.cpp (-2 / +2 lines)
Lines 31-38 Link Here
31
  // Don't bother to do anything unless we're using a non-default ctype facet
31
  // Don't bother to do anything unless we're using a non-default ctype facet
32
  try {
32
  try {
33
    typedef ctype<_Char> wctype;
33
    typedef ctype<_Char> wctype;
34
    const wctype& wct = use_facet<wctype>(L);
34
    wctype& wct = (wctype &)use_facet<wctype>(L);
35
    const wctype* zz = (const wctype*)0;
35
    wctype* zz = (wctype*)0;
36
    if (typeid(&wct) != typeid(zz)) {
36
    if (typeid(&wct) != typeid(zz)) {
37
      if (!M)
37
      if (!M)
38
        M = new hash_map<int, locale, hash<int>, equal_to<int> >;
38
        M = new hash_map<int, locale, hash<int>, equal_to<int> >;
(-)misc/build/STLport-4.0/src/num_put_float.cpp (-6 / +8 lines)
Lines 43-55 Link Here
43
43
44
# ifdef __STL_UNIX
44
# ifdef __STL_UNIX
45
45
46
# include <values.h>
46
#  ifndef __APPLE__
47
#   include <values.h>
48
#  endif
47
49
48
# if defined (__sun) 
50
# if defined (__sun) 
49
#  include <floatingpoint.h>
51
#  include <floatingpoint.h>
50
# endif
52
# endif
51
53
52
# if !defined(__STL_USE_GLIBC) && !defined(__FreeBSD__)   // dwa 1/10/00 - nan.h not supplied with gcc
54
# if !defined(__STL_USE_GLIBC) && !defined(__FreeBSD__) && !( defined(__GNUC__) && defined(__APPLE__) )   // dwa 1/10/00 - nan.h not supplied with gcc
53
// DEC & Solaris need this
55
// DEC & Solaris need this
54
#  include <nan.h>
56
#  include <nan.h>
55
# endif
57
# endif
Lines 95-101 Link Here
95
# endif
97
# endif
96
  inline bool _Stl_is_inf(double x)        { return isinf(x); }
98
  inline bool _Stl_is_inf(double x)        { return isinf(x); }
97
  inline bool _Stl_is_neg_inf(double x)    { return isinf(x) < 0; }
99
  inline bool _Stl_is_neg_inf(double x)    { return isinf(x) < 0; }
98
#elif defined(__unix) && !defined(__FreeBSD__) /* (__sgi) || defined (__sun) IRIX , Solaris, others ? */
100
#elif defined(__unix) && !defined(__FreeBSD__) && !defined(__APPLE__) /* (__sgi) || defined (__sun) IRIX , Solaris, others ? */
99
  inline bool _Stl_is_nan_or_inf(double x) { return IsNANorINF(x); }
101
  inline bool _Stl_is_nan_or_inf(double x) { return IsNANorINF(x); }
100
  inline bool _Stl_is_inf(double x)        { return IsNANorINF(x) && IsINF(x); }
102
  inline bool _Stl_is_inf(double x)        { return IsNANorINF(x) && IsINF(x); }
101
  inline bool _Stl_is_neg_inf(double x)    { return (IsINF(x)) && (x < 0.0); }
103
  inline bool _Stl_is_neg_inf(double x)    { return (IsINF(x)) && (x < 0.0); }
Lines 124-130 Link Here
124
  bool _Stl_is_inf(double x)        { return !isfinite(x); }
126
  bool _Stl_is_inf(double x)        { return !isfinite(x); }
125
  bool _Stl_is_neg_inf(double x)    { return !isfinite(x) && signbit(x); }
127
  bool _Stl_is_neg_inf(double x)    { return !isfinite(x) && signbit(x); }
126
  bool _Stl_is_neg_nan(double x)    { return isnan(x) && signbit(x); }
128
  bool _Stl_is_neg_nan(double x)    { return isnan(x) && signbit(x); }
127
#elif defined (__FreeBSD__)
129
#elif defined (__FreeBSD__) || ( defined (__GNUC__) && defined (__APPLE__) )
128
 inline bool _Stl_is_nan_or_inf(double x) { return !finite(x); }
130
 inline bool _Stl_is_nan_or_inf(double x) { return !finite(x); }
129
 inline bool _Stl_is_inf(double x)        {
131
 inline bool _Stl_is_inf(double x)        {
130
   return _Stl_is_nan_or_inf(x) && ! isnan(x);
132
   return _Stl_is_nan_or_inf(x) && ! isnan(x);
Lines 193-199 Link Here
193
     { return _ldfcvt(*(long_double*)&x, n, pt, sign); }
195
     { return _ldfcvt(*(long_double*)&x, n, pt, sign); }
194
#  endif
196
#  endif
195
197
196
#elif defined (__unix)  && !defined(__FreeBSD__)/* defined(__sgi) IRIX */
198
#elif defined (__unix)  && !defined(__FreeBSD__) && !defined(__APPLE__) /* defined(__sgi) IRIX */
197
  inline char* _Stl_ecvtR(double x, int n, int* pt, int* sign, char* buf)
199
  inline char* _Stl_ecvtR(double x, int n, int* pt, int* sign, char* buf)
198
    { return ecvt_r(x, n, pt, sign, buf); }
200
    { return ecvt_r(x, n, pt, sign, buf); }
199
  inline char* _Stl_fcvtR(double x, int n, int* pt, int* sign, char* buf)
201
  inline char* _Stl_fcvtR(double x, int n, int* pt, int* sign, char* buf)
Lines 203-209 Link Here
203
  inline char* _Stl_qfcvtR(long double x, int n, int* pt, int* sign, char* buf)
205
  inline char* _Stl_qfcvtR(long double x, int n, int* pt, int* sign, char* buf)
204
    { return qfcvt_r(x, n, pt, sign, buf); }
206
    { return qfcvt_r(x, n, pt, sign, buf); }
205
207
206
#elif defined (__FreeBSD__)
208
#elif defined (__FreeBSD__) || ( defined (__GNUC__) && defined (__APPLE__) )
207
209
208
/*
210
/*
209
 * Copyright (c) 1995-1997 The Apache Group.  All rights reserved.
211
 * Copyright (c) 1995-1997 The Apache Group.  All rights reserved.
(-)misc/build/STLport-4.0/src/static_instances.cpp (+31 lines)
Line 0 Link Here
1
/*
2
 * Copyright (c) 1999
3
 * Silicon Graphics Computer Systems, Inc.
4
 *
5
 * Copyright (c) 1999 
6
 * Boris Fomitchev
7
 *
8
 * This material is provided "as is", with absolutely no warranty expressed
9
 * or implied. Any use is at your own risk.
10
 *
11
 * Permission to use or copy this software for any purpose is hereby granted 
12
 * without fee, provided the above notices are retained on all copies.
13
 * Permission to modify the code and to distribute modified code is granted,
14
 * provided the above notices are retained, and a notice that the code was
15
 * modified is included with the above copyright notice.
16
 *
17
 */
18
19
# ifndef __PUT_STATIC_DATA_MEMBERS_HERE
20
# define __PUT_STATIC_DATA_MEMBERS_HERE
21
# endif
22
23
# include "stlport_prefix.h"
24
25
# include <hash_map>
26
# include <limits>
27
# include <rope>
28
29
// Local Variables:
30
// mode:C++
31
// End:
(-)misc/build/STLport-4.0/stlport/config/stl_gcc.h (+27 lines)
Lines 42-47 Link Here
42
#   define __STL_NO_NATIVE_MBSTATE_T      1
42
#   define __STL_NO_NATIVE_MBSTATE_T      1
43
# endif
43
# endif
44
44
45
/* Mac OS X is a little different with namespaces and cannot instantiate
46
 * static data members in template classes */
47
# if defined (__APPLE__)
48
/* Mac OS X is missing a required typedef and standard macro */
49
typedef unsigned int wint_t;
50
#  define __unix
51
/* Mac OS X needs one and only one source file to initialize all static data
52
 * members in template classes. Only one source file in an executable or
53
 * library can declare instances for such data members, otherwise duplicate
54
 * symbols will be generated. */
55
#  ifdef __PUT_STATIC_DATA_MEMBERS_HERE
56
#   define __STL_NO_STATIC_TEMPLATE_DATA
57
#   define __STL_STATIC_TEMPLATE_DATA 0
58
#   define __STL_WEAK_ATTRIBUTE 0
59
#   define __DECLARE_INSTANCE(type,item,init) type item init
60
#  endif
61
/* Mac OS X needs all "::" scope references to be "std::" */
62
#  undef __STL_VENDOR_GLOBAL_STD
63
#  undef __STL_VENDOR_GLOBAL_CSTD
64
#  define __STL_NO_CSTD_FUNCTION_IMPORTS
65
/* Workaround for the broken Mac OS X C++ preprocessor which cannot handle
66
 * parameterized macros in #include statements */
67
#  define __STL_NATIVE_HEADER(header) <../g++/##header##>
68
#  define __STL_NATIVE_C_HEADER(header) <../include/##header##>
69
#  define __STL_NATIVE_CPP_C_HEADER(header) <../g++/##header##>
70
#  define __STL_NATIVE_OLD_STREAMS_HEADER(header) <../g++/##header##>
71
# endif
45
72
46
/* g++ 2.7.x and above */
73
/* g++ 2.7.x and above */
47
#   define __STL_LONG_LONG    1
74
#   define __STL_LONG_LONG    1
(-)misc/build/STLport-4.0/stlport/cwchar (-1 / +1 lines)
Lines 34-40 Link Here
34
34
35
# if defined  (__STL_USE_NEW_C_HEADERS) && ! defined (__HP_aCC)
35
# if defined  (__STL_USE_NEW_C_HEADERS) && ! defined (__HP_aCC)
36
#  include __STL_NATIVE_CPP_C_HEADER(cwchar)
36
#  include __STL_NATIVE_CPP_C_HEADER(cwchar)
37
# elif defined (__MRC__) || defined (__SC__) || defined (__BORLANDC__)
37
# elif defined (__MRC__) || defined (__SC__) || defined (__BORLANDC__) || (defined (__GNUC__) && defined (__APPLE__))
38
#  include __STL_NATIVE_C_HEADER(stddef.h)
38
#  include __STL_NATIVE_C_HEADER(stddef.h)
39
# else
39
# else
40
#  include __STL_NATIVE_C_HEADER(wchar.h)
40
#  include __STL_NATIVE_C_HEADER(wchar.h)
(-)misc/build/STLport-4.0/stlport/exception (-1 / +1 lines)
Lines 42-48 Link Here
42
#  undef __STL_INCOMPLETE_EXCEPTION_HEADER
42
#  undef __STL_INCOMPLETE_EXCEPTION_HEADER
43
# endif
43
# endif
44
44
45
#  if defined (__GNUC__) && (__GNUC_MINOR__ >= 8 )
45
#  if defined (__GNUC__) && (__GNUC_MINOR__ >= 8 ) && ! defined (__APPLE__)
46
#    include <../include/exception>
46
#    include <../include/exception>
47
#  else
47
#  else
48
#    include __STL_NATIVE_HEADER(exception)
48
#    include __STL_NATIVE_HEADER(exception)
(-)misc/build/STLport-4.0/stlport/exception.h (-46 / +46 lines)
Lines 1-46 Link Here
1
/*
1
/*
2
 * Copyright (c) 1999 
2
 * Copyright (c) 1999 
3
 * Boris Fomitchev
3
 * Boris Fomitchev
4
 *
4
 *
5
 * This material is provided "as is", with absolutely no warranty expressed
5
 * This material is provided "as is", with absolutely no warranty expressed
6
 * or implied. Any use is at your own risk.
6
 * or implied. Any use is at your own risk.
7
 *
7
 *
8
 * Permission to use or copy this software for any purpose is hereby granted 
8
 * Permission to use or copy this software for any purpose is hereby granted 
9
 * without fee, provided the above notices are retained on all copies.
9
 * without fee, provided the above notices are retained on all copies.
10
 * Permission to modify the code and to distribute modified code is granted,
10
 * Permission to modify the code and to distribute modified code is granted,
11
 * provided the above notices are retained, and a notice that the code was
11
 * provided the above notices are retained, and a notice that the code was
12
 * modified is included with the above copyright notice.
12
 * modified is included with the above copyright notice.
13
 *
13
 *
14
 */
14
 */
15
15
16
#ifndef __STLPORT_OLDSTD_exception
16
#ifndef __STLPORT_OLDSTD_exception
17
# define __STLPORT_OLDSTD_exception
17
# define __STLPORT_OLDSTD_exception
18
18
19
# if !defined (__STL_OUTERMOST_HEADER_ID)
19
# if !defined (__STL_OUTERMOST_HEADER_ID)
20
#  define __STL_OUTERMOST_HEADER_ID 0x824
20
#  define __STL_OUTERMOST_HEADER_ID 0x824
21
#  include <stl/_prolog.h>
21
#  include <stl/_prolog.h>
22
# elif (__STL_OUTERMOST_HEADER_ID == 0x824) && ! defined (__STL_DONT_POP_0x824)
22
# elif (__STL_OUTERMOST_HEADER_ID == 0x824) && ! defined (__STL_DONT_POP_0x824)
23
#  define __STL_DONT_POP_0x824
23
#  define __STL_DONT_POP_0x824
24
# endif
24
# endif
25
25
26
# if defined (__GNUC__) && (__GNUC_MINOR__ >= 8 )
26
# if defined (__GNUC__) && (__GNUC_MINOR__ >= 8 ) && ! defined (__APPLE__)
27
#  include <../include/exception.h>
27
#  include <../include/exception.h>
28
# elif defined (__BORLANDC__)
28
# elif defined (__BORLANDC__)
29
#  include <exception.>
29
#  include <exception.>
30
# else
30
# else
31
#  include __STL_NATIVE_HEADER(exception.h)
31
#  include __STL_NATIVE_HEADER(exception.h)
32
# endif
32
# endif
33
33
34
# if (__STL_OUTERMOST_HEADER_ID == 0x824)
34
# if (__STL_OUTERMOST_HEADER_ID == 0x824)
35
#  if ! defined (__STL_DONT_POP_0x824)
35
#  if ! defined (__STL_DONT_POP_0x824)
36
#   include <stl/_epilog.h>
36
#   include <stl/_epilog.h>
37
#   undef  __STL_OUTERMOST_HEADER_ID
37
#   undef  __STL_OUTERMOST_HEADER_ID
38
#   endif
38
#   endif
39
#   undef  __STL_DONT_POP_0x824
39
#   undef  __STL_DONT_POP_0x824
40
# endif
40
# endif
41
41
42
#endif /* __STLPORT_OLDSTD_exception */
42
#endif /* __STLPORT_OLDSTD_exception */
43
43
44
// Local Variables:
44
// Local Variables:
45
// mode:C++
45
// mode:C++
46
// End:
46
// End:
(-)misc/build/STLport-4.0/stlport/new (-1 / +1 lines)
Lines 43-49 Link Here
43
#endif
43
#endif
44
44
45
# if !defined (__STL_NO_NEW_NEW_HEADER)
45
# if !defined (__STL_NO_NEW_NEW_HEADER)
46
#  if ( defined (__GNUC__) && (__GNUC_MINOR__ >= 8 )) || ( defined (__MVS__) && ! defined (__GNUC__))
46
#  if ( defined (__GNUC__) && (__GNUC_MINOR__ >= 8 ) && ! defined (__APPLE__)) || ( defined (__MVS__) && ! defined (__GNUC__))
47
#    include __STL_NATIVE_C_HEADER(new)
47
#    include __STL_NATIVE_C_HEADER(new)
48
#   else
48
#   else
49
#    include __STL_NATIVE_HEADER(new)
49
#    include __STL_NATIVE_HEADER(new)
(-)misc/build/STLport-4.0/stlport/new.h (-1 / +1 lines)
Lines 22-28 Link Here
22
# endif
22
# endif
23
23
24
# ifndef __STL_WINCE
24
# ifndef __STL_WINCE
25
# if ( defined (__GNUC__) && (__GNUC_MINOR__ >= 8 )) || ( defined (__MVS__) && ! defined (__GNUC__))
25
# if ( defined (__GNUC__) && (__GNUC_MINOR__ >= 8 ) && ! defined (__APPLE__)) || ( defined (__MVS__) && ! defined (__GNUC__))
26
#   include __STL_NATIVE_C_HEADER(new.h)
26
#   include __STL_NATIVE_C_HEADER(new.h)
27
# elif defined (__BORLANDC__)
27
# elif defined (__BORLANDC__)
28
#  include <new.>
28
#  include <new.>
(-)misc/build/STLport-4.0/stlport/stl/_alloc.c (-1 / +2 lines)
Lines 301-306 Link Here
301
    _Node_Alloc_Lock<__threads, __inst>::_S_lock __STL_MUTEX_INITIALIZER;
301
    _Node_Alloc_Lock<__threads, __inst>::_S_lock __STL_MUTEX_INITIALIZER;
302
#endif
302
#endif
303
303
304
#  if defined(__GNUC__) && !defined(__APPLE__)
304
template <bool __threads, int __inst>
305
template <bool __threads, int __inst>
305
_Node_alloc_obj * __STL_VOLATILE
306
_Node_alloc_obj * __STL_VOLATILE
306
__node_alloc<__threads, __inst>::_S_free_list[_NFREELISTS]
307
__node_alloc<__threads, __inst>::_S_free_list[_NFREELISTS]
Lines 317-323 Link Here
317
318
318
template <bool __threads, int __inst>
319
template <bool __threads, int __inst>
319
size_t __node_alloc<__threads, __inst>::_S_heap_size = 0;
320
size_t __node_alloc<__threads, __inst>::_S_heap_size = 0;
320
321
#  endif /* defined(__GNUC__) && !defined(__APPLE__) */
321
322
322
# else /* ( __STL_STATIC_TEMPLATE_DATA > 0 ) */
323
# else /* ( __STL_STATIC_TEMPLATE_DATA > 0 ) */
323
324
(-)misc/build/STLport-4.0/stlport/stl/_limits.c (-44 / +44 lines)
Lines 92-112 Link Here
92
# undef __declare_numeric_base_member
92
# undef __declare_numeric_base_member
93
93
94
# if defined (__STL_NO_STATIC_TEMPLATE_DATA)
94
# if defined (__STL_NO_STATIC_TEMPLATE_DATA)
95
#  define __HACK_ILIMITS(_Int, __imin, __imax, __idigits) _Integer_limits<_Int, __imin, __imax, __idigits>
95
#  define __HACK_ILIMITS(_Int, __imin, __imax, __idigits, __ismod) _Integer_limits<_Int, __imin, __imax, __idigits, __ismod>
96
#  define __HACK_NOTHING
96
#  define __HACK_NOTHING
97
#  define __declare_integer_limits_member(_Int, __imin, __imax, __idigits, __type, __mem) \
97
#  define __declare_integer_limits_member(_Int, __imin, __imax, __idigits, __ismod, __type, __mem) \
98
  __DECLARE_INSTANCE(const __type, __HACK_ILIMITS(_Int, __imin, __imax, __idigits):: __mem,__HACK_NOTHING)
98
  __DECLARE_INSTANCE(const __type, __HACK_ILIMITS(_Int, __imin, __imax, __idigits, __ismod):: __mem,__HACK_NOTHING)
99
99
100
#  define __declare_int_members(_Int, __imin, __imax, __idigits) \
100
#  define __declare_int_members(_Int, __imin, __imax, __idigits, __ismod) \
101
__declare_integer_limits_member(_Int, __imin, __imax, __idigits, bool, is_specialized);\
101
__declare_integer_limits_member(_Int, __imin, __imax, __idigits, __ismod, bool, is_specialized);\
102
__declare_integer_limits_member(_Int, __imin, __imax, __idigits, int, digits);\
102
__declare_integer_limits_member(_Int, __imin, __imax, __idigits, __ismod, int, digits);\
103
__declare_integer_limits_member(_Int, __imin, __imax, __idigits, int, digits10);\
103
__declare_integer_limits_member(_Int, __imin, __imax, __idigits, __ismod, int, digits10);\
104
__declare_integer_limits_member(_Int, __imin, __imax, __idigits, bool, is_signed);\
104
__declare_integer_limits_member(_Int, __imin, __imax, __idigits, __ismod, bool, is_signed);\
105
__declare_integer_limits_member(_Int, __imin, __imax, __idigits, bool, is_integer);\
105
__declare_integer_limits_member(_Int, __imin, __imax, __idigits, __ismod, bool, is_integer);\
106
__declare_integer_limits_member(_Int, __imin, __imax, __idigits, bool, is_exact);\
106
__declare_integer_limits_member(_Int, __imin, __imax, __idigits, __ismod, bool, is_exact);\
107
__declare_integer_limits_member(_Int, __imin, __imax, __idigits, int, radix);\
107
__declare_integer_limits_member(_Int, __imin, __imax, __idigits, __ismod, int, radix);\
108
__declare_integer_limits_member(_Int, __imin, __imax, __idigits, bool, is_bounded);\
108
__declare_integer_limits_member(_Int, __imin, __imax, __idigits, __ismod, bool, is_bounded);\
109
__declare_integer_limits_member(_Int, __imin, __imax, __idigits, bool, is_modulo);
109
__declare_integer_limits_member(_Int, __imin, __imax, __idigits, __ismod, bool, is_modulo);
110
110
111
111
112
#  else
112
#  else
Lines 197-221 Link Here
197
197
198
# ifdef __STL_NO_STATIC_TEMPLATE_DATA
198
# ifdef __STL_NO_STATIC_TEMPLATE_DATA
199
#  ifndef __STL_NO_BOOL
199
#  ifndef __STL_NO_BOOL
200
__declare_int_members(bool, false, true, 0)
200
__declare_int_members(bool, false, true, 0, false)
201
#  endif
201
#  endif
202
__declare_int_members(char, CHAR_MIN, CHAR_MAX, -1)
202
__declare_int_members(char, CHAR_MIN, CHAR_MAX, -1, true)
203
#  ifndef __STL_NO_SIGNED_BUILTINS
203
#  ifndef __STL_NO_SIGNED_BUILTINS
204
__declare_int_members(signed char, SCHAR_MIN, SCHAR_MAX, -1)
204
__declare_int_members(signed char, SCHAR_MIN, SCHAR_MAX, -1, true)
205
#  endif
205
#  endif
206
__declare_int_members(unsigned char, 0, UCHAR_MAX, -1)
206
__declare_int_members(unsigned char, 0, UCHAR_MAX, -1, true)
207
#  if defined (__STL_HAS_WCHAR_T) && !defined ( __STL_WCHAR_T_IS_USHORT)
207
#  if defined (__STL_HAS_WCHAR_T) && !defined ( __STL_WCHAR_T_IS_USHORT)
208
__declare_int_members(wchar_t, INT_MIN, INT_MAX, -1)
208
__declare_int_members(wchar_t, INT_MIN, INT_MAX, -1, true)
209
#  endif
209
#  endif
210
__declare_int_members(short, SHRT_MIN, SHRT_MAX, -1)
210
__declare_int_members(short, SHRT_MIN, SHRT_MAX, -1, true)
211
__declare_int_members(unsigned short, 0, USHRT_MAX, -1)
211
__declare_int_members(unsigned short, 0, USHRT_MAX, -1, true)
212
__declare_int_members(int, INT_MIN, INT_MAX, -1)
212
__declare_int_members(int, INT_MIN, INT_MAX, -1, true)
213
__declare_int_members(unsigned int, 0, UINT_MAX, -1)
213
__declare_int_members(unsigned int, 0, UINT_MAX, -1, true)
214
__declare_int_members(long, LONG_MIN, LONG_MAX, -1)
214
__declare_int_members(long, LONG_MIN, LONG_MAX, -1, true)
215
__declare_int_members(unsigned long, 0, ULONG_MAX, -1)
215
__declare_int_members(unsigned long, 0, ULONG_MAX, -1, true)
216
#  ifdef __STL_LONG_LONG
216
#  ifdef __STL_LONG_LONG
217
__declare_int_members(long long, LONGLONG_MIN, LONG_MAX, -1)
217
__declare_int_members(long long, LONGLONG_MIN, LONG_MAX, -1, true)
218
__declare_int_members(unsigned long long, 0, ULONGLONG_MAX, -1)
218
__declare_int_members(unsigned long long, 0, ULONGLONG_MAX, -1, true)
219
#  endif
219
#  endif
220
__declare_float_members(float, FLT_MANT_DIG,FLT_DIG,
220
__declare_float_members(float, FLT_MANT_DIG,FLT_DIG,
221
                  	    FLT_MIN_EXP,
221
                  	    FLT_MIN_EXP,
Lines 318-343 Link Here
318
318
319
#else
319
#else
320
320
321
__DECLARE_INSTANCE(_F_rep,
322
                   _LimG<bool>::_F_inf, __STL_ARRAY_STATIC_INIT(__STL_FLOAT_INF_REP));
323
__DECLARE_INSTANCE(_F_rep,
324
                   _LimG<bool>::_F_qNaN, __STL_ARRAY_STATIC_INIT(__STL_FLOAT_QNAN_REP));
325
__DECLARE_INSTANCE(_F_rep,
326
                   _LimG<bool>::_F_sNaN, __STL_ARRAY_STATIC_INIT(__STL_FLOAT_SNAN_REP));
327
__DECLARE_INSTANCE(_D_rep,
328
                   _LimG<bool>::_D_inf, __STL_ARRAY_STATIC_INIT(__STL_DOUBLE_INF_REP));
329
__DECLARE_INSTANCE(_D_rep,
330
                   _LimG<bool>::_D_qNaN, __STL_ARRAY_STATIC_INIT(__STL_DOUBLE_QNAN_REP));
331
__DECLARE_INSTANCE(_D_rep,
332
                   _LimG<bool>::_D_sNaN, __STL_ARRAY_STATIC_INIT(__STL_DOUBLE_SNAN_REP));
333
# ifndef __STL_NO_LONG_DOUBLE
321
# ifndef __STL_NO_LONG_DOUBLE
334
__DECLARE_INSTANCE(_L_rep,
322
__DECLARE_INSTANCE(const _L_rep, _LimG<bool>::_L_inf,
335
                   _LimG<bool>::_L_inf, __STL_ARRAY_STATIC_INIT(__STL_LDOUBLE_INF_REP));
323
  __STL_ARRAY_STATIC_INIT({__STL_LDOUBLE_INF_REP}));
336
__DECLARE_INSTANCE(_D_rep,
324
__DECLARE_INSTANCE(const _L_rep, _LimG<bool>::_L_qNaN,
337
                   _LimG<bool>::_L_qNaN, __STL_ARRAY_STATIC_INIT(__STL_LDOUBLE_QNAN_REP));
325
  __STL_ARRAY_STATIC_INIT({__STL_LDOUBLE_QNAN_REP}));
338
__DECLARE_INSTANCE(_L_rep,
326
__DECLARE_INSTANCE(const _L_rep, _LimG<bool>::_L_sNaN,
339
                   _LimG<bool>::_L_sNaN, __STL_ARRAY_STATIC_INIT(__STL_LDOUBLE_SNAN_REP));
327
  __STL_ARRAY_STATIC_INIT({__STL_LDOUBLE_SNAN_REP}));
340
# endif
328
# endif
329
__DECLARE_INSTANCE(const _D_rep, _LimG<bool>::_D_inf,
330
  __STL_ARRAY_STATIC_INIT({__STL_DOUBLE_INF_REP}));
331
__DECLARE_INSTANCE(const _D_rep, _LimG<bool>::_D_qNaN,
332
  __STL_ARRAY_STATIC_INIT({__STL_DOUBLE_QNAN_REP}));
333
__DECLARE_INSTANCE(const _D_rep, _LimG<bool>::_D_sNaN,
334
  __STL_ARRAY_STATIC_INIT({__STL_DOUBLE_SNAN_REP}));
335
__DECLARE_INSTANCE(const _F_rep, _LimG<bool>::_F_inf,
336
  __STL_ARRAY_STATIC_INIT({__STL_FLOAT_INF_REP}));
337
__DECLARE_INSTANCE(const _F_rep, _LimG<bool>::_F_qNaN,
338
  __STL_ARRAY_STATIC_INIT({__STL_FLOAT_QNAN_REP}));
339
__DECLARE_INSTANCE(const _F_rep, _LimG<bool>::_F_sNaN,
340
  __STL_ARRAY_STATIC_INIT({__STL_FLOAT_SNAN_REP}));
341
341
342
#endif /* STATIC_DATA */   
342
#endif /* STATIC_DATA */   
343
343
(-)misc/build/STLport-4.0/stlport/stl/_stdio_file.h (-1 / +1 lines)
Lines 116-122 Link Here
116
116
117
# define __STL_FILE_I_O_IDENTICAL 1
117
# define __STL_FILE_I_O_IDENTICAL 1
118
118
119
#elif defined (__CYGWIN__) || defined(__FreeBSD__)
119
#elif defined (__CYGWIN__) || defined(__FreeBSD__) || ( defined(__GNUC__) && defined(__APPLE__) )
120
120
121
inline int   _FILE_fd(const FILE& __f) { return __f._file; }
121
inline int   _FILE_fd(const FILE& __f) { return __f._file; }
122
inline char* _FILE_I_begin(const FILE& __f) { return (char*) __f._bf._base; }
122
inline char* _FILE_I_begin(const FILE& __f) { return (char*) __f._bf._base; }
(-)misc/build/STLport-4.0/stlport/stl/c_locale.h (+11 lines)
Lines 280-285 Link Here
280
# define _Locale_PRINT _CTYPE_R
280
# define _Locale_PRINT _CTYPE_R
281
# define _Locale_ALPHA _CTYPE_A
281
# define _Locale_ALPHA _CTYPE_A
282
282
283
# elif defined (__APPLE__)
284
285
# define _Locale_CNTRL _C
286
# define _Locale_UPPER _U
287
# define _Locale_LOWER _L
288
# define _Locale_DIGIT _D
289
# define _Locale_XDIGIT _X
290
# define _Locale_PUNCT _P
291
# define _Locale_SPACE _S
292
# define _Locale_PRINT _R
293
# define _Locale_ALPHA _A
283
294
284
# elif defined(__STL_USE_GLIBC) /* linux, using the gnu compiler */
295
# elif defined(__STL_USE_GLIBC) /* linux, using the gnu compiler */
285
296
(-)misc/build/STLport-4.0/stlport/stl/debug/_debug.c (+3 lines)
Lines 92-99 Link Here
92
  }
92
  }
93
93
94
# if ( __STL_STATIC_TEMPLATE_DATA > 0 )
94
# if ( __STL_STATIC_TEMPLATE_DATA > 0 )
95
96
#  if !defined(__GNUC__) && !defined(__APPLE__)
95
template <class _Dummy>
97
template <class _Dummy>
96
const char* __stl_debug_engine<_Dummy>::_Message_table[_StlMsg_MAX]  __STL_MESSAGE_TABLE_BODY;
98
const char* __stl_debug_engine<_Dummy>::_Message_table[_StlMsg_MAX]  __STL_MESSAGE_TABLE_BODY;
99
#  endif /* !defined(__GNUC__) && !defined(__APPLE__) */
97
100
98
# else
101
# else
99
__DECLARE_INSTANCE(const char*, __stl_debug_engine<bool>::_Message_table[_StlMsg_MAX],
102
__DECLARE_INSTANCE(const char*, __stl_debug_engine<bool>::_Message_table[_StlMsg_MAX],
(-)misc/build/STLport-4.0/stlport/typeinfo (-1 / +1 lines)
Lines 23-29 Link Here
23
23
24
# ifndef __STL_NO_TYPEINFO
24
# ifndef __STL_NO_TYPEINFO
25
25
26
# if defined (__GNUC__) && (__GNUC_MINOR__ > 7)
26
# if defined (__GNUC__) && (__GNUC_MINOR__ > 7) && ! defined (__APPLE__)
27
#  include <../include/typeinfo>
27
#  include <../include/typeinfo>
28
# elif defined (__STL_NO_NEW_NEW_HEADER)
28
# elif defined (__STL_NO_NEW_NEW_HEADER)
29
#  include __STL_NATIVE_HEADER(typeinfo.h)
29
#  include __STL_NATIVE_HEADER(typeinfo.h)
(-)misc/build/STLport-4.0/stlport/typeinfo.h (-1 / +1 lines)
Lines 23-29 Link Here
23
23
24
# ifndef __STL_NO_TYPEINFO
24
# ifndef __STL_NO_TYPEINFO
25
25
26
# if defined (__GNUC__) && (__GNUC_MINOR__ >= 8 )
26
# if defined (__GNUC__) && (__GNUC_MINOR__ >= 8 ) && ! defined (__APPLE__)
27
#  include <../include/typeinfo.h>
27
#  include <../include/typeinfo.h>
28
# else
28
# else
29
#  include __STL_NATIVE_HEADER(typeinfo.h)
29
#  include __STL_NATIVE_HEADER(typeinfo.h)
(-)misc/build/STLport-4.0/stlport/wchar.h (+4 lines)
Lines 27-33 Link Here
27
using __STL_VENDOR_CSTD::strlen;
27
using __STL_VENDOR_CSTD::strlen;
28
using __STL_VENDOR_CSTD::strspn;
28
using __STL_VENDOR_CSTD::strspn;
29
# endif
29
# endif
30
# if defined (__GNUC__) && defined (__APPLE__)
31
# include __STL_NATIVE_C_HEADER(stddef.h)
32
# else
30
# include __STL_NATIVE_C_HEADER(wchar.h)
33
# include __STL_NATIVE_C_HEADER(wchar.h)
34
# endif
31
35
32
# endif /* WINCE */
36
# endif /* WINCE */
33
37
(-)misc/build/STLport-4.0/test/eh/gcc-apple-macosx.mak (+113 lines)
Line 0 Link Here
1
# ;;; -*- Mode:makefile;-*- 
2
# Generated automatically from Makefile.in by configure.
3
# This requires GNU make.
4
5
srcdir = .
6
VPATH = .
7
DYLD_LIBRARY_PATH = ../../lib
8
9
# point this to proper location
10
STL_INCL=-I../../stlport
11
12
AUX_LIST=TestClass.cpp main.cpp nc_alloc.cpp random_number.cpp
13
14
TEST_LIST=test_algo.cpp  \
15
test_algobase.cpp     test_list.cpp test_slist.cpp \
16
test_bit_vector.cpp   test_vector.cpp \
17
test_deque.cpp test_set.cpp test_map.cpp \
18
test_hash_map.cpp  test_hash_set.cpp test_rope.cpp \
19
test_string.cpp test_bitset.cpp test_valarray.cpp \
20
test_static_instances.cpp
21
22
LIST=${AUX_LIST} ${TEST_LIST}
23
24
OBJECTS = $(LIST:%.cpp=obj/%.o) $(STAT_MODULE)
25
D_OBJECTS = $(LIST:%.cpp=d_obj/%.o) $(STAT_MODULE)
26
NOSGI_OBJECTS = $(LIST:%.cpp=nosgi_obj/%.o) $(STAT_MODULE)
27
28
EXECS = $(LIST:%.cpp=%)
29
TESTS = $(LIST:%.cpp=%.out)
30
TEST_EXE  = ./eh_test
31
D_TEST_EXE = ./eh_test_d
32
NOSGI_TEST_EXE = ./eh_test_nosgi
33
34
TEST  = ./eh_test.out
35
D_TEST = ./eh_test_d.out
36
NOSGI_TEST = ./eh_test_nosgi.out
37
38
CC = cc
39
CXX = $(CC)
40
41
# dwa 12/22/99 -- had to turn off -ansi flag so we could use SGI IOSTREAMS
42
CXX_EXTRA_FLAGS = -W -Wno-sign-compare -Wno-unused -Wno-uninitialized -traditional-cpp -fno-coalesce
43
CXXFLAGS = -g -O ${STL_INCL} -I. ${CXX_EXTRA_FLAGS} -DEH_VECTOR_OPERATOR_NEW
44
D_CXXFLAGS = -g -O ${STL_INCL} -I. ${CXX_EXTRA_FLAGS} -DEH_VECTOR_OPERATOR_NEW -D__STL_DEBUG -D__STL_USE_STATIC_LIB
45
NOSGI_CXXFLAGS = -Wall -g -O2 ${STL_INCL} -I. ${CXX_EXTRA_FLAGS} -D__STL_NO_SGI_IOSTREAMS -D__STL_DEBUG_UNINITIALIZED -DEH_VECTOR_OPERATOR_NEW
46
47
check: $(TEST)
48
49
LIBS = -framework System
50
D_LIBSTLPORT = -L../../lib -lstlport_gcc_debug
51
LIBSTLPORT = -L../../lib -lstlport_gcc
52
53
all: $(TEST_EXE) $(D_TEST_EXE) $(NOSGI_TEST_EXE)
54
55
check_nosgi: $(NOSGI_TEST)
56
check_d: $(D_TEST)
57
58
59
$(TEST_EXE) : $(OBJECTS)
60
	$(CXX) $(CXXFLAGS) $(OBJECTS) $(LIBSTLPORT) $(LIBS) -o $(TEST_EXE)
61
	ln -sf ../../lib/libstlport_gcc.dylib
62
63
$(D_TEST_EXE) : $(D_OBJECTS)
64
	$(CXX) $(D_CXXFLAGS) $(D_OBJECTS) $(D_LIBSTLPORT) $(LIBS) -o $(D_TEST_EXE)
65
	ln -sf ../../lib/libstlport_gcc_debug.dylib
66
67
$(NOSGI_TEST_EXE) : $(NOSGI_OBJECTS)
68
	$(CXX) $(NOSGI_CXXFLAGS) $(NOSGI_OBJECTS) $(LIBS) -o $(NOSGI_TEST_EXE)
69
70
71
$(TEST) : $(TEST_EXE)
72
	$(TEST_EXE)
73
74
$(D_TEST) : $(D_TEST_EXE)
75
	$(D_TEST_EXE)
76
77
$(NOSGI_TEST) : $(NOSGI_TEST_EXE)
78
	$(NOSGI_TEST_EXE)
79
80
SUFFIXES: .cpp.o.exe.out.res
81
82
nosgi_obj/%.o : %.cpp
83
	$(CXX) $(NOSGI_CXXFLAGS) $< -c -o $@
84
85
d_obj/%.o : %.cpp
86
	$(CXX) $(D_CXXFLAGS) $< -c -o $@
87
88
obj/%.o : %.cpp
89
	$(CXX) $(CXXFLAGS) $< -c -o $@
90
91
nosgi_obj/%.i : %.cpp
92
	$(CXX) $(NOSGI_CXXFLAGS) $< -E -H > $@
93
94
d_obj/%.i : %.cpp
95
	$(CXX) $(D_CXXFLAGS) $< -E -H > $@
96
97
obj/%.i : %.cpp
98
	$(CXX) $(CXXFLAGS) $< -E -H > $@
99
100
%.out: %.cpp
101
	$(CXX) $(CXXFLAGS) $< -c -USINGLE -DMAIN -g -o $*.o
102
	$(CXX) $(CXXFLAGS) $*.o $(LIBS) -o $*
103
	./$* > $@
104
	-rm -f $*
105
106
%.s: %.cpp
107
	$(CXX) $(CXXFLAGS) -O4 -S -pto $<  -o $@
108
109
%.E: %.cpp
110
	$(CXX) $(CXXFLAGS) -E $<  -o $@
111
112
clean:
113
	-rm -fR ${TEST_EXE} *.o */*.o *.rpo *.obj *.out core *~
(-)misc/build/STLport-4.0/test/eh/test_static_instances.cpp (+57 lines)
Line 0 Link Here
1
/*
2
 * Copyright (c) 1999
3
 * Silicon Graphics Computer Systems, Inc.
4
 *
5
 * Copyright (c) 1999 
6
 * Boris Fomitchev
7
 *
8
 * This material is provided "as is", with absolutely no warranty expressed
9
 * or implied. Any use is at your own risk.
10
 *
11
 * Permission to use or copy this software for any purpose is hereby granted 
12
 * without fee, provided the above notices are retained on all copies.
13
 * Permission to modify the code and to distribute modified code is granted,
14
 * provided the above notices are retained, and a notice that the code was
15
 * modified is included with the above copyright notice.
16
 *
17
 */
18
19
# ifndef __PUT_STATIC_DATA_MEMBERS_HERE
20
# define __PUT_STATIC_DATA_MEMBERS_HERE
21
# endif
22
23
# ifndef __STL_LINK_TIME_INSTANTIATION
24
# define __STL_LINK_TIME_INSTANTIATION
25
# endif
26
27
# include "Prefix.h"
28
29
# if defined (EH_NEW_HEADERS)
30
#include <rope>
31
#else
32
#include <rope.h>
33
#endif 
34
 
35
// typedef rope<TestClass, alloc> TestRope; 
36
typedef __STLPORT_STD::rope<char, eh_allocator(char) > TestRope;
37
38
# define __ROPE_TABLE_BODY  = { \
39
/* 0 */1, /* 1 */2, /* 2 */3, /* 3 */5, /* 4 */8, /* 5 */13, /* 6 */21,         \
40
/* 7 */34, /* 8 */55, /* 9 */89, /* 10 */144, /* 11 */233, /* 12 */377,         \
41
/* 13 */610, /* 14 */987, /* 15 */1597, /* 16 */2584, /* 17 */4181,             \
42
/* 18 */6765ul, /* 19 */10946ul, /* 20 */17711ul, /* 21 */28657ul, /* 22 */46368ul,   \
43
/* 23 */75025ul, /* 24 */121393ul, /* 25 */196418ul, /* 26 */317811ul,                \
44
/* 27 */514229ul, /* 28 */832040ul, /* 29 */1346269ul, /* 30 */2178309ul,             \
45
/* 31 */3524578ul, /* 32 */5702887ul, /* 33 */9227465ul, /* 34 */14930352ul,          \
46
/* 35 */24157817ul, /* 36 */39088169ul, /* 37 */63245986ul, /* 38 */102334155ul,      \
47
/* 39 */165580141ul, /* 40 */267914296ul, /* 41 */433494437ul,                        \
48
/* 42 */701408733ul, /* 43 */1134903170ul, /* 44 */1836311903ul,                      \
49
/* 45 */2971215073ul }
50
51
__DECLARE_INSTANCE(const unsigned long,
52
                   TestRope::_S_min_len[__ROPE_DEPTH_SIZE],
53
                   __ROPE_TABLE_BODY);
54
55
// Local Variables:
56
// mode:C++
57
// End:
(-)misc/build/STLport-4.0/test/regression/gcc-apple-macosx.mak (+169 lines)
Line 0 Link Here
1
# ;;; -*- Mode:makefile;-*- 
2
# Generated automatically from Makefile.in by configure.
3
# This requires GNU make.
4
.SUFFIXES:	.cc .cpp .o .exe .out
5
6
srcdir = .
7
VPATH = .
8
9
STL_INCL=-I../../stlport
10
11
LIST  = stl_test.cpp accum1.cpp accum2.cpp \
12
	adjdiff0.cpp adjdiff1.cpp adjdiff2.cpp \
13
	adjfind0.cpp adjfind1.cpp adjfind2.cpp \
14
	advance.cpp \
15
	alg1.cpp alg2.cpp alg3.cpp alg4.cpp alg5.cpp \
16
	bcompos1.cpp bcompos2.cpp \
17
	bind1st1.cpp bind1st2.cpp \
18
	bind2nd1.cpp bind2nd2.cpp \
19
	binsert1.cpp binsert2.cpp \
20
	binsrch1.cpp binsrch2.cpp \
21
	bnegate1.cpp bnegate2.cpp bvec1.cpp \
22
	copy1.cpp copy2.cpp copy3.cpp copy4.cpp \
23
	copyb.cpp copyb0.cpp \
24
	count0.cpp count1.cpp \
25
	countif1.cpp \
26
	deque1.cpp \
27
	divides.cpp \
28
	eqlrnge0.cpp eqlrnge1.cpp eqlrnge2.cpp \
29
	equal0.cpp equal1.cpp equal2.cpp \
30
	equalto.cpp \
31
	fill1.cpp filln1.cpp \
32
	find0.cpp find1.cpp \
33
	findif0.cpp findif1.cpp \
34
	finsert1.cpp finsert2.cpp \
35
	foreach0.cpp foreach1.cpp \
36
	func1.cpp func2.cpp func3.cpp \
37
	gener1.cpp gener2.cpp \
38
	genern1.cpp genern2.cpp \
39
	greateq.cpp greater.cpp \
40
	incl0.cpp incl1.cpp incl2.cpp \
41
	inplmrg1.cpp inplmrg2.cpp \
42
	inrprod0.cpp inrprod1.cpp inrprod2.cpp \
43
	insert1.cpp insert2.cpp \
44
	iota1.cpp \
45
	istmit1.cpp \
46
	iter1.cpp iter2.cpp iter3.cpp iter4.cpp \
47
	iterswp0.cpp iterswp1.cpp \
48
	less.cpp \
49
	lesseq.cpp \
50
	lexcmp1.cpp lexcmp2.cpp \
51
	list1.cpp list2.cpp list3.cpp list4.cpp \
52
	logicand.cpp logicnot.cpp \
53
	logicor.cpp \
54
	lwrbnd1.cpp lwrbnd2.cpp \
55
	map1.cpp \
56
	max1.cpp max2.cpp \
57
	maxelem1.cpp maxelem2.cpp \
58
	merge0.cpp merge1.cpp merge2.cpp \
59
	min1.cpp min2.cpp \
60
	minelem1.cpp minelem2.cpp \
61
	minus.cpp \
62
	mismtch0.cpp mismtch1.cpp mismtch2.cpp \
63
	mkheap0.cpp mkheap1.cpp \
64
	mmap1.cpp mmap2.cpp \
65
	modulus.cpp \
66
	mset1.cpp mset3.cpp mset4.cpp mset5.cpp \
67
	negate.cpp nequal.cpp \
68
	nextprm0.cpp nextprm1.cpp nextprm2.cpp \
69
	nthelem0.cpp nthelem1.cpp nthelem2.cpp \
70
	ostmit.cpp \
71
	pair0.cpp pair1.cpp pair2.cpp \
72
	parsrt0.cpp parsrt1.cpp parsrt2.cpp \
73
	parsrtc0.cpp parsrtc1.cpp parsrtc2.cpp \
74
	partsrt0.cpp \
75
	partsum0.cpp partsum1.cpp partsum2.cpp \
76
	pheap1.cpp pheap2.cpp \
77
	plus.cpp \
78
	pqueue1.cpp \
79
	prevprm0.cpp prevprm1.cpp prevprm2.cpp \
80
	ptition0.cpp ptition1.cpp \
81
	ptrbinf1.cpp ptrbinf2.cpp \
82
	ptrunf1.cpp ptrunf2.cpp \
83
	queue1.cpp \
84
	rawiter.cpp \
85
	remcopy1.cpp \
86
	remcpif1.cpp \
87
	remif1.cpp \
88
	remove1.cpp \
89
	repcpif1.cpp \
90
	replace0.cpp replace1.cpp replcpy1.cpp replif1.cpp \
91
	revbit1.cpp revbit2.cpp \
92
	revcopy1.cpp reverse1.cpp reviter1.cpp reviter2.cpp \
93
	rndshuf0.cpp rndshuf1.cpp rndshuf2.cpp \
94
	rotate0.cpp rotate1.cpp rotcopy0.cpp rotcopy1.cpp \
95
	search0.cpp search1.cpp search2.cpp \
96
	set1.cpp set2.cpp \
97
	setdiff0.cpp setdiff1.cpp setdiff2.cpp \
98
	setintr0.cpp setintr1.cpp setintr2.cpp \
99
	setsymd0.cpp setsymd1.cpp setsymd2.cpp \
100
	setunon0.cpp setunon1.cpp setunon2.cpp \
101
	sort1.cpp sort2.cpp \
102
	stack1.cpp stack2.cpp \
103
	stblptn0.cpp stblptn1.cpp \
104
	stblsrt1.cpp stblsrt2.cpp \
105
	swap1.cpp \
106
	swprnge1.cpp \
107
	times.cpp \
108
	trnsfrm1.cpp trnsfrm2.cpp \
109
	ucompos1.cpp ucompos2.cpp \
110
	unegate1.cpp unegate2.cpp \
111
	uniqcpy1.cpp uniqcpy2.cpp \
112
	unique1.cpp unique2.cpp \
113
	uprbnd1.cpp uprbnd2.cpp \
114
	vec1.cpp vec2.cpp vec3.cpp vec4.cpp vec5.cpp vec6.cpp vec7.cpp vec8.cpp \
115
    hmmap1.cpp hset2.cpp hmset1.cpp slist1.cpp hmap1.cpp string1.cpp bitset1.cpp
116
117
118
# STAT_MODULE=stat.o
119
OBJECTS = $(LIST:%.cpp=%.o) $(STAT_MODULE)
120
EXECS = $(LIST:%.cpp=%.exe)
121
TESTS = $(LIST:%.cpp=%.out)
122
TEST_EXE  = stl_test.exe
123
TEST  = stl_test.out
124
125
CC = c++
126
CXX = $(CC)
127
128
# DEBUG_FLAGS= -D__STL_DEBUG
129
130
CXXFLAGS = -D__STL_NO_SGI_IOSTREAMS -D__STL_WHOLE_NATIVE_STD -fhonor-std -D__HONOR_STD ${STL_INCL} -I. ${CXX_EXTRA_FLAGS} ${STL_VERSION_FLAGS}
131
132
CXXFLAGS = -W -Wno-sign-compare -Wno-unused -Wno-uninitialized -D__STL_NO_SGI_IOSTREAMS ${STL_INCL} -I. ${CXX_EXTRA_FLAGS} ${STL_VERSION_FLAGS} -traditional-cpp -fno-coalesce
133
134
LIBS = -framework System
135
LIBSTDCXX = 
136
137
check: $(TEST)
138
139
$(TEST) : $(OBJECTS)
140
	$(CXX) $(CXXFLAGS) ${REPO_FLAGS} $(OBJECTS) $(LIBS) -o $(TEST_EXE)
141
	echo 'a string' | ./$(TEST_EXE) > $(TEST)
142
143
144
.cc.o .cxx.o .C.o .cpp.o:
145
	${CXX} ${CXXFLAGS} ${DEBUG_FLAGS} ${REPO_FLAGS} ${.IMPSRC} -c -o $*.o $<
146
147
%.out: %.cpp
148
	$(CXX) $(CXXFLAGS) ${DEBUG_FLAGS} -USINGLE -DMAIN=1 $< -c -o $*.o
149
	$(CXX) $(CXXFLAGS) $*.o $(STAT_MODULE) $(LIBS) -o $*.exe
150
	./$*.exe > $@
151
	-rm -f $*.exe
152
153
istmit1.out: istmit1.cpp
154
	$(CXX) $(CXXFLAGS) ${DEBUG_FLAGS} ${REPO_FLAGS} $< $(STAT_MODULE) $(LIBSTDCXX) -lstdc++ $(LIBS) -o istmit1
155
	echo 'a string' | ./istmit1 > istmit1.out
156
	-rm -f ./istmit1
157
158
$(STAT_MODULE): stat.cpp
159
	$(CXX) $(CXXFLAGS) ${DEBUG_FLAGS} ${REPO_FLAGS} -c $< -o $@
160
161
%.s: %.cpp
162
	$(CXX) $(CXXFLAGS) -O3 -fno-exceptions -D__STL_NO_EXCEPTIONS -S $<  -o $*.s
163
164
%.i: %.cpp
165
	$(CXX) $(CXXFLAGS) ${DEBUG_FLAGS} -E $<  > $@
166
167
clean:
168
	-rm -Rf *.exe *.out *.o *.rpo core *.out
169

Return to issue 13632