diff options
-rw-r--r-- | Makefile | 2 | ||||
-rw-r--r-- | Makefile.nt | 2 | ||||
-rwxr-xr-x | configure | 2 | ||||
-rw-r--r-- | driver/main.ml | 2 | ||||
-rw-r--r-- | driver/optmain.ml | 3 | ||||
-rw-r--r-- | otherlibs/dynlink/Makefile | 2 | ||||
-rw-r--r-- | utils/clflags.ml | 1 | ||||
-rw-r--r-- | utils/clflags.mli | 1 | ||||
-rw-r--r-- | utils/config.mli | 6 | ||||
-rw-r--r-- | utils/config.mlp | 4 |
10 files changed, 5 insertions, 20 deletions
@@ -372,9 +372,7 @@ utils/config.ml: utils/config.mlp config/Makefile -e 's|%%BYTERUN%%|$(BINDIR)/ocamlrun|' \ -e 's|%%CCOMPTYPE%%|cc|' \ -e 's|%%BYTECC%%|$(BYTECC) $(BYTECCCOMPOPTS) $(SHAREDCCCOMPOPTS)|' \ - -e 's|%%BYTELINK%%|$(BYTECC) $(BYTECCLINKOPTS)|' \ -e 's|%%NATIVECC%%|$(NATIVECC) $(NATIVECCCOMPOPTS)|' \ - -e 's|%%NATIVELINK%%|$(NATIVECC) $(NATIVECCLINKOPTS)|' \ -e 's|%%PACKLD%%|$(PACKLD)|' \ -e 's|%%BYTECCLIBS%%|$(BYTECCLIBS)|' \ -e 's|%%NATIVECCLIBS%%|$(NATIVECCLIBS)|' \ diff --git a/Makefile.nt b/Makefile.nt index 4351e14b7..99d4b6cdc 100644 --- a/Makefile.nt +++ b/Makefile.nt @@ -310,9 +310,7 @@ utils/config.ml: utils/config.mlp config/Makefile -e "s|%%BYTERUN%%|ocamlrun|" \ -e 's|%%CCOMPTYPE%%|$(CCOMPTYPE)|' \ -e "s|%%BYTECC%%|$(BYTECC) $(BYTECCCOMPOPTS)|" \ - -e "s|%%BYTELINK%%|flexlink|" \ -e "s|%%NATIVECC%%|$(NATIVECC) $(NATIVECCCOMPOPTS)|" \ - -e "s|%%NATIVELINK%%|flexlink|" \ -e "s|%%PARTIALLD%%|$(PARTIALLD)|" \ -e "s|%%PACKLD%%|$(PACKLD)|" \ -e "s|%%BYTECCLIBS%%|$(BYTECCLIBS)|" \ @@ -544,6 +544,7 @@ if test $withsharedlibs = "yes"; then else mksharedlib="$bytecc -shared" bytecclinkopts="$bytecclinkopts -Wl,-E" + natdynlinkopts="-Wl,-E" byteccrpath="-Wl,-rpath," mksharedlibrpath="-Wl,-rpath," fi @@ -589,6 +590,7 @@ if test $withsharedlibs = "yes"; then sharedcccompopts="-fPIC" mksharedlib="$bytecc -shared" bytecclinkopts="$bytecclinkopts -Wl,-E" + natdynlinkopts="-Wl,-E" byteccrpath="-Wl,-rpath," mksharedlibrpath="-Wl,-rpath," shared_libraries_supported=true;; diff --git a/driver/main.ml b/driver/main.ml index d288a2f64..d7e11a0d6 100644 --- a/driver/main.ml +++ b/driver/main.ml @@ -91,7 +91,7 @@ module Options = Main_args.Make_options (struct let _a = set make_archive let _annot = set annotations let _c = set compile_only - let _cc s = c_compiler := s; c_linker := s + let _cc s = c_compiler := s let _cclib s = ccobjs := Misc.rev_split_words s @ !ccobjs let _ccopt s = ccopts := s :: !ccopts let _config = show_config diff --git a/driver/optmain.ml b/driver/optmain.ml index 5e26d6a16..037a90697 100644 --- a/driver/optmain.ml +++ b/driver/optmain.ml @@ -91,7 +91,6 @@ let show_config () = let main () = native_code := true; c_compiler := Config.native_c_compiler; - c_linker := Config.native_c_linker; let ppf = Format.err_formatter in try Arg.parse (Arch.command_line_options @ [ @@ -99,7 +98,7 @@ let main () = "-annot", Arg.Set annotations, " Save information in <filename>.annot"; "-c", Arg.Set compile_only, " Compile only (do not link)"; - "-cc", Arg.String(fun s -> c_compiler := s; c_linker := s), + "-cc", Arg.String(fun s -> c_compiler := s), "<comp> Use <comp> as the C compiler and linker"; "-cclib", Arg.String(fun s -> ccobjs := Misc.rev_split_words s @ !ccobjs), diff --git a/otherlibs/dynlink/Makefile b/otherlibs/dynlink/Makefile index 60938a21a..97b5bd246 100644 --- a/otherlibs/dynlink/Makefile +++ b/otherlibs/dynlink/Makefile @@ -47,7 +47,7 @@ all: dynlink.cma extract_crc allopt: dynlink.cmxa dynlink.cma: $(OBJS) - $(CAMLC) $(COMPFLAGS) -a -o dynlink.cma $(OBJS) + $(CAMLC) $(COMPFLAGS) -ccopt "$(NATDYNLINKOPTS)" -a -o dynlink.cma $(OBJS) dynlink.cmxa: $(NATOBJS) $(CAMLOPT) $(COMPFLAGS) -ccopt "$(NATDYNLINKOPTS)" -a -o dynlink.cmxa $(NATOBJS) diff --git a/utils/clflags.ml b/utils/clflags.ml index b4ac5f47e..0d9b24b2d 100644 --- a/utils/clflags.ml +++ b/utils/clflags.ml @@ -47,7 +47,6 @@ and recursive_types = ref false (* -rectypes *) and make_runtime = ref false (* -make_runtime *) and gprofile = ref false (* -p *) and c_compiler = ref Config.bytecomp_c_compiler (* -cc *) -and c_linker = ref Config.bytecomp_c_linker (* -cc *) and no_auto_link = ref false (* -noautolink *) and dllpaths = ref ([] : string list) (* -dllpath *) and make_package = ref false (* -pack *) diff --git a/utils/clflags.mli b/utils/clflags.mli index 84a001d4d..8ba36210e 100644 --- a/utils/clflags.mli +++ b/utils/clflags.mli @@ -44,7 +44,6 @@ val recursive_types : bool ref val make_runtime : bool ref val gprofile : bool ref val c_compiler : string ref -val c_linker : string ref val no_auto_link : bool ref val dllpaths : string list ref val make_package : bool ref diff --git a/utils/config.mli b/utils/config.mli index 047b3c52e..ef46b2591 100644 --- a/utils/config.mli +++ b/utils/config.mli @@ -29,17 +29,11 @@ val ccomp_type: string val bytecomp_c_compiler: string (* The C compiler to use for compiling C files with the bytecode compiler *) -val bytecomp_c_linker: string - (* The C compiler to use for building custom runtime systems - with the bytecode compiler *) val bytecomp_c_libraries: string (* The C libraries to link with custom runtimes *) val native_c_compiler: string (* The C compiler to use for compiling C files with the native-code compiler *) -val native_c_linker: string - (* The C compiler to use for the final linking step - in the native code compiler *) val native_c_libraries: string (* The C libraries to link with native-code programs *) val native_pack_linker: string diff --git a/utils/config.mlp b/utils/config.mlp index a33d0808a..a1e03e82b 100644 --- a/utils/config.mlp +++ b/utils/config.mlp @@ -29,10 +29,8 @@ let standard_library = let standard_runtime = "%%BYTERUN%%" let ccomp_type = "%%CCOMPTYPE%%" let bytecomp_c_compiler = "%%BYTECC%%" -let bytecomp_c_linker = "%%BYTELINK%%" let bytecomp_c_libraries = "%%BYTECCLIBS%%" let native_c_compiler = "%%NATIVECC%%" -let native_c_linker = "%%NATIVELINK%%" let native_c_libraries = "%%NATIVECCLIBS%%" let native_pack_linker = "%%PACKLD%%" let ranlib = "%%RANLIBCMD%%" @@ -91,10 +89,8 @@ let print_config oc = p "standard_runtime" standard_runtime; p "ccomp_type" ccomp_type; p "bytecomp_c_compiler" bytecomp_c_compiler; - p "bytecomp_c_linker" bytecomp_c_linker; p "bytecomp_c_libraries" bytecomp_c_libraries; p "native_c_compiler" native_c_compiler; - p "native_c_linker" native_c_linker; p "native_c_libraries" native_c_libraries; p "native_pack_linker" native_pack_linker; p "ranlib" ranlib; |