From 441ffcd257d951622eeb177de420e2c91fc6ec31 Mon Sep 17 00:00:00 2001
From: Richard Frith-Macdonald
Date: Sat, 5 Jan 2002 06:29:03 +0000
Subject: [PATCH] Simplify source directory stuff.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@11994 72102866-910b-0410-8b05-ffd578937521
---
ChangeLog | 6 +++++
Source/GNUmakefile | 16 +++++++-----
Tools/autogsdoc.m | 65 +++++-----------------------------------------
3 files changed, 21 insertions(+), 66 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index 49e2064f2..d2412be58 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2002-01-05 Richard Frith-Macdonald
+
+ * Tools/autogsdoc.m: Simplify by removing SourceDirectory default.
+ * Source/GNUmakefile (Base_AGSDOC_FLAGS): Remove the SourceDirectory
+ option ... now assumed to be the current directory for simplicity.
+
2002-01-04 Richard Frith-Macdonald
* Source/GNUmakefile (Base_AGSDOC_FLAGS): Fix to use
diff --git a/Source/GNUmakefile b/Source/GNUmakefile
index 66f614aa0..86f8052db 100644
--- a/Source/GNUmakefile
+++ b/Source/GNUmakefile
@@ -306,7 +306,6 @@ NSAttributedString.h \
NSAutoreleasePool.h \
NSBitmapCharSet.h \
NSBundle.h \
-NSByteOrder.h \
NSCalendarDate.h \
NSCharacterSet.h \
NSClassDescription.h \
@@ -332,7 +331,6 @@ NSGeometry.h \
NSHashTable.h \
NSHost.h \
NSInvocation.h \
-NSKeyValueCoding.h \
NSLock.h \
NSMapTable.h \
NSMethodSignature.h \
@@ -342,7 +340,6 @@ NSNull.h \
NSNumberFormatter.h \
NSObjCRuntime.h \
NSObject.h \
-NSPathUtilities.h \
NSPort.h \
NSPortCoder.h \
NSPortMessage.h \
@@ -353,7 +350,6 @@ NSProxy.h \
NSRange.h \
NSRunLoop.h \
NSScanner.h \
-NSSerialization.h \
NSSet.h \
NSString.h \
NSTask.h \
@@ -364,11 +360,18 @@ NSURL.h \
NSURLHandle.h \
NSUndoManager.h \
NSUserDefaults.h \
-NSUtilities.h \
NSValue.h \
NSZone.h
-FOUNDATION_HEADERS = Foundation.h $(AUTOGSDOC_HEADERS) objc-load.h
+FOUNDATION_HEADERS = \
+Foundation.h \
+NSByteOrder.h \
+NSKeyValueCoding.h \
+NSPathUtilities.h \
+NSSerialization.h \
+NSUtilities.h \
+$(AUTOGSDOC_HEADERS) \
+objc-load.h
UNICODE_HEADERS = \
@@ -415,7 +418,6 @@ Base_HEADER_FILES_DIR = $(HEADER_DIR)
Base_AGSDOC_FILES = Base.gsdoc $(AUTOGSDOC_HEADERS)
Base_AGSDOC_FLAGS = \
-HeaderDirectory ../Headers/Foundation \
- -SourceDirectory . \
-Declared Foundation \
-Standards YES \
-Up Base
diff --git a/Tools/autogsdoc.m b/Tools/autogsdoc.m
index 878d28fff..0f2aa7120 100644
--- a/Tools/autogsdoc.m
+++ b/Tools/autogsdoc.m
@@ -32,9 +32,6 @@
parse corresponding source files in the same directory (or the
directory specified using the DocumentationDirectory default),
and produce gsdoc files as output.
- If you list one or more source (.m) files after a header file,
- the tool will parse those files to find documentation for the
- things declared in the preceeding header.
Even without any human assistance, this tool will produce skeleton
@@ -256,13 +253,6 @@
is part of GNUstep and possibly complies with the OpenStep standard
or implements MacOS-X compatible methods.
- - SourceDirectory
- May be used to specify the directory to be searched for source
- (anything other than
.h
files ... which are controlled
- by the HeaderDirectory default).
- If this is not specified, sources are looked for relative to the
- current directory or using absolute path names if given.
-
- SystemProjects
This value is used to control the automatic inclusion of system
external projects into the indexing system for generation of
@@ -340,7 +330,6 @@ main(int argc, char **argv, char **env)
NSString *documentationDirectory;
NSString *declared;
NSString *headerDirectory;
- NSString *sourceDirectory;
NSString *project;
NSDictionary *originalIndex;
AGSIndex *projectRefs;
@@ -406,12 +395,6 @@ main(int argc, char **argv, char **env)
headerDirectory = @"";
}
- sourceDirectory = [defs stringForKey: @"SourceDirectory"];
- if (sourceDirectory == nil)
- {
- sourceDirectory = @"";
- }
-
documentationDirectory = [defs stringForKey: @"DocumentationDirectory"];
if (documentationDirectory == nil)
{
@@ -551,16 +534,7 @@ main(int argc, char **argv, char **env)
*/
if ([arg isAbsolutePath] == NO)
{
- if ([[arg pathExtension] isEqual: @"m"] == YES)
- {
- if ([sourceDirectory length] > 0)
- {
- arg = [sourceDirectory stringByAppendingPathComponent:
- [arg lastPathComponent]];
- [a replaceObjectAtIndex: 0 withObject: arg];
- }
- }
- else
+ if ([[arg pathExtension] isEqual: @"h"] == YES)
{
if ([headerDirectory length] > 0)
{
@@ -570,19 +544,6 @@ main(int argc, char **argv, char **env)
}
}
}
- for (i = 1; i < [a count]; i++)
- {
- arg = [a objectAtIndex: i];
- if ([arg isAbsolutePath] == NO)
- {
- if ([sourceDirectory length] > 0)
- {
- arg = [sourceDirectory stringByAppendingPathComponent:
- [arg lastPathComponent]];
- [a replaceObjectAtIndex: i withObject: arg];
- }
- }
- }
gsdocfile = [documentationDirectory
stringByAppendingPathComponent: file];
@@ -749,15 +710,12 @@ main(int argc, char **argv, char **env)
/*
* Our source file is a gsdoc file ... so it may be located
- * in the source (input) directory rather than the documentation
+ * in the current (input) directory rather than the documentation
* (output) directory.
*/
if ([mgr isReadableFileAtPath: gsdocfile] == NO)
{
- gsdocfile = [sourceDirectory
- stringByAppendingPathComponent: file];
- gsdocfile = [gsdocfile stringByAppendingPathExtension:
- @"gsdoc"];
+ gsdocfile = [file stringByAppendingPathExtension: @"gsdoc"];
}
if (ignoreDependencies == NO)
{
@@ -1031,18 +989,7 @@ main(int argc, char **argv, char **env)
if ([mgr isReadableFileAtPath: gsdocfile] == NO
&& [arg hasSuffix: @".gsdoc"] == YES)
{
- NSString *sdir = [arg stringByDeletingLastPathComponent];
-
- if ([sdir length] == 0)
- {
- sdir = sourceDirectory;
- }
- else if ([sdir isAbsolutePath] == NO)
- {
- sdir = [sourceDirectory stringByAppendingPathComponent: sdir];
- }
- gsdocfile = [sdir stringByAppendingPathComponent: file];
- gsdocfile = [gsdocfile stringByAppendingPathExtension: @"gsdoc"];
+ gsdocfile = [file stringByAppendingPathExtension: @"gsdoc"];
}
if (ignoreDependencies == NO)
@@ -1134,12 +1081,12 @@ main(int argc, char **argv, char **env)
}
file = [file lastPathComponent];
- src = [sourceDirectory stringByAppendingPathComponent: file];
+ src = file;
dst = [documentationDirectory stringByAppendingPathComponent: file];
/*
* If we can't find the file in the source directory, assume
- * it is in the ddocumentation directory already, and just needs
+ * it is in the documentation directory already, and just needs
* cross-refs rebuilding.
*/
if ([mgr isReadableFileAtPath: src] == NO)