From: helge Date: Sun, 29 Aug 2004 21:28:41 +0000 (+0000) Subject: added FHS install hack to appserver X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=84bb96f825e5cb57f33c54e01c4452c0e0c8a3f5;p=sope added FHS install hack to appserver git-svn-id: http://svn.opengroupware.org/SOPE/trunk@86 e4a50df8-12e2-0310-a44c-efbce7f8a7e3 --- diff --git a/sope-appserver/NGObjWeb/ChangeLog b/sope-appserver/NGObjWeb/ChangeLog index 8120142e..572184a2 100644 --- a/sope-appserver/NGObjWeb/ChangeLog +++ b/sope-appserver/NGObjWeb/ChangeLog @@ -1,3 +1,32 @@ +2004-08-29 Helge Hess + + * v4.3.18 + + * Templates/WOApplication+Builders.m: also look in + /usr/local/lib/sope-4.3/wox-builders/ and + /usr/lib/sope-4.3/wox-builders/ for SOPE WOx element builder bundles + + * SoObjects/SoProductRegistry.m: also look in + /usr/local/share/sope-4.3/products and /usr/share/sope-4.3/products + for SOPE product bundles + + * WORequest.m, WebDAV/SoObject+SoDAV.m: use new WOCoreApplication + method to lookup Languages.plist / DAVPropMap.plist resource + + * WOCoreApplication.m: use GNUSTEP_PATHPREFIX_LIST and GNUSTEP_PATHLIST + to find libNGObjWeb resources, also look in + /usr/local/share/sope-4.3/ngobjweb/ and + /usr/share/sope-4.3/ngobjweb/. Added a method + +findNGObjWebResource:ofType: to locate library resources + + * WOCoreApplication+Bundle.m: use GNUSTEP_PATHPREFIX_LIST and + GNUSTEP_PATHLIST to load application bundles + + * added hack to install the project in FHS locations - the library, + its headers, the tools and the resources will be installed in + FHS_INSTALL_ROOT if specified (eg make FHS_INSTALL_ROOT=/usr/local), + SOPE products are installed in lib/sope-4.3/products/ + 2004-08-27 Helge Hess * GNUmakefile: export WOComponentDefinition.h as a public header diff --git a/sope-appserver/NGObjWeb/GNUmakefile b/sope-appserver/NGObjWeb/GNUmakefile index 34fa78d9..7d2481ee 100644 --- a/sope-appserver/NGObjWeb/GNUmakefile +++ b/sope-appserver/NGObjWeb/GNUmakefile @@ -150,3 +150,4 @@ include $(GNUSTEP_MAKEFILES)/library.make include $(GNUSTEP_MAKEFILES)/bundle.make include $(GNUSTEP_MAKEFILES)/tool.make -include GNUmakefile.postamble +-include fhs.make diff --git a/sope-appserver/NGObjWeb/GNUmakefile.preamble b/sope-appserver/NGObjWeb/GNUmakefile.preamble index 40b7d646..c9144011 100644 --- a/sope-appserver/NGObjWeb/GNUmakefile.preamble +++ b/sope-appserver/NGObjWeb/GNUmakefile.preamble @@ -31,7 +31,8 @@ ADDITIONAL_LIB_DIRS += \ -L$(RELBUILD_DIR_SxCore)/EOControl/$(GNUSTEP_OBJ_DIR_NAME) \ -L$(RELBUILD_DIR_SxXml)/XmlRpc/$(GNUSTEP_OBJ_DIR_NAME) \ -L$(RELBUILD_DIR_SxXml)/DOM/$(GNUSTEP_OBJ_DIR_NAME) \ - -L$(RELBUILD_DIR_SxXml)/SaxObjC/$(GNUSTEP_OBJ_DIR_NAME) + -L$(RELBUILD_DIR_SxXml)/SaxObjC/$(GNUSTEP_OBJ_DIR_NAME) \ + -L/usr/local/lib -L/usr/lib else libNGObjWeb_LIB_DIRS += \ @@ -42,7 +43,8 @@ libNGObjWeb_LIB_DIRS += \ -L$(CORE_ROOT)/EOControl/$(GNUSTEP_OBJ_DIR) \ -L$(SOPE_ROOT)/sope-xml/XmlRpc/$(GNUSTEP_OBJ_DIR) \ -L$(SOPE_ROOT)/sope-xml/DOM/$(GNUSTEP_OBJ_DIR) \ - -L$(SOPE_ROOT)/sope-xml/SaxObjC/$(GNUSTEP_OBJ_DIR) + -L$(SOPE_ROOT)/sope-xml/SaxObjC/$(GNUSTEP_OBJ_DIR) \ + -L/usr/local/lib -L/usr/lib endif libNGObjWeb_LIBRARIES_DEPEND_UPON += \ diff --git a/sope-appserver/NGObjWeb/NSObject+WO.m b/sope-appserver/NGObjWeb/NSObject+WO.m index 2882cc49..51b548f0 100644 --- a/sope-appserver/NGObjWeb/NSObject+WO.m +++ b/sope-appserver/NGObjWeb/NSObject+WO.m @@ -18,7 +18,6 @@ Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -// $Id$ #include "NSObject+WO.h" #include "common.h" diff --git a/sope-appserver/NGObjWeb/SoObjects/SoProductRegistry.m b/sope-appserver/NGObjWeb/SoObjects/SoProductRegistry.m index a0f3dac9..af2c68ca 100644 --- a/sope-appserver/NGObjWeb/SoObjects/SoProductRegistry.m +++ b/sope-appserver/NGObjWeb/SoObjects/SoProductRegistry.m @@ -267,6 +267,28 @@ static int debugOn = 0; [self scanForProductsInDirectory:lPath]; } + /* look into FHS pathes */ + + pathes = [NSArray arrayWithObjects: + @"/usr/local/lib/sope-4.3/products/", + @"/usr/lib/sope-4.3/products/", + nil]; + for (i = 0; i < [pathes count]; i++) { + NSString *lPath; + BOOL isDir; + + lPath = [pathes objectAtIndex:i]; + if (![fm fileExistsAtPath:lPath isDirectory:&isDir]) + continue; + if (!isDir) + continue; + + [self debugWithFormat:@" directory %@", lPath]; + [self scanForProductsInDirectory:lPath]; + } + + /* report result */ + [self debugWithFormat: @"finished scan for products (%i products registered).", [self->products count]]; diff --git a/sope-appserver/NGObjWeb/Templates/WOApplication+Builders.m b/sope-appserver/NGObjWeb/Templates/WOApplication+Builders.m index 8d84099a..18b66a6e 100644 --- a/sope-appserver/NGObjWeb/Templates/WOApplication+Builders.m +++ b/sope-appserver/NGObjWeb/Templates/WOApplication+Builders.m @@ -117,6 +117,28 @@ [self scanForBuilderBundlesInDirectory:lPath]; } + /* look into FHS pathes */ + + pathes = [NSArray arrayWithObjects: + @"/usr/local/lib/sope-4.3/wox-builders/", + @"/usr/lib/sope-4.3/wox-builders/", + nil]; + for (i = 0; i < [pathes count]; i++) { + NSString *lPath; + BOOL isDir; + + lPath = [pathes objectAtIndex:i]; + if (![fm fileExistsAtPath:lPath isDirectory:&isDir]) + continue; + if (!isDir) + continue; + + [self debugWithFormat:@" directory %@", lPath]; + [self scanForBuilderBundlesInDirectory:lPath]; + } + + /* report result */ + [self debugWithFormat:@"finished scan for builders."]; } diff --git a/sope-appserver/NGObjWeb/Version b/sope-appserver/NGObjWeb/Version index 610acbde..1494d0b4 100644 --- a/sope-appserver/NGObjWeb/Version +++ b/sope-appserver/NGObjWeb/Version @@ -1,6 +1,6 @@ # version file -SUBMINOR_VERSION:=17 +SUBMINOR_VERSION:=18 # v4.2.413 requires libSaxObjC v4.2.33 # v4.2.341 requires libNGExtensions v4.2.77 diff --git a/sope-appserver/NGObjWeb/WOCoreApplication+Bundle.m b/sope-appserver/NGObjWeb/WOCoreApplication+Bundle.m index 898c31a4..c60e11ac 100644 --- a/sope-appserver/NGObjWeb/WOCoreApplication+Bundle.m +++ b/sope-appserver/NGObjWeb/WOCoreApplication+Bundle.m @@ -1,7 +1,7 @@ /* - Copyright (C) 2000-2003 SKYRIX Software AG + Copyright (C) 2000-2004 SKYRIX Software AG - This file is part of OGo + This file is part of OpenGroupware.org. OGo is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the @@ -18,7 +18,6 @@ Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -// $Id$ #include #include "common.h" @@ -32,6 +31,7 @@ + (int)loadApplicationBundle:(NSString *)_bundleName domainPath:(NSString *)_domain { + // TODO: is this actually used somewhere? NSFileManager *fm; NSString *bp; NSBundle *bundle; @@ -50,9 +50,11 @@ } else { NSDictionary *env; + NSEnumerator *e; + id tmp; env = [[NSProcessInfo processInfo] environment]; - + [chkPathes addObject:@"."]; #if COCOA_FRAMEWORK bp = [env objectForKey:@"HOME"]; @@ -66,24 +68,24 @@ bp = [bp stringByAppendingPathComponent:_domain]; [chkPathes addObject:bp]; #else - bp = [env objectForKey:@"GNUSTEP_USER_ROOT"]; - bp = [bp stringByAppendingPathComponent:@"Library"]; - bp = [bp stringByAppendingPathComponent:_domain]; - [chkPathes addObject:bp]; - bp = [env objectForKey:@"GNUSTEP_LOCAL_ROOT"]; - bp = [bp stringByAppendingPathComponent:@"Library"]; - bp = [bp stringByAppendingPathComponent:_domain]; - [chkPathes addObject:bp]; - bp = [env objectForKey:@"GNUSTEP_SYSTEM_ROOT"]; - bp = [bp stringByAppendingPathComponent:@"Library"]; - bp = [bp stringByAppendingPathComponent:_domain]; - [chkPathes addObject:bp]; + if ((tmp = [env objectForKey:@"GNUSTEP_PATHPREFIX_LIST"]) == nil) + tmp = [env objectForKey:@"GNUSTEP_PATHLIST"]; + tmp = [tmp componentsSeparatedByString:@":"]; + e = [tmp objectEnumerator]; + while ((tmp = [e nextObject])) { + bp = [tmp stringByAppendingPathComponent:@"Library"]; + bp = [bp stringByAppendingPathComponent:_domain]; + if ([chkPathes containsObject:bp]) continue; + + [chkPathes addObject:bp]; + } #endif } e = [chkPathes objectEnumerator]; while ((bp = [e nextObject])) { BOOL isDir; + bp = [bp stringByAppendingPathComponent:_bundleName]; if (![fm fileExistsAtPath:bp isDirectory:&isDir]) continue; if (!isDir) continue; @@ -97,7 +99,8 @@ } if ((bundle = [NGBundle bundleWithPath:bp]) == nil) { - NSLog(@"%s: did not find %@ at %@ ...", __PRETTY_FUNCTION__, _bundleName, bp); + NSLog(@"%s: did not find %@ at %@ ...", __PRETTY_FUNCTION__, + _bundleName, bp); //return 1; } diff --git a/sope-appserver/NGObjWeb/WOCoreApplication.m b/sope-appserver/NGObjWeb/WOCoreApplication.m index 218ec0be..789d28e2 100644 --- a/sope-appserver/NGObjWeb/WOCoreApplication.m +++ b/sope-appserver/NGObjWeb/WOCoreApplication.m @@ -685,40 +685,20 @@ static NSMutableArray *activeApps = nil; // THREAD ]; } -@end /* WOCoreApplication */ - -@implementation WOCoreApplication(Defaults) +/* defaults */ -+ (void)_initDefaults { - static BOOL didInit = NO; -#if !COMPILE_AS_FRAMEWORK - NSFileManager *fm; - NSDictionary *env; - NSString *relPath; -#else - NSBundle *bundle; -#endif - NSDictionary *owDefaults = nil; - NSString *apath; - - if (didInit) return; - didInit = YES; ++ (NSArray *)resourcesSearchPathes { + NSMutableArray *ma; + NSDictionary *env; + NSString *relPath, *apath; + NSEnumerator *e; -#if COMPILE_AS_FRAMEWORK - bundle = [NSBundle bundleForClass:[WOCoreApplication class]]; - apath = [bundle pathForResource:@"Defaults" ofType:@"plist"]; - - if (apath == nil) { - NSLog(@"ERROR: cannot find Defaults.plist " - @"resource of NGObjWeb framework (%@) !", bundle); - } -#else - fm = [NSFileManager defaultManager]; - env = [[NSProcessInfo processInfo] environment]; + ma = [NSMutableArray arrayWithCapacity:8]; + env = [[NSProcessInfo processInfo] environment]; /* - TODO: the following is a dirty hack because GNUstep people decided - to change the directory structure. SIGH! + TODO: the following is a dirty hack because GNUstep people decided + to change the directory structure. SIGH! */ #if APPLE_FOUNDATION_LIBRARY || NeXT_Foundation_LIBRARY || GNUSTEP_BASE_LIBRARY relPath = @"Library/Libraries"; @@ -727,28 +707,63 @@ static NSMutableArray *activeApps = nil; // THREAD #endif relPath = [relPath stringByAppendingPathComponent:@"Resources"]; relPath = [relPath stringByAppendingPathComponent:@"NGObjWeb"]; - relPath = [relPath stringByAppendingPathComponent:@"Defaults.plist"]; - apath = [env objectForKey:@"GNUSTEP_USER_ROOT"]; - apath = [apath stringByAppendingPathComponent:relPath]; - if (![fm fileExistsAtPath:apath]) { - apath = [env objectForKey:@"GNUSTEP_LOCAL_ROOT"]; - apath = [apath stringByAppendingPathComponent:relPath]; - } - if (![fm fileExistsAtPath:apath]) { - apath = [env objectForKey:@"GNUSTEP_SYSTEM_ROOT"]; + if ((apath = [env objectForKey:@"GNUSTEP_PATHPREFIX_LIST"]) == nil) + apath = [env objectForKey:@"GNUSTEP_PATHLIST"]; + + e = [[apath componentsSeparatedByString:@":"] objectEnumerator]; + while ((apath = [e nextObject])) { apath = [apath stringByAppendingPathComponent:relPath]; + if ([ma containsObject:apath]) continue; + + [ma addObject:apath]; } - if (![fm fileExistsAtPath:apath]) { - apath = relPath; - } - if (![fm fileExistsAtPath:apath]) { - NSLog(@"ERROR: cannot find Defaults.plist " - @"resource of NGObjWeb library !"); + [ma addObject:relPath]; + [ma addObject:@"/usr/local/share/sope-4.3/ngobjweb/"]; + [ma addObject:@"/usr/share/sope-4.3/ngobjweb/"]; + return ma; +} + ++ (NSString *)findNGObjWebResource:(NSString *)_name ofType:(NSString *)_ext { +#if !COMPILE_AS_FRAMEWORK + NSFileManager *fm; + NSString *filename; +#else + NSBundle *bundle; +#endif + NSEnumerator *e; + NSString *apath; + +#if COMPILE_AS_FRAMEWORK + bundle = [NSBundle bundleForClass:[WOCoreApplication class]]; + return [bundle pathForResource:_name ofType:_ext]; +#else + filename = [_name stringByAppendingPathExtension:_ext]; + fm = [NSFileManager defaultManager]; + e = [[self resourcesSearchPathes] objectEnumerator]; + while ((apath = [e nextObject]) != nil) { + apath = [apath stringByAppendingPathComponent:filename]; + + if ([fm fileExistsAtPath:apath]) + return apath; } + return nil; #endif - owDefaults = [NSDictionary dictionaryWithContentsOfFile:apath]; +} + ++ (void)_initDefaults { + static BOOL didInit = NO; + NSDictionary *owDefaults = nil; + NSString *apath; + if (didInit) return; + didInit = YES; + + apath = [self findNGObjWebResource:@"Defaults" ofType:@"plist"]; + if (apath == nil) + NSLog(@"ERROR: cannot find Defaults.plist resource of NGObjWeb library !"); + + owDefaults = [NSDictionary dictionaryWithContentsOfFile:apath]; if (owDefaults) { [[NSUserDefaults standardUserDefaults] registerDefaults:owDefaults]; #if HEAVY_DEBUG @@ -828,4 +843,4 @@ static NSMutableArray *activeApps = nil; // THREAD return s; } -@end /* WOCoreApplication(Defaults) */ +@end /* WOCoreApplication */ diff --git a/sope-appserver/NGObjWeb/WORequest.m b/sope-appserver/NGObjWeb/WORequest.m index e0abe594..92a1843a 100644 --- a/sope-appserver/NGObjWeb/WORequest.m +++ b/sope-appserver/NGObjWeb/WORequest.m @@ -45,6 +45,10 @@ NGObjWeb_DECLARE NSString *WORequestValueSenderID = @"_i"; NGObjWeb_DECLARE NSString *WORequestValueSessionID = @"wosid"; NGObjWeb_DECLARE NSString *WONoSelectionString = @"WONoSelectionString"; +@interface WOCoreApplication(Resources) ++ (NSString *)findNGObjWebResource:(NSString *)_name ofType:(NSString *)_ext; +@end + @implementation WORequest static BOOL debugOn = NO; @@ -53,56 +57,6 @@ static BOOL debugOn = NO; return [super version] + 2 /* v7 */; } -+ (NSString *)lookupLanguagesPlist { - NSString *apath; -#if !COMPILE_AS_FRAMEWORK - NSFileManager *fm = [NSFileManager defaultManager]; - NSDictionary *env; - NSString *relPath; -#else - NSBundle *bundle; -#endif - -#if COMPILE_AS_FRAMEWORK - bundle = [NSBundle bundleForClass:self]; - apath = [bundle pathForResource:@"Languages" ofType:@"plist"]; -#else - env = [[NSProcessInfo processInfo] environment]; - - /* - TODO: the following is a dirty hack because GNUstep people decided - to change the directory structure. SIGH! - */ -#if APPLE_FOUNDATION_LIBRARY || NeXT_Foundation_LIBRARY || GNUSTEP_BASE_LIBRARY - relPath = @"Library/Libraries"; -#else - relPath = @"Libraries"; -#endif - relPath = [relPath stringByAppendingPathComponent:@"Resources"]; - relPath = [relPath stringByAppendingPathComponent:@"NGObjWeb"]; - relPath = [relPath stringByAppendingPathComponent:@"Languages.plist"]; - - apath = [env objectForKey:@"GNUSTEP_USER_ROOT"]; - apath = [apath stringByAppendingPathComponent:relPath]; - if (![fm fileExistsAtPath:apath]) { - apath = [env objectForKey:@"GNUSTEP_LOCAL_ROOT"]; - apath = [apath stringByAppendingPathComponent:relPath]; - } - if (![fm fileExistsAtPath:apath]) { - apath = [env objectForKey:@"GNUSTEP_SYSTEM_ROOT"]; - apath = [apath stringByAppendingPathComponent:relPath]; - } - if (![fm fileExistsAtPath:apath]) { - apath = relPath; - } - if (![fm fileExistsAtPath:apath]) { - NSLog(@"ERROR: cannot find Languages.plist resource " - @"of NGObjWeb library !"); - } -#endif - return apath; -} - + (void)initialize { static BOOL isInitialized = NO; NSUserDefaults *ud = [NSUserDefaults standardUserDefaults]; @@ -132,10 +86,16 @@ static BOOL debugOn = NO; /* load language mappings */ - apath = [self lookupLanguagesPlist]; - langMap = [NSDictionary dictionaryWithContentsOfFile:apath]; + apath = [WOApplication findNGObjWebResource:@"Languages" ofType:@"plist"]; + if (apath == nil) { + NSLog(@"ERROR: cannot find Languages.plist resource " + @"of NGObjWeb library !"); + langMap = nil; + } + else + langMap = [NSDictionary dictionaryWithContentsOfFile:apath]; - if (langMap) { + if (langMap != nil) { NSDictionary *defs; defs = [NSDictionary dictionaryWithObject:langMap diff --git a/sope-appserver/NGObjWeb/WebDAV/SoObject+SoDAV.m b/sope-appserver/NGObjWeb/WebDAV/SoObject+SoDAV.m index e7ccb07b..751c96bb 100644 --- a/sope-appserver/NGObjWeb/WebDAV/SoObject+SoDAV.m +++ b/sope-appserver/NGObjWeb/WebDAV/SoObject+SoDAV.m @@ -243,56 +243,19 @@ @end /* NSObject(SoObjectSoDAV) */ -@implementation NSObject(SoObjectDAVMaps) +@interface WOCoreApplication(Resources) ++ (NSString *)findNGObjWebResource:(NSString *)_name ofType:(NSString *)_ext; +@end -+ (NSString *)lookupDefMapPlist { - NSString *apath; -#if !COMPILE_AS_FRAMEWORK - NSFileManager *fm = [NSFileManager defaultManager]; - NSDictionary *env; - NSString *relPath; -#endif -#if COMPILE_AS_FRAMEWORK - { - NSBundle *bundle; - - bundle = [NSBundle bundleForClass:self]; - apath = [bundle pathForResource:@"DAVPropMap" ofType:@"plist"]; - } -#else - env = [[NSProcessInfo processInfo] environment]; - relPath = @"Libraries"; - relPath = [relPath stringByAppendingPathComponent:@"Resources"]; - relPath = [relPath stringByAppendingPathComponent:@"NGObjWeb"]; - relPath = [relPath stringByAppendingPathComponent:@"DAVPropMap.plist"]; - - apath = [env objectForKey:@"GNUSTEP_USER_ROOT"]; - apath = [apath stringByAppendingPathComponent:relPath]; - if (![fm fileExistsAtPath:apath]) { - apath = [env objectForKey:@"GNUSTEP_LOCAL_ROOT"]; - apath = [apath stringByAppendingPathComponent:relPath]; - } - if (![fm fileExistsAtPath:apath]) { - apath = [env objectForKey:@"GNUSTEP_SYSTEM_ROOT"]; - apath = [apath stringByAppendingPathComponent:relPath]; - } - if (![fm fileExistsAtPath:apath]) { - apath = relPath; - } - if (![fm fileExistsAtPath:apath]) { - NSLog(@"ERROR: cannot find DAVPropMap.plist resource " - @"of NGObjWeb library !"); - } -#endif - return apath; -} +@implementation NSObject(SoObjectDAVMaps) + (id)defaultWebDAVAttributeMap { static NSDictionary *defMap = nil; if (defMap == nil) { NSString *path; - if ((path = [self lookupDefMapPlist])) + path = [WOApplication findNGObjWebResource:@"DAVPropMap" ofType:@"plist"]; + if (path != nil) defMap = [[NSDictionary alloc] initWithContentsOfFile:path]; } return defMap; diff --git a/sope-appserver/NGObjWeb/fhs.make b/sope-appserver/NGObjWeb/fhs.make new file mode 100644 index 00000000..6e4c5061 --- /dev/null +++ b/sope-appserver/NGObjWeb/fhs.make @@ -0,0 +1,55 @@ +# postprocessing + +# FHS support (this is a hack and is going to be done by gstep-make!) + +ifneq ($(FHS_INSTALL_ROOT),) + +FHS_INCLUDE_DIR=$(FHS_INSTALL_ROOT)/include/ +FHS_LIB_DIR=$(FHS_INSTALL_ROOT)/lib/ +FHS_BIN_DIR=$(FHS_INSTALL_ROOT)/bin/ +FHS_SO_DIR=$(FHS_LIB_DIR)sope-4.3/products/ + +NONFHS_LIBDIR="$(GNUSTEP_LIBRARIES)/$(GNUSTEP_TARGET_LDIR)/" +NONFHS_LIBNAME="$(LIBRARY_NAME)$(LIBRARY_NAME_SUFFIX)$(SHARED_LIBEXT)" +NONFHS_BINDIR="$(GNUSTEP_TOOLS)/$(GNUSTEP_TARGET_LDIR)" + + +fhs-header-dirs :: + $(MKDIRS) $(FHS_INCLUDE_DIR)$(libNGObjWeb_HEADER_FILES_INSTALL_DIR) + +fhs-bin-dirs :: + $(MKDIRS) $(FHS_BIN_DIR) + +fhs-products-dirs :: + $(MKDIRS) $(FHS_SO_DIR) + + +move-headers-to-fhs :: fhs-header-dirs + @echo "moving headers to $(FHS_INCLUDE_DIR) .." + mv $(GNUSTEP_HEADERS)$(libNGObjWeb_HEADER_FILES_INSTALL_DIR)/*.h \ + $(FHS_INCLUDE_DIR)$(libNGObjWeb_HEADER_FILES_INSTALL_DIR)/ + +move-libs-to-fhs :: + @echo "moving libs to $(FHS_LIB_DIR) .." + mv $(NONFHS_LIBDIR)/$(NONFHS_LIBNAME)* $(FHS_LIB_DIR)/ + +move-tools-to-fhs :: fhs-bin-dirs + @echo "moving tools from $(NONFHS_BINDIR) to $(FHS_BIN_DIR) .." + for i in $(TOOL_NAME); do \ + mv "$(NONFHS_BINDIR)/$${i}" $(FHS_BIN_DIR); \ + done + +move-bundles-to-fhs :: fhs-products-dirs + @echo "moving bundles $(BUNDLE_INSTALL_DIR) to $(FHS_SO_DIR) .." + for i in $(BUNDLE_NAME); do \ + j="$(FHS_SO_DIR)/$${i}$(BUNDLE_EXTENSION)"; \ + if test -d $$j; then rm -r $$j; fi; \ + mv "$(BUNDLE_INSTALL_DIR)/$${i}$(BUNDLE_EXTENSION)" $$j; \ + done + +move-to-fhs :: move-headers-to-fhs move-libs-to-fhs move-tools-to-fhs \ + move-bundles-to-fhs + +after-install :: move-to-fhs + +endif diff --git a/sope-appserver/NGXmlRpc/ChangeLog b/sope-appserver/NGXmlRpc/ChangeLog index 51c964c6..da445e98 100644 --- a/sope-appserver/NGXmlRpc/ChangeLog +++ b/sope-appserver/NGXmlRpc/ChangeLog @@ -1,3 +1,10 @@ +2004-08-29 Helge Hess + + * added hack to install the project in FHS locations - the library, + its headers, the tools and the resources will be installed in + FHS_INSTALL_ROOT if specified (eg make FHS_INSTALL_ROOT=/usr/local) + (v4.3.3) + 2004-08-23 Helge Hess * v4.3.2 diff --git a/sope-appserver/NGXmlRpc/GNUmakefile b/sope-appserver/NGXmlRpc/GNUmakefile index abc4d23b..4452fcc5 100644 --- a/sope-appserver/NGXmlRpc/GNUmakefile +++ b/sope-appserver/NGXmlRpc/GNUmakefile @@ -53,3 +53,4 @@ xmlrpc_call_OBJC_FILES = xmlrpc_call.m include $(GNUSTEP_MAKEFILES)/library.make include $(GNUSTEP_MAKEFILES)/tool.make -include GNUmakefile.postamble +-include fhs.make diff --git a/sope-appserver/NGXmlRpc/Version b/sope-appserver/NGXmlRpc/Version index ed045adf..81d0f5a4 100644 --- a/sope-appserver/NGXmlRpc/Version +++ b/sope-appserver/NGXmlRpc/Version @@ -1,3 +1,3 @@ # version file -SUBMINOR_VERSION:=2 +SUBMINOR_VERSION:=3 diff --git a/sope-appserver/NGXmlRpc/fhs.make b/sope-appserver/NGXmlRpc/fhs.make new file mode 100644 index 00000000..33a66cd2 --- /dev/null +++ b/sope-appserver/NGXmlRpc/fhs.make @@ -0,0 +1,42 @@ +# postprocessing + +# FHS support (this is a hack and is going to be done by gstep-make!) + +ifneq ($(FHS_INSTALL_ROOT),) + +FHS_INCLUDE_DIR=$(FHS_INSTALL_ROOT)/include/ +FHS_LIB_DIR=$(FHS_INSTALL_ROOT)/lib/ +FHS_BIN_DIR=$(FHS_INSTALL_ROOT)/bin/ + +NONFHS_LIBDIR="$(GNUSTEP_LIBRARIES)/$(GNUSTEP_TARGET_LDIR)/" +NONFHS_LIBNAME="$(LIBRARY_NAME)$(LIBRARY_NAME_SUFFIX)$(SHARED_LIBEXT)" +NONFHS_BINDIR="$(GNUSTEP_TOOLS)/$(GNUSTEP_TARGET_LDIR)" + + +fhs-header-dirs :: + $(MKDIRS) $(FHS_INCLUDE_DIR)$(libNGXmlRpc_HEADER_FILES_INSTALL_DIR) + +fhs-bin-dirs :: + $(MKDIRS) $(FHS_BIN_DIR) + + +move-headers-to-fhs :: fhs-header-dirs + @echo "moving headers to $(FHS_INCLUDE_DIR) .." + mv $(GNUSTEP_HEADERS)$(libNGXmlRpc_HEADER_FILES_INSTALL_DIR)/*.h \ + $(FHS_INCLUDE_DIR)$(libNGXmlRpc_HEADER_FILES_INSTALL_DIR)/ + +move-libs-to-fhs :: + @echo "moving libs to $(FHS_LIB_DIR) .." + mv $(NONFHS_LIBDIR)/$(NONFHS_LIBNAME)* $(FHS_LIB_DIR)/ + +move-tools-to-fhs :: fhs-bin-dirs + @echo "moving tools from $(NONFHS_BINDIR) to $(FHS_BIN_DIR) .." + for i in $(TOOL_NAME); do \ + mv "$(NONFHS_BINDIR)/$${i}" $(FHS_BIN_DIR); \ + done + +move-to-fhs :: move-headers-to-fhs move-libs-to-fhs move-tools-to-fhs + +after-install :: move-to-fhs + +endif diff --git a/sope-appserver/SoOFS/ChangeLog b/sope-appserver/SoOFS/ChangeLog index cd179a88..939592e9 100644 --- a/sope-appserver/SoOFS/ChangeLog +++ b/sope-appserver/SoOFS/ChangeLog @@ -1,3 +1,10 @@ +2004-08-29 Helge Hess + + * added hack to install the project in FHS locations - the library, + its headers, the tools and the resources will be installed in + FHS_INSTALL_ROOT if specified (eg make FHS_INSTALL_ROOT=/usr/local) + (v4.3.7) + 2004-08-29 Helge Hess * OFSResourceManager.m: fixed include for WOComponentDefinition.h diff --git a/sope-appserver/SoOFS/GNUmakefile b/sope-appserver/SoOFS/GNUmakefile index 3c87520c..a5e6054c 100644 --- a/sope-appserver/SoOFS/GNUmakefile +++ b/sope-appserver/SoOFS/GNUmakefile @@ -69,3 +69,4 @@ include $(GNUSTEP_MAKEFILES)/library.make include $(GNUSTEP_MAKEFILES)/bundle.make include $(GNUSTEP_MAKEFILES)/tool.make -include GNUmakefile.postamble +-include fhs.make diff --git a/sope-appserver/SoOFS/Version b/sope-appserver/SoOFS/Version index f3879a62..e25d7408 100644 --- a/sope-appserver/SoOFS/Version +++ b/sope-appserver/SoOFS/Version @@ -1,3 +1,3 @@ # version file -SUBMINOR_VERSION:=6 +SUBMINOR_VERSION:=7 diff --git a/sope-appserver/SoOFS/fhs.make b/sope-appserver/SoOFS/fhs.make new file mode 100644 index 00000000..1f3b0802 --- /dev/null +++ b/sope-appserver/SoOFS/fhs.make @@ -0,0 +1,55 @@ +# postprocessing + +# FHS support (this is a hack and is going to be done by gstep-make!) + +ifneq ($(FHS_INSTALL_ROOT),) + +FHS_INCLUDE_DIR=$(FHS_INSTALL_ROOT)/include/ +FHS_LIB_DIR=$(FHS_INSTALL_ROOT)/lib/ +FHS_BIN_DIR=$(FHS_INSTALL_ROOT)/bin/ +FHS_SO_DIR=$(FHS_LIB_DIR)sope-4.3/products/ + +NONFHS_LIBDIR="$(GNUSTEP_LIBRARIES)/$(GNUSTEP_TARGET_LDIR)/" +NONFHS_LIBNAME="$(LIBRARY_NAME)$(LIBRARY_NAME_SUFFIX)$(SHARED_LIBEXT)" +NONFHS_BINDIR="$(GNUSTEP_TOOLS)/$(GNUSTEP_TARGET_LDIR)" + + +fhs-header-dirs :: + $(MKDIRS) $(FHS_INCLUDE_DIR)$(libSoOFS_HEADER_FILES_INSTALL_DIR) + +fhs-bin-dirs :: + $(MKDIRS) $(FHS_BIN_DIR) + +fhs-products-dirs :: + $(MKDIRS) $(FHS_SO_DIR) + + +move-headers-to-fhs :: fhs-header-dirs + @echo "moving headers to $(FHS_INCLUDE_DIR) .." + mv $(GNUSTEP_HEADERS)$(libSoOFS_HEADER_FILES_INSTALL_DIR)/*.h \ + $(FHS_INCLUDE_DIR)$(libSoOFS_HEADER_FILES_INSTALL_DIR)/ + +move-libs-to-fhs :: + @echo "moving libs to $(FHS_LIB_DIR) .." + mv $(NONFHS_LIBDIR)/$(NONFHS_LIBNAME)* $(FHS_LIB_DIR)/ + +move-tools-to-fhs :: fhs-bin-dirs + @echo "moving tools from $(NONFHS_BINDIR) to $(FHS_BIN_DIR) .." + for i in $(TOOL_NAME); do \ + mv "$(NONFHS_BINDIR)/$${i}" $(FHS_BIN_DIR); \ + done + +move-bundles-to-fhs :: fhs-products-dirs + @echo "moving bundles $(BUNDLE_INSTALL_DIR) to $(FHS_SO_DIR) .." + for i in $(BUNDLE_NAME); do \ + j="$(FHS_SO_DIR)/$${i}$(BUNDLE_EXTENSION)"; \ + if test -d $$j; then rm -r $$j; fi; \ + mv "$(BUNDLE_INSTALL_DIR)/$${i}$(BUNDLE_EXTENSION)" $$j; \ + done + +move-to-fhs :: move-headers-to-fhs move-libs-to-fhs move-tools-to-fhs \ + move-bundles-to-fhs + +after-install :: move-to-fhs + +endif diff --git a/sope-appserver/WEExtensions/ChangeLog b/sope-appserver/WEExtensions/ChangeLog index 5d0146dc..c4aa97f1 100644 --- a/sope-appserver/WEExtensions/ChangeLog +++ b/sope-appserver/WEExtensions/ChangeLog @@ -1,3 +1,10 @@ +2004-08-29 Helge Hess + + * added hack to install the project in FHS locations - the library, + its headers, the tools and the resources will be installed in + FHS_INSTALL_ROOT if specified (eg make FHS_INSTALL_ROOT=/usr/local) + (v4.3.58) + 2004-08-24 Helge Hess * install bundle in Library/WOxElemBuilders-4.3/ (v4.3.57) diff --git a/sope-appserver/WEExtensions/GNUmakefile b/sope-appserver/WEExtensions/GNUmakefile index d2a0057d..0ca4b0c6 100644 --- a/sope-appserver/WEExtensions/GNUmakefile +++ b/sope-appserver/WEExtensions/GNUmakefile @@ -4,8 +4,9 @@ include $(GNUSTEP_MAKEFILES)/common.make include ../Version include ./Version -LIBRARY_NAME = libWEExtensions -BUNDLE_NAME = WEExtensions +LIBRARY_NAME = libWEExtensions +BUNDLE_NAME = WEExtensions +BUNDLE_EXTENSION = .wox BUNDLE_INSTALL_DIR = $(GNUSTEP_INSTALLATION_DIR)/Library/WOxElemBuilders-4.3/ libWEExtensions_HEADER_FILES_DIR = . @@ -62,3 +63,4 @@ WEExtensions_PRINCIPAL_CLASS = WEExtensionsBundle include $(GNUSTEP_MAKEFILES)/library.make include $(GNUSTEP_MAKEFILES)/bundle.make -include GNUmakefile.postamble +-include fhs.make diff --git a/sope-appserver/WEExtensions/Version b/sope-appserver/WEExtensions/Version index 33ff92fa..296d4b3c 100644 --- a/sope-appserver/WEExtensions/Version +++ b/sope-appserver/WEExtensions/Version @@ -1,3 +1,3 @@ # $Id$ -SUBMINOR_VERSION:=57 +SUBMINOR_VERSION:=58 diff --git a/sope-appserver/WEExtensions/fhs.make b/sope-appserver/WEExtensions/fhs.make new file mode 100644 index 00000000..f87729b8 --- /dev/null +++ b/sope-appserver/WEExtensions/fhs.make @@ -0,0 +1,44 @@ +# postprocessing + +# FHS support (this is a hack and is going to be done by gstep-make!) + +ifneq ($(FHS_INSTALL_ROOT),) + +FHS_INCLUDE_DIR=$(FHS_INSTALL_ROOT)/include/ +FHS_LIB_DIR=$(FHS_INSTALL_ROOT)/lib/ +FHS_BIN_DIR=$(FHS_INSTALL_ROOT)/bin/ +FHS_WOx_DIR=$(FHS_LIB_DIR)sope-4.3/wox-builders/ + +NONFHS_LIBDIR="$(GNUSTEP_LIBRARIES)/$(GNUSTEP_TARGET_LDIR)/" +NONFHS_LIBNAME="$(LIBRARY_NAME)$(LIBRARY_NAME_SUFFIX)$(SHARED_LIBEXT)" + + +fhs-header-dirs :: + $(MKDIRS) $(FHS_INCLUDE_DIR)$(libWEExtensions_HEADER_FILES_INSTALL_DIR) + +fhs-wox-dirs :: + $(MKDIRS) $(FHS_WOx_DIR) + + +move-headers-to-fhs :: fhs-header-dirs + @echo "moving headers to $(FHS_INCLUDE_DIR) .." + mv $(GNUSTEP_HEADERS)$(libWEExtensions_HEADER_FILES_INSTALL_DIR)/*.h \ + $(FHS_INCLUDE_DIR)$(libWEExtensions_HEADER_FILES_INSTALL_DIR)/ + +move-libs-to-fhs :: + @echo "moving libs to $(FHS_LIB_DIR) .." + mv $(NONFHS_LIBDIR)/$(NONFHS_LIBNAME)* $(FHS_LIB_DIR)/ + +move-bundles-to-fhs :: fhs-wox-dirs + @echo "moving bundles $(BUNDLE_INSTALL_DIR) to $(FHS_WOx_DIR) .." + for i in $(BUNDLE_NAME); do \ + j="$(FHS_WOx_DIR)/$${i}$(BUNDLE_EXTENSION)"; \ + if test -d $$j; then rm -r $$j; fi; \ + mv "$(BUNDLE_INSTALL_DIR)/$${i}$(BUNDLE_EXTENSION)" $$j; \ + done + +move-to-fhs :: move-headers-to-fhs move-libs-to-fhs move-bundles-to-fhs + +after-install :: move-to-fhs + +endif diff --git a/sope-appserver/WOExtensions/ChangeLog b/sope-appserver/WOExtensions/ChangeLog index 86fdf2e7..b56a92df 100644 --- a/sope-appserver/WOExtensions/ChangeLog +++ b/sope-appserver/WOExtensions/ChangeLog @@ -1,8 +1,15 @@ +2004-08-29 Helge Hess + + * added hack to install the project in FHS locations - the library, + its headers, the tools and the resources will be installed in + FHS_INSTALL_ROOT if specified (eg make FHS_INSTALL_ROOT=/usr/local) + (v4.3.19) + 2004-08-24 Helge Hess - * install bundle in Library/WOxElemBuilders-4.3/ (v4.3.57) + * install bundle in Library/WOxElemBuilders-4.3/ (v4.3.18) - * v4.3.56 + * v4.3.17 * added a bundle manager class (WOExtensionsBuilderModule) diff --git a/sope-appserver/WOExtensions/GNUmakefile b/sope-appserver/WOExtensions/GNUmakefile index 9f77036a..fc181b0d 100644 --- a/sope-appserver/WOExtensions/GNUmakefile +++ b/sope-appserver/WOExtensions/GNUmakefile @@ -4,8 +4,9 @@ include $(GNUSTEP_MAKEFILES)/common.make include ../Version include ./Version -LIBRARY_NAME = libWOExtensions -BUNDLE_NAME = WOExtensions +LIBRARY_NAME = libWOExtensions +BUNDLE_NAME = WOExtensions +BUNDLE_EXTENSION = .wox BUNDLE_INSTALL_DIR = $(GNUSTEP_INSTALLATION_DIR)/Library/WOxElemBuilders-4.3/ libWOExtensions_HEADER_FILES_DIR = . @@ -41,3 +42,4 @@ WOExtensions_PRINCIPAL_CLASS = WOExtensionsBuilderModule include $(GNUSTEP_MAKEFILES)/library.make include $(GNUSTEP_MAKEFILES)/bundle.make -include GNUmakefile.postamble +-include fhs.make diff --git a/sope-appserver/WOExtensions/Version b/sope-appserver/WOExtensions/Version index 33dfbe1b..93c8cd1d 100644 --- a/sope-appserver/WOExtensions/Version +++ b/sope-appserver/WOExtensions/Version @@ -1,3 +1,3 @@ # $Id$ -SUBMINOR_VERSION:=17 +SUBMINOR_VERSION:=19 diff --git a/sope-appserver/WOExtensions/fhs.make b/sope-appserver/WOExtensions/fhs.make new file mode 100644 index 00000000..08e2932c --- /dev/null +++ b/sope-appserver/WOExtensions/fhs.make @@ -0,0 +1,44 @@ +# postprocessing + +# FHS support (this is a hack and is going to be done by gstep-make!) + +ifneq ($(FHS_INSTALL_ROOT),) + +FHS_INCLUDE_DIR=$(FHS_INSTALL_ROOT)/include/ +FHS_LIB_DIR=$(FHS_INSTALL_ROOT)/lib/ +FHS_BIN_DIR=$(FHS_INSTALL_ROOT)/bin/ +FHS_WOx_DIR=$(FHS_LIB_DIR)sope-4.3/wox-builders/ + +NONFHS_LIBDIR="$(GNUSTEP_LIBRARIES)/$(GNUSTEP_TARGET_LDIR)/" +NONFHS_LIBNAME="$(LIBRARY_NAME)$(LIBRARY_NAME_SUFFIX)$(SHARED_LIBEXT)" + + +fhs-header-dirs :: + $(MKDIRS) $(FHS_INCLUDE_DIR)$(libWOExtensions_HEADER_FILES_INSTALL_DIR) + +fhs-wox-dirs :: + $(MKDIRS) $(FHS_WOx_DIR) + + +move-headers-to-fhs :: fhs-header-dirs + @echo "moving headers to $(FHS_INCLUDE_DIR) .." + mv $(GNUSTEP_HEADERS)$(libWOExtensions_HEADER_FILES_INSTALL_DIR)/*.h \ + $(FHS_INCLUDE_DIR)$(libWOExtensions_HEADER_FILES_INSTALL_DIR)/ + +move-libs-to-fhs :: + @echo "moving libs to $(FHS_LIB_DIR) .." + mv $(NONFHS_LIBDIR)/$(NONFHS_LIBNAME)* $(FHS_LIB_DIR)/ + +move-bundles-to-fhs :: fhs-wox-dirs + @echo "moving bundles $(BUNDLE_INSTALL_DIR) to $(FHS_WOx_DIR) .." + for i in $(BUNDLE_NAME); do \ + j="$(FHS_WOx_DIR)/$${i}$(BUNDLE_EXTENSION)"; \ + if test -d $$j; then rm -r $$j; fi; \ + mv "$(BUNDLE_INSTALL_DIR)/$${i}$(BUNDLE_EXTENSION)" $$j; \ + done + +move-to-fhs :: move-headers-to-fhs move-libs-to-fhs move-bundles-to-fhs + +after-install :: move-to-fhs + +endif