From owner-freebsd-bugs@FreeBSD.ORG Thu Jun 27 00:50:00 2013 Return-Path: Delivered-To: freebsd-bugs@smarthost.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id E6FD1A38 for ; Thu, 27 Jun 2013 00:50:00 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:1900:2254:206c::16:87]) by mx1.freebsd.org (Postfix) with ESMTP id A44A119AF for ; Thu, 27 Jun 2013 00:50:00 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.7/8.14.7) with ESMTP id r5R0o0gk067769 for ; Thu, 27 Jun 2013 00:50:00 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.7/8.14.7/Submit) id r5R0o00J067768; Thu, 27 Jun 2013 00:50:00 GMT (envelope-from gnats) Resent-Date: Thu, 27 Jun 2013 00:50:00 GMT Resent-Message-Id: <201306270050.r5R0o00J067768@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Stefan Grundmann Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 59D40838 for ; Thu, 27 Jun 2013 00:45:14 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from oldred.freebsd.org (oldred.freebsd.org [8.8.178.121]) by mx1.freebsd.org (Postfix) with ESMTP id 4A3821979 for ; Thu, 27 Jun 2013 00:45:14 +0000 (UTC) Received: from oldred.freebsd.org ([127.0.1.6]) by oldred.freebsd.org (8.14.5/8.14.7) with ESMTP id r5R0jDhE073921 for ; Thu, 27 Jun 2013 00:45:13 GMT (envelope-from nobody@oldred.freebsd.org) Received: (from nobody@localhost) by oldred.freebsd.org (8.14.5/8.14.5/Submit) id r5R0jDGH073920; Thu, 27 Jun 2013 00:45:13 GMT (envelope-from nobody) Message-Id: <201306270045.r5R0jDGH073920@oldred.freebsd.org> Date: Thu, 27 Jun 2013 00:45:13 GMT From: Stefan Grundmann To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Subject: misc/180017: Synopsis: erlang-runtime-16.b.01 wx build broken when using clang X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 27 Jun 2013 00:50:01 -0000 >Number: 180017 >Category: misc >Synopsis: Synopsis: erlang-runtime-16.b.01 wx build broken when using clang >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Thu Jun 27 00:50:00 UTC 2013 >Closed-Date: >Last-Modified: >Originator: Stefan Grundmann >Release: svn path=/head/; revision=252207 >Organization: >Environment: FreeBSD seth 10.0-CURRENT FreeBSD 10.0-CURRENT #0: Thu Jun 20 17:07:42 UTC 2013 sg@seth:/usr/obj/usr/src/sys/GENERIC amd64 >Description: erlang-runtime-16.b.01 does not build the wx application when using clang since otp_src_R16B01/lib/wx/configure:5137 states CXXFLAGS="$CXXFLAGS $CFLAGS $CPPFLAGS" which makes '-std=gnu89' (from USE_CSTD in Makefile) end up in the c++ command. clang fails: error: invalid argument '-std=gnu89' not allowed with 'C++/ObjC++' during configure of lib/wx. (Can not link the wx driver, wx will NOT be useable) When this is fixed (by not including CFLAGS into CXXFLAGS) the wx build failes: /usr/bin/ld: amd64-portbld-freebsd10.0/wxe_impl.o: relocation R_X86_64_32S against `a local symbol' can not be used when making a shared object; recompile with -fPIC amd64-portbld-freebsd10.0/wxe_impl.o: could not read symbols: Bad value >How-To-Repeat: build lang/erlang-runtime16 with WX enabled and clang >Fix: --- lib/wx/configure.orig 2013-06-26 23:47:25.000000000 +0000 +++ lib/wx/configure 2013-06-26 23:47:48.000000000 +0000 @@ -5134,7 +5134,7 @@ -CXXFLAGS="$CXXFLAGS $CFLAGS $CPPFLAGS" +CXXFLAGS="$CXXFLAGS -fPIC $CPPFLAGS" CFLAGS="$CFLAGS $CPPFLAGS $C_ONLY_FLAGS" DEBUG_CXXFLAGS="$CXXFLAGS $DEBUG_CFLAGS $CPPFLAGS" >Release-Note: >Audit-Trail: >Unformatted: