~ chicken-core (chicken-5) 8553c4c2f0b51c836b9486d8fef96a5656b3cdd4


commit 8553c4c2f0b51c836b9486d8fef96a5656b3cdd4
Author:     Peter Bex <peter@more-magic.net>
AuthorDate: Sat Oct 14 15:19:59 2017 +0200
Commit:     Evan Hanson <evhan@foldling.org>
CommitDate: Mon Oct 16 09:09:28 2017 +1300

    Remove ambiguous -l<libname> option (fixes #1193)
    
    Instead, one should use -L -l<libname>
    
    Signed-off-by: Evan Hanson <evhan@foldling.org>

diff --git a/NEWS b/NEWS
index 3727dba0..d976ad0a 100644
--- a/NEWS
+++ b/NEWS
@@ -23,6 +23,7 @@
 
 - Tools
   - The new "-link" option to csc allows linking with objects from extensions.
+  - The ambiguous "-l<libname>" option for csc has been removed (#1193).
 
 - Core libraries
   - Removed support for memory-mapped files (posix), queues
diff --git a/csc.mdoc b/csc.mdoc
index 16341a12..9383290d 100644
--- a/csc.mdoc
+++ b/csc.mdoc
@@ -265,14 +265,6 @@ Select a C compiler other than the default.
 Select a C++ compiler other than the default.
 .It Fl ld Ar COMPILER
 Select a linker other than the default.
-.It Fl l Ns Ar LIBNAME
-Link with given library
-.Po
-.Sq lib Ns Ar LIBNAME
-on UNIX,
-.Sq Ar LIBNAME Ns .lib
-on Windows
-.Pc .
 .It Fl static-libs
 Link with static CHICKEN libraries and extensions.
 .It Fl F Ns Ar <DIR>
diff --git a/csc.scm b/csc.scm
index 15882f27..f1030c30 100644
--- a/csc.scm
+++ b/csc.scm
@@ -450,9 +450,6 @@ Usage: #{csc} [OPTION ...] [FILENAME ...]
     -cc COMPILER                   select other C compiler than the default
     -cxx COMPILER                  select other C++ compiler than the default
     -ld COMPILER                   select other linker than the default 
-    -lLIBNAME                      link with given library
-                                    (`libLIBNAME' on UNIX,
-                                     `LIBNAME.lib' on Windows)
     -static                        link with static CHICKEN libraries and
                                     extensions (if possible)
     -F<DIR>                        pass \"-F<DIR>\" to C compiler
@@ -766,9 +763,7 @@ EOF
 		       (t-options arg) ]
 		      [(and (> (string-length arg) 1)
 			    (char=? #\- (string-ref arg 0)) )
-		       (cond [(char=? #\l (string-ref arg 1))
-			      (set! link-options (append link-options (list arg))) ]
- 			     [(char=? #\L (string-ref arg 1))
+		       (cond [(char=? #\L (string-ref arg 1))
  			      (set! link-options (append link-options (list arg))) ]
  			     [(char=? #\I (string-ref arg 1))
  			      (set! compile-options (append compile-options (list arg))) ]
Trap