command line: Support "mescc --print-libgcc-file-name".
* module/mescc.scm (parse-opts): Add "--print-libgcc-file-name".
This commit is contained in:
parent
237dd8a0f0
commit
443f662361
|
@ -66,6 +66,7 @@
|
||||||
(define (single-char #\D) (value #t))
|
(define (single-char #\D) (value #t))
|
||||||
(debug-info (single-char #\g))
|
(debug-info (single-char #\g))
|
||||||
(dumpmachine)
|
(dumpmachine)
|
||||||
|
(print-libgcc-file-name)
|
||||||
(fno-builtin)
|
(fno-builtin)
|
||||||
(fno-stack-protector)
|
(fno-stack-protector)
|
||||||
(help (single-char #\h))
|
(help (single-char #\h))
|
||||||
|
@ -91,8 +92,9 @@
|
||||||
(help? (option-ref options 'help #f))
|
(help? (option-ref options 'help #f))
|
||||||
(files (option-ref options '() '()))
|
(files (option-ref options '() '()))
|
||||||
(dumpmachine? (option-ref options 'dumpmachine #f))
|
(dumpmachine? (option-ref options 'dumpmachine #f))
|
||||||
|
(print-libgcc-file-name? (option-ref options 'print-libgcc-file-name #f))
|
||||||
(version? (option-ref options 'version #f))
|
(version? (option-ref options 'version #f))
|
||||||
(usage? (and (not dumpmachine?) (not help?) (not version?) (null? files))))
|
(usage? (and (not dumpmachine?) (not print-libgcc-file-name?) (not help?) (not version?) (null? files))))
|
||||||
(cond (version? (format #t "mescc (GNU Mes) ~a\n" %version) (exit 0))
|
(cond (version? (format #t "mescc (GNU Mes) ~a\n" %version) (exit 0))
|
||||||
(else
|
(else
|
||||||
(and (or help? usage?)
|
(and (or help? usage?)
|
||||||
|
@ -175,6 +177,7 @@ General help using GNU software: <http://gnu.org/gethelp/>
|
||||||
(options (acons 'numbered-arch? numbered-arch? options))
|
(options (acons 'numbered-arch? numbered-arch? options))
|
||||||
(dumpmachine? (option-ref options 'dumpmachine #f))
|
(dumpmachine? (option-ref options 'dumpmachine #f))
|
||||||
(preprocess? (option-ref options 'preprocess #f))
|
(preprocess? (option-ref options 'preprocess #f))
|
||||||
|
(print-libgcc-file-name? (option-ref options 'print-libgcc-file-name #f))
|
||||||
(compile? (option-ref options 'compile #f))
|
(compile? (option-ref options 'compile #f))
|
||||||
(assemble? (option-ref options 'assemble #f))
|
(assemble? (option-ref options 'assemble #f))
|
||||||
(verbose? (count-opt options 'verbose)))
|
(verbose? (count-opt options 'verbose)))
|
||||||
|
@ -183,6 +186,7 @@ General help using GNU software: <http://gnu.org/gethelp/>
|
||||||
(when (> verbose? 1)
|
(when (> verbose? 1)
|
||||||
(format (current-error-port) "options=~s\n" options)))
|
(format (current-error-port) "options=~s\n" options)))
|
||||||
(cond (dumpmachine? (display (mescc:get-host options)))
|
(cond (dumpmachine? (display (mescc:get-host options)))
|
||||||
|
(print-libgcc-file-name? (display "-lmescc\n"))
|
||||||
(preprocess? (mescc:preprocess options))
|
(preprocess? (mescc:preprocess options))
|
||||||
(compile? (mescc:compile options))
|
(compile? (mescc:compile options))
|
||||||
(assemble? (mescc:assemble options))
|
(assemble? (mescc:assemble options))
|
||||||
|
|
Loading…
Reference in a new issue