* configure.ac

* GSWeb/GSWUtils.m
* GSWeb/GSWApplication+Defaults.m
* GSWeb/GSWHTTPIO.m

Fixed for non-Apple platforms, patch from Sebastian Reitenbach.



git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gsweb/trunk@36230 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
dwetzel 2013-03-01 23:56:56 +00:00
parent d26615691d
commit 2e3ab05400
5 changed files with 46 additions and 64 deletions

View file

@ -1,3 +1,11 @@
2013-03-01 David Wetzel <dave@turbocat.de>
* configure.ac
* GSWeb/GSWUtils.m
* GSWeb/GSWApplication+Defaults.m
* GSWeb/GSWHTTPIO.m
Fixed for non-Apple platforms, patch from Sebastian Reitenbach.
2013-02-26 David Wetzel <dave@turbocat.de>
* added GSWeb/GSWApplication+Defaults.h
* GSWeb/GNUmakefile: use -Werror

View file

@ -275,7 +275,7 @@ GSWeb_InitializeGlobalAppDefaultOptions(void)
LOGOPT_NC(GSWOPTValue_SessionStoreClassName);
LOGOPT_NC(GSWOPT_SessionStoreClassName);
LOGOPT_NC(GSWOPTVALUE_DirectConnectEnabled);
LOGOPT (GSWOPTVALUE_DirectConnectEnabled);
LOGOPT_NC(GSWOPT_DirectConnectEnabled);
LOGOPT (GSWOPTVALUE_FrameworksBaseURL);

View file

@ -26,9 +26,6 @@
#include <Foundation/NSString.h>
#include <Foundation/NSFileHandle.h>
#include <Foundation/NSData.h>
#ifdef GNUSTEP
#include <GNUstepBase/GSFileHandle.h>
#endif
#include <GNUstepBase/NSString+GNUstepBase.h>
#include <Foundation/NSError.h>
#include <Foundation/NSException.h>
@ -374,9 +371,10 @@ void _sendMessage(GSWResponse * message, NSFileHandle* fh, NSString * httpVersio
uint16_t rPort = 0;
NSString * rAddress = nil;
#ifdef GNUSTEP
[(GSFileHandle*) fh setNonBlocking: NO];
#endif
// checkme.
//#ifdef GNUSTEP
// [(GSFileHandle*) fh setNonBlocking: NO];
//#endif
// get info about who talks to us

View file

@ -989,9 +989,9 @@ void ValidationExceptionRaiseFn0(const char *func,
when other threads invoke description on us. */
if (self == [NSThread currentThread])
{
return (*nsString_stringWithFormatIMP)(nsStringClass,stringWithFormatSEL, @"<%s: %p (%p)>",
GSClassNameFromObject(self),
self, objc_thread_id());
return (*nsString_stringWithFormatIMP)(nsStringClass,stringWithFormatSEL, @"<%s: %p>",
GSClassNameFromObject(self),
self);
}
return [super description];
}
@ -1002,30 +1002,7 @@ void ValidationExceptionRaiseFn0(const char *func,
static NSString *
volatileInternalDescription(NSLock *self)
{
#ifdef GNUSTEP
struct objc_mutex *mutex = 0;
const char *type;
NSUInteger size;
int offset;
if (GSObjCFindVariable(self, "_mutex", &type, &size, &offset))
{
GSObjCGetVariable(self, offset, size, &mutex);
}
if (mutex != 0)
{
return (*nsString_stringWithFormatIMP)(nsStringClass,stringWithFormatSEL, @"(%@ mutex:%p owner:%p depth:%d)",
self, mutex, mutex->owner, mutex->depth);
}
else
{
return (*nsString_stringWithFormatIMP)(nsStringClass,stringWithFormatSEL, @"(%@ mutex:%p)",
self, mutex);
}
#else
return [self description];
#endif
}
//--------------------------------------------------------------------
@ -1039,12 +1016,8 @@ loggedLockBeforeDateFromFunctionInFileInLine(id self,
{
BOOL isLocked = YES;
NSThread *thread;
void *threadID = 0;
thread = [NSThread currentThread];
#ifdef GNUSTEP
threadID = objc_thread_id();
#endif
if (limit == nil)
{
@ -1072,11 +1045,11 @@ loggedLockBeforeDateFromFunctionInFileInLine(id self,
NSString *name;
NSDebugFLLog(@"locking",
@"tried lock FAILED thread %@(%p) "
@"tried lock FAILED thread %@ "
@"date:%@ file:%s function:%s line:%li "
@"lock:%@ "
@"exception:%@ reason:%@ info:%@",
thread, threadID,
thread,
limit, file, function, line,
volatileInternalDescription(self));
@ -1089,12 +1062,12 @@ loggedLockBeforeDateFromFunctionInFileInLine(id self,
}
NSDebugFLLog(@"locking",
@"%@ %@ thread %@(%p) "
@"%@ %@ thread %@ "
@"date:%@ file:%s function:%s line:%li "
@"result:%d lock:%@",
(try ? @"tried lock" : @"lock"),
(isLocked ? @"SUCCEEDED" : @"FAILED"),
thread, threadID,
thread,
limit, file, function, line,
isLocked, volatileInternalDescription(self));
@ -1108,29 +1081,26 @@ loggedUnlockFromFunctionInFileInLine(id self,
const char *function,
long line)
{
NSThread *thread;
void *threadID = 0;
thread = [NSThread currentThread];
#ifdef GNUSTEP
threadID = objc_thread_id();
#endif
NSDebugFLLog(@"locking",
@"unlock thread %@(%p) "
@"file:%s function:%s line:%li "
@"lock:%@",
thread, threadID,
file, function, line,
volatileInternalDescription(self));
[self unlock];
NSDebugFLLog(@"locking",
@"unlock SUCCEEDED thread %@(%p) "
@"file:%s function:%s line:%li "
@"lock:%@",
thread, threadID,
file, function, line,
volatileInternalDescription(self));
NSThread *thread;
thread = [NSThread currentThread];
NSDebugFLLog(@"locking",
@"unlock thread %@ "
@"file:%s function:%s line:%li "
@"lock:%@",
thread,
file, function, line,
volatileInternalDescription(self));
[self unlock];
NSDebugFLLog(@"locking",
@"unlock SUCCEEDED thread %@ "
@"file:%s function:%s line:%li "
@"lock:%@",
thread,
file, function, line,
volatileInternalDescription(self));
}
//====================================================================

View file

@ -133,6 +133,12 @@ AC_ARG_ENABLE(png,
enable_png=yes)
if test $enable_png = yes; then
PNG_CPPFLAGS="`pkg-config --cflags libpng`"
CPPFLAGS="$CPPFLAGS $PNG_CPPFLAGS"
AUX_INCS="$AUX_INCS $PNG_CPPFLAGS"
AC_CHECK_HEADER(png.h, [], [], [])
AC_CHECK_LIB(png, png_sig_cmp)
fi