Moved over from main

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/branches/freeze_1_8_0@17674 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Adam Fedor 2003-09-16 02:56:04 +00:00
parent d99f7012d8
commit 379c9873cd
9 changed files with 67 additions and 12 deletions

View file

@ -1,3 +1,25 @@
2003-09-15 Adam Fedor <fedor@gnu.org>
* Source/NSBundle.m (+_addFrameworkFromClass:): Check
_loadingBundle != bundle when removing classes.
2003-09-15 S.J.Chun <chunsj@embian.com>
* Source/Unicode.m: Added Korean encoding
* Headers/Foundation/NSString.h: Added Korean encoding
* Source/Additions/GSCompatibility.h: Idem.
Mon Sep 15 13:35:15 2003 Nicola Pero <n.pero@mi.flashnet.it>
* configure.ac: Fixed GNUSTEP_HDIR when not flattened.
* configure: Regenerated.
2003-09-15 Adam Fedor <fedor@gnu.org>
* configure.ac: Check for tzset
* Source/NSTimeZone.m (+systemTimeZone): Use it to find time zone
(as a last resort).
2003-09-13 David Ayers <d.ayers@inode.at>
* Headers/Additions/GNUstepBase/GSCategories.h: Move declarations

View file

@ -158,7 +158,8 @@ typedef enum _NSGNUstepStringEncoding
NSGB2312StringEncoding = 56,
NSUTF7StringEncoding = 64, // RFC 2152
NSGSM0338StringEncoding, // GSM (mobile phone) default alphabet
NSBIG5StringEncoding // Traditional chinese
NSBIG5StringEncoding, // Traditional chinese
NSKoreanEUCEncoding // Korean
} NSGNUstepStringEncoding;

View file

@ -6,7 +6,7 @@
/* Define if SO_REUSEADDR is broken on this system */
#undef BROKEN_SO_REUSEADDR
/* Define if your system terminates the final argument in /proc/28891/cmdline */
/* Define if your system terminates the final argument in /proc/$$/cmdline */
#undef CMDLINE_TERMINATED
/* Define if constructors are automatically loaded */
@ -121,6 +121,9 @@
/* Define to 1 if you have the `mmap' function. */
#undef HAVE_MMAP
/* Define to 1 if you have the `nanosleep' function. */
#undef HAVE_NANOSLEEP
/* Define to 1 if you have the <ndir.h> header file, and it defines `DIR'. */
#undef HAVE_NDIR_H
@ -282,6 +285,9 @@
/* Define to 1 if you have the <time.h> header file. */
#undef HAVE_TIME_H
/* Define to 1 if you have the `tzset' function. */
#undef HAVE_TZSET
/* Define to 1 if you have the <ucbinclude/sys/resource.h> header file. */
#undef HAVE_UCBINCLUDE_SYS_RESOURCE_H
@ -291,9 +297,6 @@
/* Define to 1 if you have the <unistd.h> header file. */
#undef HAVE_UNISTD_H
/* Define to 1 if you have the `nanosleep' function. */
#undef HAVE_NANOSLEEP
/* Define to 1 if you have the `usleep' function. */
#undef HAVE_USLEEP

View file

@ -93,7 +93,8 @@ typedef enum _NSStringEncoding
NSGB2312StringEncoding = 56,
NSUTF7StringEncoding = 64, // RFC 2152
NSGSM0338StringEncoding, // GSM (mobile phone) default alphabet
NSBIG5StringEncoding // Traditional chinese
NSBIG5StringEncoding, // Traditional chinese
NSKoreanEUCEncoding // Korean
} NSStringEncoding;
enum {

View file

@ -179,6 +179,7 @@ static struct _strenc_ str_encoding_table[] = {
{NSGB2312StringEncoding, "NSGB2312StringEncoding","EUC-CN",0,0},
{NSGSM0338StringEncoding, "NSGSM0338StringEncoding","",0,1},
{NSBIG5StringEncoding, "NSBIG5StringEncoding","BIG5",0,0},
{NSKoreanEUCEncoding, "NSKoreanEUCEncoding", "EUC-KR",0,0},
{0,"Unknown encoding","",0,0}
};
@ -424,6 +425,14 @@ GSEncodingForRegistry (NSString *registry, NSString *encoding)
if ([encoding isEqualToString: @"0"])
return NSBIG5StringEncoding;
}
else if ([registry isEqualToString: @"ksc5601.1987"])
{
return NSKoreanEUCEncoding;
}
else if ([registry isEqualToString: @"ksc5601.1997"])
{
return NSKoreanEUCEncoding;
}
else if ([registry isEqualToString:@"utf8"]
|| [registry isEqualToString:@"utf-8"] )
{

View file

@ -471,9 +471,11 @@ _bundle_name_first_match(NSString* directory, NSString* name)
* linked into the bundle (then, the dynamic linker
* automatically drags in the framework when the bundle is
* loaded). But then, the classes in the framework should be
* removed from the list of classes in the bundle.
* removed from the list of classes in the bundle. Check that
* _loadingBundle != bundle which happens on Windows machines when
* loading in Frameworks.
*/
if (_loadingBundle != nil)
if (_loadingBundle != nil && _loadingBundle != bundle)
{
[(NSMutableArray *)[_loadingBundle _bundleClasses]
removeObjectsInArray: [bundle _bundleClasses]];

View file

@ -54,6 +54,7 @@
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>
#include "Foundation/NSArray.h"
#include "Foundation/NSCoder.h"
#include "Foundation/NSData.h"
@ -1123,6 +1124,18 @@ static NSMapTable *absolutes = 0;
localZoneString = [localZoneString stringByTrimmingSpaces];
}
}
#if HAVE_TZSET
if (localZoneString == nil)
{
/*
* Try to get timezone from tzset and tzname
*/
extern char *tzname[2];
tzset();
if (tzname[0] != NULL && *tzname[0] != '\0')
localZoneString = [NSString stringWithCString: tzname[0]];
}
#else
if (localZoneString == nil)
{
/*
@ -1131,6 +1144,7 @@ static NSMapTable *absolutes = 0;
localZoneString = [[[NSProcessInfo processInfo]
environment] objectForKey: @"TZ"];
}
#endif
if (localZoneString != nil)
{
zone = [defaultPlaceholderTimeZone initWithName: localZoneString];

6
configure vendored
View file

@ -2645,14 +2645,15 @@ fi
# Miscellaneous flags
#--------------------------------------------------------------------
# Set location of GNUstep dirs for later use
GNUSTEP_HDIR=$GNUSTEP_SYSTEM_ROOT/Library/Headers
if test "$GNUSTEP_FLATTENED" = yes; then
GNUSTEP_LDIR=$GNUSTEP_SYSTEM_ROOT/Library/Libraries
GNUSTEP_HDIR=$GNUSTEP_SYSTEM_ROOT/Library/Headers
else
clean_target_os=`$GNUSTEP_MAKEFILES/clean_os.sh $target_os`
clean_target_cpu=`$GNUSTEP_MAKEFILES/clean_cpu.sh $target_cpu`
obj_dir=$clean_target_cpu/$clean_target_os
GNUSTEP_LDIR=$GNUSTEP_SYSTEM_ROOT/Library/Libraries/$obj_dir
GNUSTEP_HDIR=$GNUSTEP_SYSTEM_ROOT/Library/Headers/$LIBRARY_COMBO
fi
#
@ -8321,7 +8322,8 @@ done
for ac_func in time ctime
for ac_func in time ctime tzset
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
echo "$as_me:$LINENO: checking for $ac_func" >&5

View file

@ -105,14 +105,15 @@ fi
# Miscellaneous flags
#--------------------------------------------------------------------
# Set location of GNUstep dirs for later use
GNUSTEP_HDIR=$GNUSTEP_SYSTEM_ROOT/Library/Headers
if test "$GNUSTEP_FLATTENED" = yes; then
GNUSTEP_LDIR=$GNUSTEP_SYSTEM_ROOT/Library/Libraries
GNUSTEP_HDIR=$GNUSTEP_SYSTEM_ROOT/Library/Headers
else
clean_target_os=`$GNUSTEP_MAKEFILES/clean_os.sh $target_os`
clean_target_cpu=`$GNUSTEP_MAKEFILES/clean_cpu.sh $target_cpu`
obj_dir=$clean_target_cpu/$clean_target_os
GNUSTEP_LDIR=$GNUSTEP_SYSTEM_ROOT/Library/Libraries/$obj_dir
GNUSTEP_HDIR=$GNUSTEP_SYSTEM_ROOT/Library/Headers/$LIBRARY_COMBO
fi
#
@ -529,7 +530,7 @@ LIBS="$saved_LIBS"
dnl AC_REPLACE_FUNCS(getrusage gettimeofday)
AC_CHECK_HEADERS(time.h sys/time.h sys/rusage.h ucbinclude/sys/resource.h)
AC_CHECK_FUNCS(time ctime)
AC_CHECK_FUNCS(time ctime tzset)
#--------------------------------------------------------------------
# These headers/functions needed by GSTcpPort.m