mirror of
https://github.com/datajerk/c2d.git
synced 2024-06-13 06:29:30 +00:00
more c2d.c cleanup
This commit is contained in:
parent
368161abc7
commit
e1a469cf72
BIN
bin/c2d.exe
BIN
bin/c2d.exe
Binary file not shown.
19
c2d.c
19
c2d.c
|
@ -28,19 +28,8 @@ Features:
|
||||||
o 32-bit/64-bit x86 OS/X.
|
o 32-bit/64-bit x86 OS/X.
|
||||||
o 32-bit x86 Windows/MinGW.
|
o 32-bit x86 Windows/MinGW.
|
||||||
|
|
||||||
Compile:
|
|
||||||
OS/X:
|
|
||||||
gcc -Wall -O -o c2d c2d.c
|
|
||||||
Linux:
|
|
||||||
gcc -Wall -O -o c2d c2d.c -lm
|
|
||||||
Windows/Cygwin:
|
|
||||||
gcc -Wall -O -o c2d c2d.c
|
|
||||||
Windows/MinGW:
|
|
||||||
PATH=C:\MinGW\bin;%PATH%
|
|
||||||
gcc -Wall -O -static -o c2d c2d.c
|
|
||||||
|
|
||||||
Bugs:
|
Bugs:
|
||||||
* Probably
|
* Yes (input checking)
|
||||||
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@ -75,18 +64,18 @@ int main(int argc, char **argv)
|
||||||
opterr = 1;
|
opterr = 1;
|
||||||
while ((c = getopt(argc, argv, "t:vmh?s:")) != -1)
|
while ((c = getopt(argc, argv, "t:vmh?s:")) != -1)
|
||||||
switch (c) {
|
switch (c) {
|
||||||
case 't':
|
case 't': // load a splash page while loading binary
|
||||||
loader = 1;
|
loader = 1;
|
||||||
textpage = optarg;
|
textpage = optarg;
|
||||||
break;
|
break;
|
||||||
case 'm':
|
case 'm': // boot to monitor
|
||||||
warm = 1;
|
warm = 1;
|
||||||
break;
|
break;
|
||||||
case 'v': // version
|
case 'v': // version
|
||||||
fprintf(stderr, "\n%s\n\n", VERSION);
|
fprintf(stderr, "\n%s\n\n", VERSION);
|
||||||
return 1;
|
return 1;
|
||||||
break;
|
break;
|
||||||
case 's': // override rate for -1/-2 only
|
case 's': // start here instead of load address
|
||||||
warm = 0;
|
warm = 0;
|
||||||
start = (int) strtol(optarg, (char **) NULL, 16); // todo: input check
|
start = (int) strtol(optarg, (char **) NULL, 16); // todo: input check
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in New Issue
Block a user