Commit 98b7b340 authored by ROOL's avatar ROOL 🤖
Browse files

This commit was manufactured by cvs2git to create tag 'RISC_OSLib-5_75-2'.

Sprout from master 2013-10-24 20:03:55 UTC Robert Sprowson <rsprowson@gitlab.riscosopen.org> 'Some library fixes'
Cherrypick from master 2013-01-15 21:21:19 UTC Robert Sprowson <rsprowson@gitlab.riscosopen.org> 'Add JPEG_ to swis.h':
    SWIOptions,feb
    VersionASM
    VersionNum
    c/armsys
    c/scanf
    c/time
    rlib/c/template
Cherrypick from StrongARM 1996-11-05 19:56:31 UTC Neil Turton <nturton@gitlab.riscosopen.org> 'Import from cleaned 370 CD':
    Mk_mjs,fd7
parent c9b6d7f3
| Copyright 1996 Acorn Computers Ltd
|
| Licensed under the Apache License, Version 2.0 (the "License");
| you may not use this file except in compliance with the License.
| You may obtain a copy of the License at
|
| http://www.apache.org/licenses/LICENSE-2.0
|
| Unless required by applicable law or agreed to in writing, software
| distributed under the License is distributed on an "AS IS" BASIS,
| WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
| See the License for the specific language governing permissions and
| limitations under the License.
|
Dir <Obey$Dir>
wimpslot -min 1000k
echo amu_machine lib.clib
amu_machine lib.clib
......@@ -19,7 +19,6 @@ Echo <32> ; Automatically generated file <Sys$Date> { > s.swioptions }
IfThere Hdr:ADFS Then Echo <32> GET Hdr:ADFS { >> s.swioptions }
IfThere Hdr:ATAPI Then Echo <32> GET Hdr:ATAPI { >> s.swioptions }
IfThere Hdr:BasicTrans Then Echo <32> GET Hdr:BasicTrans { >> s.swioptions }
IfThere Hdr:BlendTable Then Echo <32> GET Hdr:BlendTable { >> s.swioptions }
IfThere Hdr:Buffer Then Echo <32> GET Hdr:Buffer { >> s.swioptions }
IfThere Hdr:ARM3Cache Then Echo <32> GET Hdr:ARM3Cache { >> s.swioptions }
IfThere Hdr:CDROM Then Echo <32> GET Hdr:CDROM { >> s.swioptions }
......@@ -41,12 +40,10 @@ IfThere Hdr:Filter Then Echo <32> GET Hdr:Filter { >> s.swioptions }
IfThere Hdr:Font Then Echo <32> GET Hdr:Font { >> s.swioptions }
IfThere Hdr:FPEmulator Then Echo <32> GET Hdr:FPEmulator { >> s.swioptions }
IfThere Hdr:Free Then Echo <32> GET Hdr:Free { >> s.swioptions }
IfThere Hdr:Freeway Then Echo <32> GET Hdr:Freeway { >> s.swioptions }
IfThere Hdr:FSLock Then Echo <32> GET Hdr:FSLock { >> s.swioptions }
IfThere Hdr:Hourglass Then Echo <32> GET Hdr:Hourglass { >> s.swioptions }
IfThere Hdr:HostFS Then Echo <32> GET Hdr:HostFS { >> s.swioptions }
IfThere Hdr:IIC Then Echo <32> GET Hdr:IIC { >> s.swioptions }
IfThere Hdr:ITable Then Echo <32> GET Hdr:ITable { >> s.swioptions }
IfThere Hdr:Joystick Then Echo <32> GET Hdr:Joystick { >> s.swioptions }
IfThere Hdr:SprExtend Then Echo <32> GET Hdr:SprExtend { >> s.swioptions }
IfThere Hdr:MakePSFont Then Echo <32> GET Hdr:MakePSFont { >> s.swioptions }
......@@ -59,7 +56,6 @@ IfThere Hdr:PDumper Then Echo <32> GET Hdr:PDumper { >> s.swioptions }
IfThere Hdr:Podule Then Echo <32> GET Hdr:Podule { >> s.swioptions }
IfThere Hdr:Portable Then Echo <32> GET Hdr:Portable { >> s.swioptions }
IfThere Hdr:RAMFS Then Echo <32> GET Hdr:RAMFS { >> s.swioptions }
IfThere Hdr:RemotePrin Then Echo <32> GET Hdr:RemotePrin { >> s.swioptions }
IfThere Hdr:ResourceFS Then Echo <32> GET Hdr:ResourceFS { >> s.swioptions }
IfThere Hdr:ScrBlank Then Echo <32> GET Hdr:ScrBlank { >> s.swioptions }
IfThere Hdr:ScrModes Then Echo <32> GET Hdr:ScrModes { >> s.swioptions }
......
......@@ -11,13 +11,13 @@
GBLS Module_HelpVersion
GBLS Module_ComponentName
GBLS Module_ComponentPath
Module_MajorVersion SETS "5.78"
Module_Version SETA 578
Module_MajorVersion SETS "5.75"
Module_Version SETA 575
Module_MinorVersion SETS ""
Module_Date SETS "24 Oct 2013"
Module_ApplicationDate SETS "24-Oct-13"
Module_Date SETS "15 Jan 2013"
Module_ApplicationDate SETS "15-Jan-13"
Module_ComponentName SETS "RISC_OSLib"
Module_ComponentPath SETS "castle/RiscOS/Sources/Lib/RISC_OSLib"
Module_FullVersion SETS "5.78"
Module_HelpVersion SETS "5.78 (24 Oct 2013)"
Module_FullVersion SETS "5.75"
Module_HelpVersion SETS "5.75 (15 Jan 2013)"
END
/* (5.78)
/* (5.75)
*
* This file is automatically maintained by srccommit, do not edit manually.
* Last processed by srccommit version: 1.1.
*
*/
#define Module_MajorVersion_CMHG 5.78
#define Module_MajorVersion_CMHG 5.75
#define Module_MinorVersion_CMHG
#define Module_Date_CMHG 24 Oct 2013
#define Module_Date_CMHG 15 Jan 2013
#define Module_MajorVersion "5.78"
#define Module_Version 578
#define Module_MajorVersion "5.75"
#define Module_Version 575
#define Module_MinorVersion ""
#define Module_Date "24 Oct 2013"
#define Module_Date "15 Jan 2013"
#define Module_ApplicationDate "24-Oct-13"
#define Module_ApplicationDate "15-Jan-13"
#define Module_ComponentName "RISC_OSLib"
#define Module_ComponentPath "castle/RiscOS/Sources/Lib/RISC_OSLib"
#define Module_FullVersion "5.78"
#define Module_HelpVersion "5.78 (24 Oct 2013)"
#define Module_LibraryVersionInfo "5:78"
#define Module_FullVersion "5.75"
#define Module_HelpVersion "5.75 (15 Jan 2013)"
#define Module_LibraryVersionInfo "5:75"
......@@ -67,7 +67,7 @@ const char *_clib_version(void)
#undef str
#undef xstr
static int unused[15];
static int unused[3];
/* timing things... */
......@@ -626,9 +626,8 @@ void _terminate_getenv(void)
#define DDEUtils_SetCLSize 0x42581
#define DDEUtils_SetCL 0x42582
#define DDEUtils_FlushCL 0x4258B
static int _cli_limit;
#endif
int system(const char *string)
{
#define CALL 0
......@@ -667,7 +666,7 @@ int system(const char *string)
}
#ifdef DDE
cmd_string = 0;
if (strlen(string) >= _cli_limit) {
if (strlen(string) > 255) {
s = (char *)string;
while (*s == ' ') s++;
cmd = s;
......@@ -719,12 +718,6 @@ void _armsys_lib_init(void)
(void) unused;
_getenv_value = NULL;
_error_recursion = 0;
#ifdef DDE
if ((_kernel_osbyte(129, 0, 255) & 0xFF) >= 0xA8)
_cli_limit = 1024; /* Ursula long command lines */
else
_cli_limit = 256; /* Pre Ursula shorter ones */
#endif
_ctype_init(); /* C locale */
_exit_init(); /* must happen before exit() can be called */
_signal_init(); /* had better be done pretty early */
......
......@@ -635,22 +635,21 @@ static long int rd_string(FILE *p, va_list res, int flag, int field)
return charcount;
}
/* Can "%[blah]" match a zero-length string? No */
/* ISO9899 7.19.6.2 Matches a nonempty sequence of characters */
/* Ambiguity in Oct 86 ANSI draft: can "%[x]" match a zero-length string? */
/* p119 line 19 suggests no, p121 example suggests yes. Treat as yes here */
static long int rd_string_map(FILE *p, va_list res, int flag, int field,
unsigned int charmap[])
int charmap[])
{ long int charcount = -1; /* allow for always ungetc */
int ch; char *s = NULL;
if (!(flag & NOSTORE)) s = va_arg(res, char *);
ch = countgetc(p);
if (ch == EOF) return CVTEOF;
while (field > 0 && ch != EOF && (charmap[ch/32] & (1uL<<(ch%32))) != 0)
while (field > 0 && ch != EOF && (charmap[ch/32] & (1<<(ch%32))) != 0)
{ field--;
if (!(flag & NOSTORE)) *s++ = ch;
ch = countgetc(p);
}
__backspace(p); /* OK if ch == EOF */
if (charcount == 0) return CVTFAIL;
if (!(flag & NOSTORE)) *s = 0;
return charcount;
}
......@@ -784,13 +783,12 @@ case '%': { int field = 0, flag = 0;
case 'x':
case 'X': worked = rd_int(p, argv, flag | ALLOWSIGN, 16, field);
break;
case '[': { int negated = 0, i;
unsigned int charmap[8];
case '[': { int negated = 0, i, charmap[8];
if ((fch = *fmt++) == '^') negated = 1, fch = *fmt++;
for (i=0; i<8; i++) charmap[i] = 0;
/* the 'do' next allows special treatment of %[]})] */
do { if (fch==0) return cnt; /* %[... unterminated */
charmap[fch/32] |= 1u<<(fch%32);
charmap[fch/32] |= 1<<(fch%32);
} while ((fch = *fmt++) != ']');
if (negated) for (i=0; i<8; i++)
charmap[i] = ~charmap[i];
......
......@@ -44,7 +44,7 @@ extern int __locales[5];
/* N.B. clock() and time() are defined in armsys.c */
static const int monlen[13] = { 31,29,31,30,31,30,31,31,30,31,30,31,0x40000000 };
static int monlen[13] = { 31,29,31,30,31,30,31,31,30,31,30,31,0x40000000 };
double difftime(time_t time1, time_t time0)
{ return (double)time1 - (double)time0;
......
......@@ -134,7 +134,7 @@ template *template_copy(template *from)
return to;
}
static BOOL (template_readfile)(char *filename)
BOOL (template_readfile)(char *filename)
{
template *to; /* for insertion into linked list */
int sprites = 0; /* are sprites used? */
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment