From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail3-relais-sop.national.inria.fr (mail3-relais-sop.national.inria.fr [192.134.164.104]) by sympa.inria.fr (Postfix) with ESMTPS id 9D431801D9 for ; Tue, 18 Jul 2017 14:22:18 +0200 (CEST) X-IronPort-AV: E=Sophos;i="5.40,377,1496095200"; d="scan'208";a="231911366" Received: from wencory.loria.fr ([152.81.3.42]) by mail3-relais-sop.national.inria.fr with ESMTP/TLS/AES256-GCM-SHA384; 18 Jul 2017 14:22:18 +0200 Received: from localhost ([127.0.0.1]) by wencory.loria.fr with esmtp (Exim 4.89) (envelope-from ) id 1dXRW5-00050H-O2 for caml-list@inria.fr; Tue, 18 Jul 2017 14:22:17 +0200 To: OCaml mailing list From: =?UTF-8?Q?St=c3=a9phane_Glondu?= Message-ID: <546b87d1-9f90-684a-b048-c8ffb279ff7b@glondu.net> Date: Tue, 18 Jul 2017 14:22:17 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: fr Content-Transfer-Encoding: 8bit Subject: [Caml-list] Options -c and -o are incompatible when compiling C files Hello, kalzium (in Debian) fails to build with ocaml 4.05.0 because of the following error: > [ 55%] Generating modwrap.o > cd /tmp/kalzium-16.08.3/obj-x86_64-linux-gnu/src && /usr/bin/ocamlopt -I /usr/lib/ocaml/facile -c /tmp/kalzium-16.08.3/src/solver/modwrap.c -o /tmp/kalzium-16.08.3/obj-x86_64-linux-gnu/src/modwrap.o > Options -c and -o are incompatible when compiling C files > src/CMakeFiles/kalzium.dir/build.make:107: recipe for target 'src/modwrap.o' failed > make[4]: *** [src/modwrap.o] Error 2 > make[4]: Leaving directory '/tmp/kalzium-16.08.3/obj-x86_64-linux-gnu' > CMakeFiles/Makefile2:305: recipe for target 'src/CMakeFiles/kalzium.dir/all' failed > make[3]: *** [src/CMakeFiles/kalzium.dir/all] Error 2 I am surprised by this error message: what is the rationale? Investigating this, I bumped into: https://github.com/ocaml/ocaml/pull/761 Fabrice says: "In 4.04.0+beta1, ocamlc -c test.c -o subdir/test.o does not produce subdir/test.o but test.o.". But in ocaml 4.02.3, -c and -o used to work properly together (kalzium was building successfully). This looks like a regression to me. -- Stéphane