scsh-users
[Top] [All Lists]

Static images broken again in 0.5.0

To: scsh@martigny.ai.mit.edu
Subject: Static images broken again in 0.5.0
From: sperber@informatik.uni-tuebingen.de (Michael Sperber [Mr. Preprocessor])
Date: 23 Apr 1997 10:05:03 +0200
They probably still suck under AIX, but that's for when I have more
time.

*** scsh/static.scm.in.orig     Wed Apr 23 09:59:12 1997
--- scsh/static.scm.in  Wed Apr 23 10:01:05 1997
***************
*** 57,67 ****
        (let ((options (make-options)))
  
        ;; Set the input and output filenames first.
!       (if (< (length argl) 3) (usage (car argl)))
!       (set-options:output-executable options (caddr args))
!       (set-options:input-image options (cadr args))
  
!       (let loop ((args (cdddr argl)))
          (cond ((null? args)
                 (cond ((not (options:output-executable options))
                        (display "error: -o is a required argument") 
--- 57,65 ----
        (let ((options (make-options)))
  
        ;; Set the input and output filenames first.
!       (if (< (length argl) 5) (usage (car argl)))
  
!       (let loop ((args (cdr argl)))
          (cond ((null? args)
                 (cond ((not (options:output-executable options))
                        (display "error: -o is a required argument") 
***************
*** 71,76 ****
--- 69,88 ----
                        (display "error: -i is a required argument") 
                        (newline)
                        (usage (car argl)))))
+               ((equal? (car args) "-i")
+                (cond ((not (null? (cdr args)))
+                       (set-options:input-image options (cadr args))
+                       (loop (cddr args)))
+                      (else 
+                       (display "error: -i requires argument") (newline)
+                       (usage (car argl)))))
+               ((equal? (car args) "-o")
+                (cond ((not (null? (cdr args)))
+                       (set-options:output-executable options (cadr args))
+                       (loop (cddr args)))
+                      (else 
+                       (display "error: -o requires argument") (newline)
+                       (usage (car argl)))))
                ((equal? (car args) "--temp")
                 (cond ((not (null? (cdr args)))
                        (set-options:temp-dir options (cadr args))
***************
*** 130,136 ****
      (define (usage program-name)
        (format #t 
              (string-append
!              "usage: ~a image executable~%" 
               "          [--temp directory]~%"
               "          [--cc command]~%"
               "          [--ld command]~%"
--- 142,150 ----
      (define (usage program-name)
        (format #t 
              (string-append
!              "usage: ~a~%"
!              "          [-i image]~%"
!              "          [-o executable]~%"
               "          [--temp directory]~%"
               "          [--cc command]~%"
               "          [--ld command]~%"
--
Cheers =8-} Mike
Friede, Völkerverständigung und überhaupt blabla
<Prev in Thread] Current Thread [Next in Thread>