mirror of
https://github.com/GnoConsortium/gno.git
synced 2024-06-11 09:29:27 +00:00
Initial checkin for GNO, such that it actually compiles and links.
No functional differences. Not tested.
This commit is contained in:
parent
be57edaf08
commit
d34f9db837
24
usr.orca.bin/udl/Makefile
Normal file
24
usr.orca.bin/udl/Makefile
Normal file
|
@ -0,0 +1,24 @@
|
||||||
|
#
|
||||||
|
# This file is intended for use when building udl from within
|
||||||
|
# the GNO base distribution. For building stand-alone on the
|
||||||
|
# IIgs or on another platform, use one of the other makefiles.
|
||||||
|
#
|
||||||
|
# Devin Reade, October 1997.
|
||||||
|
#
|
||||||
|
# $Id: Makefile,v 1.1 1997/12/08 16:07:19 gdr Exp $
|
||||||
|
#
|
||||||
|
|
||||||
|
PROG = udl
|
||||||
|
SRCS = udlgs.c udluse.c common.c globals.c
|
||||||
|
MAIN = udlgs
|
||||||
|
# OPTIMIZE= 0
|
||||||
|
# DEBUG =
|
||||||
|
|
||||||
|
# See the README for these macros.
|
||||||
|
CFLAGS += -DHAS_ATEXIT -DOVERFLOW_CHECK # -D__STACK_CHECK__
|
||||||
|
STACK = 4096
|
||||||
|
BINDIR = /usr/bin
|
||||||
|
|
||||||
|
.INCLUDE: /src/gno/prog.mk
|
||||||
|
|
||||||
|
head.o:: def.h extern.h
|
|
@ -4,7 +4,7 @@ udl - Convert EOL formats freely between MS-DOS (CR/LF), Unix/Amiga (LF),
|
||||||
|
|
||||||
(c) 1993-1996 Soenke Behrens, Devin Reade
|
(c) 1993-1996 Soenke Behrens, Devin Reade
|
||||||
|
|
||||||
Version 1.1.5: $Id: README,v 1.10 1997/08/02 21:09:13 gdr Exp $
|
Version 1.1.5: $Id: README,v 1.11 1997/12/08 16:07:19 gdr Exp $
|
||||||
=============================================================================
|
=============================================================================
|
||||||
|
|
||||||
Udl converts text files between the various end-of-line conventions, i.e.
|
Udl converts text files between the various end-of-line conventions, i.e.
|
||||||
|
@ -67,8 +67,14 @@ breaking the code for other platforms).
|
||||||
Installation
|
Installation
|
||||||
============
|
============
|
||||||
|
|
||||||
Apple IIgs with GNO
|
Apple IIgs with GNO v2.0.6 (Source Distribution)
|
||||||
^^^^^^^^^^^^^^^^^^^
|
^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||||
|
|
||||||
|
Type 'dmake install' to install to a live system.
|
||||||
|
Type 'dmake release' when building a binary release.
|
||||||
|
|
||||||
|
Apple IIgs with GNO v2.0.4
|
||||||
|
^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||||
Type 'dmake install -f Makefile.gs'. By default this copies the binary
|
Type 'dmake install -f Makefile.gs'. By default this copies the binary
|
||||||
into "/usr/local/bin" and the man page into "/usr/local/man/man1". (You
|
into "/usr/local/bin" and the man page into "/usr/local/man/man1". (You
|
||||||
_are_ using version 3.x of 'man', are you not? *blatant plug*) If you
|
_are_ using version 3.x of 'man', are you not? *blatant plug*) If you
|
||||||
|
@ -105,7 +111,8 @@ your operating system as returned by `uname -sr | tr ' ' '_'`.
|
||||||
|
|
||||||
HAS_ATEXIT if your system has atexit()
|
HAS_ATEXIT if your system has atexit()
|
||||||
|
|
||||||
_POSIX_C_SOURCE and _POSIX_SOURCE if your compiler is Posix compliant
|
_POSIX_C_SOURCE and _POSIX_SOURCE if your compiler, libraries,
|
||||||
|
and headers are POSIX-1.1988 compliant
|
||||||
|
|
||||||
READDIR_RETURNS_DOT if your direct readdir() function will return
|
READDIR_RETURNS_DOT if your direct readdir() function will return
|
||||||
entries for "." and "..". SunOS 4.x and 5.x (Solaris) are known to
|
entries for "." and "..". SunOS 4.x and 5.x (Solaris) are known to
|
||||||
|
|
|
@ -4,12 +4,12 @@
|
||||||
*
|
*
|
||||||
* Routines common to both the Unix and Apple IIgs versions.
|
* Routines common to both the Unix and Apple IIgs versions.
|
||||||
*
|
*
|
||||||
* $Id: common.c,v 1.9 1996/02/04 01:34:26 gdr Exp $
|
* $Id: common.c,v 1.10 1997/12/08 16:07:19 gdr Exp $
|
||||||
*
|
*
|
||||||
* Copyright (c) 1993-1995 Soenke Behrens, Devin Reade
|
* Copyright (c) 1993-1995 Soenke Behrens, Devin Reade
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifdef GNO
|
#ifdef __GNO__
|
||||||
#pragma noroot
|
#pragma noroot
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -602,12 +602,12 @@ void cleanup (void) {
|
||||||
|
|
||||||
void usage (void) {
|
void usage (void) {
|
||||||
extern char use1[]; /* from udluse.c */
|
extern char use1[]; /* from udluse.c */
|
||||||
#ifdef GNO
|
#ifdef __GNO__
|
||||||
extern char use2[];
|
extern char use2[];
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
fprintf(stderr,"%s",use1);
|
fprintf(stderr,"%s",use1);
|
||||||
#ifdef GNO
|
#ifdef __GNO__
|
||||||
if(!needsgno())
|
if(!needsgno())
|
||||||
fprintf(stderr,"%s",use2);
|
fprintf(stderr,"%s",use2);
|
||||||
#endif
|
#endif
|
||||||
|
@ -837,7 +837,7 @@ char *Mktemp(const char *base)
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Make sure the file name does not already exist */
|
/* Make sure the file name does not already exist */
|
||||||
#ifdef GNO
|
#ifdef __GNO__
|
||||||
if (needsgno() == TRUE) {
|
if (needsgno() == TRUE) {
|
||||||
#endif
|
#endif
|
||||||
if (stat(st,&tstat) == 0)
|
if (stat(st,&tstat) == 0)
|
||||||
|
@ -845,7 +845,7 @@ char *Mktemp(const char *base)
|
||||||
free (st);
|
free (st);
|
||||||
st = Mktemp (base);
|
st = Mktemp (base);
|
||||||
}
|
}
|
||||||
#ifdef GNO
|
#ifdef __GNO__
|
||||||
} else { /* ORCA/Shell doesn't like stat one little bit */
|
} else { /* ORCA/Shell doesn't like stat one little bit */
|
||||||
FILE *fp;
|
FILE *fp;
|
||||||
if ((fp = fopen(st,"r")) != NULL)
|
if ((fp = fopen(st,"r")) != NULL)
|
||||||
|
|
|
@ -4,12 +4,12 @@
|
||||||
*
|
*
|
||||||
* Contains definitions of global variables declared in common.h
|
* Contains definitions of global variables declared in common.h
|
||||||
*
|
*
|
||||||
* $Id: globals.c,v 1.6 1996/02/04 01:34:28 gdr Exp $
|
* $Id: globals.c,v 1.7 1997/12/08 16:07:19 gdr Exp $
|
||||||
*
|
*
|
||||||
* Copyright (c) 1993-1995 Soenke Behrens, Devin Reade
|
* Copyright (c) 1993-1995 Soenke Behrens, Devin Reade
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifdef GNO
|
#ifdef __GNO__
|
||||||
#pragma noroot
|
#pragma noroot
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
.\" Copyright (c) 1993-1996 Soenke Behrens, Devin Reade
|
.\" Copyright (c) 1993-1997 Soenke Behrens, Devin Reade
|
||||||
.\"
|
.\"
|
||||||
.\" $Id: udl.1,v 1.11 1997/08/02 21:09:13 gdr Exp $
|
.\" $Id: udl.1,v 1.12 1997/12/08 16:07:19 gdr Exp $
|
||||||
.\"
|
.\"
|
||||||
.TH UDL 1 "Commands and Applications" "31 January 1996" "Version 1.1.5"
|
.TH UDL 1 "31 January 1996" GNO "Commands and Applications"
|
||||||
.SH NAME
|
.SH NAME
|
||||||
udl - convert text files between different architectures
|
udl - convert text files between different architectures
|
||||||
.SH SYNOPSIS
|
.SH SYNOPSIS
|
||||||
|
@ -95,6 +95,6 @@ Bug reports should be directed to one of the two addresses below.
|
||||||
Soenke Behrens <sbehrens@contech.demon.co.uk> with contributions by
|
Soenke Behrens <sbehrens@contech.demon.co.uk> with contributions by
|
||||||
Devin Reade <gdr@myrias.ab.ca>.
|
Devin Reade <gdr@myrias.ab.ca>.
|
||||||
.SH VERSION
|
.SH VERSION
|
||||||
This is
|
This manual page documents
|
||||||
.B udl
|
.B udl
|
||||||
version 1.1.5.
|
version 1.1.5.
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
*
|
*
|
||||||
* Apple IIgs specific routines.
|
* Apple IIgs specific routines.
|
||||||
*
|
*
|
||||||
* $Id: udlgs.c,v 1.10 1997/08/02 21:09:13 gdr Exp $
|
* $Id: udlgs.c,v 1.11 1997/12/08 16:07:19 gdr Exp $
|
||||||
*
|
*
|
||||||
* Copyright (c) 1993-1995 Soenke Behrens, Devin Reade
|
* Copyright (c) 1993-1995 Soenke Behrens, Devin Reade
|
||||||
*/
|
*/
|
||||||
|
@ -12,7 +12,17 @@
|
||||||
#include <orca.h>
|
#include <orca.h>
|
||||||
#include <shell.h>
|
#include <shell.h>
|
||||||
#include <gsos.h>
|
#include <gsos.h>
|
||||||
|
#include <stdlib.h>
|
||||||
|
|
||||||
|
#ifdef __GNO__
|
||||||
|
#include <unistd.h>
|
||||||
|
#include <gno/gno.h>
|
||||||
|
#else
|
||||||
#include <getopt.h>
|
#include <getopt.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/* We having a naming inconsistency in <shell.h> */
|
||||||
|
#define Next_WildcardGSPB NextWildcardGSPB
|
||||||
|
|
||||||
#include "common.h"
|
#include "common.h"
|
||||||
|
|
||||||
|
@ -29,9 +39,6 @@ Init_WildcardGSPB InitWild;
|
||||||
|
|
||||||
extern pascal void SystemQuitFlags (unsigned);
|
extern pascal void SystemQuitFlags (unsigned);
|
||||||
extern pascal void SystemQuitPath (GSString255Ptr);
|
extern pascal void SystemQuitPath (GSString255Ptr);
|
||||||
extern int needsgno(void);
|
|
||||||
extern void begin_stack_check(void);
|
|
||||||
extern int end_stack_check(void);
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Prototypes of functions in this file
|
* Prototypes of functions in this file
|
||||||
|
@ -41,6 +48,13 @@ extern int CheckGSOSType (char *name);
|
||||||
extern void SetGSOSType (char *name, int type, int auxtype);
|
extern void SetGSOSType (char *name, int type, int auxtype);
|
||||||
extern int right_shell_version (void);
|
extern int right_shell_version (void);
|
||||||
|
|
||||||
|
#ifdef __STACK_CHECK__
|
||||||
|
static void
|
||||||
|
printStack (void) {
|
||||||
|
fprintf(stderr, "stack usage: %d bytes\n", _endStackCheck());
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
int main(int argc,char *argv[]) {
|
int main(int argc,char *argv[]) {
|
||||||
FILE *infile, *outfile;
|
FILE *infile, *outfile;
|
||||||
int Tunix = FALSE;
|
int Tunix = FALSE;
|
||||||
|
@ -67,8 +81,9 @@ int main(int argc,char *argv[]) {
|
||||||
*currentDirectory = '\0';
|
*currentDirectory = '\0';
|
||||||
recursionDepth=0;
|
recursionDepth=0;
|
||||||
|
|
||||||
#ifdef CHECK_STACK
|
#ifdef __STACK_CHECK__
|
||||||
begin_stack_check();
|
_beginStackCheck();
|
||||||
|
atexit(printStack);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* In case of exit(), free the mem I allocated */
|
/* In case of exit(), free the mem I allocated */
|
||||||
|
@ -314,10 +329,6 @@ int main(int argc,char *argv[]) {
|
||||||
p++;
|
p++;
|
||||||
} /* end while */
|
} /* end while */
|
||||||
|
|
||||||
#ifdef CHECK_STACK
|
|
||||||
fprintf(stderr,"stack usage: %d bytes\n",end_stack_check());
|
|
||||||
#endif
|
|
||||||
|
|
||||||
return (EXIT_SUCCESS);
|
return (EXIT_SUCCESS);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4,12 +4,12 @@
|
||||||
*
|
*
|
||||||
* Usage strings.
|
* Usage strings.
|
||||||
*
|
*
|
||||||
* $Id: udluse.c,v 1.10 1997/08/02 21:09:13 gdr Exp $
|
* $Id: udluse.c,v 1.11 1997/12/08 16:07:19 gdr Exp $
|
||||||
*
|
*
|
||||||
* Copyright (c) 1993-1995 Soenke Behrens, Devin Reade
|
* Copyright (c) 1993-1995 Soenke Behrens, Devin Reade
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifdef GNO
|
#ifdef __GNO__
|
||||||
#pragma noroot
|
#pragma noroot
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user