From nobody Sun Aug 13 00:00:13 2023 X-Original-To: haskell@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4RNd2P65drz4m65v for ; Sun, 13 Aug 2023 00:00:13 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RNd2P37Mdz3CFg for ; Sun, 13 Aug 2023 00:00:13 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1691884813; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=A6aEt2bN3XCeX5w1wsvYICbXkLHJrY2fR4k8Z1duA04=; b=wMnSI0RtoEZxqNipPNtjJY1a6/JRB+iPZb/IwpCOMeOG+O8cv1joZ2geKJYddz+rwbEq7Y LzZ7nrXEynHrr+VT4Eptvy6tDXpV8hBirKoqWoL7PLhGHAZpdLxbIwmg25iYOLJBEKNN5A LsUeAjMmO/VSvueK8EZ8bcJRJbeR4OX5fq50GIhpKkZ6hGWp8JWb9kGis2EW4NlyaIRBs2 SEHFyPl66u/CMddJ84yTCxKvLdP067M4Ivk5x2gy+FnVvDhyTCB81jpzrUqztInG9Jhpls lMV8dYyKaBsTcykYfEdAztYILMb3I4uiJyHFUtDLaGe9Qjz6wVHOomg+O+6+ng== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1691884813; a=rsa-sha256; cv=none; b=jlIl6ZayEed/prF7VjlcjIvghusM1ILgikdGDxWsGRIinZQOjYF6+lBZH17CMQOcnyNTU1 TZfIzK11HgrVnlVvQ8Yi5N90xMc6cke9zza332KD6m8R5mTYDQfQRaQx3MKDPaXxLFJ5mn pU2Ig2MjJZXk4u4EET2RdaMOwugHf4CSO5IIgAPyOh2dL4NlZ9Z2HiCZJi3bbOwfwLbBqf qJlaaDEwUGO26ZuPL7Kpui2cP9bU7H1fLWKBtsinqlMO+3Q27JIGqAsVAXE9qfRBbblnOS R1UY3RvU2GTq4KwHqX813zcfWnXRDh95WNhMESv8ZLtr50ffOMxnWO+C8XnUMA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4RNd2P2F5kzgRV for ; Sun, 13 Aug 2023 00:00:13 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 37D00Dth037097 for ; Sun, 13 Aug 2023 00:00:13 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 37D00DjN037096 for haskell@FreeBSD.org; Sun, 13 Aug 2023 00:00:13 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: haskell@FreeBSD.org Subject: [Bug 273091] lang/ghc 9.4.6 fails to build without the addition of iconv configure flags Date: Sun, 13 Aug 2023 00:00:13 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Ports & Packages X-Bugzilla-Component: Individual Port(s) X-Bugzilla-Version: Latest X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Only Me X-Bugzilla-Who: kreinholz@gmail.com X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: haskell@FreeBSD.org X-Bugzilla-Flags: maintainer-feedback? X-Bugzilla-Changed-Fields: bug_id short_desc product version rep_platform op_sys bug_status bug_severity priority component assigned_to reporter flagtypes.name Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated List-Id: FreeBSD-specific Haskell issues and discussions List-Archive: https://lists.freebsd.org/archives/freebsd-haskell List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-haskell@freebsd.org MIME-Version: 1.0 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D273091 Bug ID: 273091 Summary: lang/ghc 9.4.6 fails to build without the addition of iconv configure flags Product: Ports & Packages Version: Latest Hardware: amd64 OS: Any Status: New Severity: Affects Only Me Priority: --- Component: Individual Port(s) Assignee: haskell@FreeBSD.org Reporter: kreinholz@gmail.com Flags: maintainer-feedback?(haskell@FreeBSD.org) Assignee: haskell@FreeBSD.org OS: FreeBSD 13.2-STABLE stable/13-bc50720b32 GENERIC amd64 What: attempted to build lang/ghc-9.4.6 from Ports with default `make confi= g` options Expected result: successful build of ghc Actual result: build fails at the stage1 bootstrap phase with the following error message: # cabal-configure (for _build/stage1/libraries/base/setup-config) configure: error: iconv is required on non-Windows platforms ExitFailure 1 Build failed. *** Error code 1 Stop. make[1]: stopped in /usr/ports/lang/ghc *** Error code 1 /usr/ports/lang/ghc/work/ghc-9.4.6/_build/stage1/libraries/base/build/confi= g.log reveals: configure:32566: checking for library containing iconv configure:32597: /usr/local/bin/gcc -o conftest -iquote /usr/ports/lang/ghc/work /ghc-9.4.6/libraries/base -fuse-ld=3Dgold conftest.c -lrt >&5 /tmp//cccRZgTs.o:conftest.c:function main: error: undefined reference to 'libico nv_open' /tmp//cccRZgTs.o:conftest.c:function main: error: undefined reference to 'libico nv' /tmp//cccRZgTs.o:conftest.c:function main: error: undefined reference to 'libico nv_close' collect2: error: ld returned 1 exit status configure:32597: $? =3D 1 configure: failed program was: | /* confdefs.h */ And: configure:32597: /usr/local/bin/gcc -o conftest -iquote /usr/ports/lang/ghc/work /ghc-9.4.6/libraries/base -fuse-ld=3Dgold conftest.c -liconv -lrt >&5 /usr/local/bin/ld.gold: error: cannot find -liconv /tmp//ccp8G3Is.o:conftest.c:function main: error: undefined reference to 'libico nv_open' /tmp//ccp8G3Is.o:conftest.c:function main: error: undefined reference to 'libico nv' /tmp//ccp8G3Is.o:conftest.c:function main: error: undefined reference to 'libico nv_close' collect2: error: ld returned 1 exit status On my system, iconv headers and libs are installed to the standard location, /usr/local. However, for some reason ghc's configure script fails to look f= or them there. This may be similar to a problem noted by Mac OS X users attemp= ting to build ghc when two different versions of iconv exist on their systems, installed in different locations. The fix/workaround is easy: edit the Makefile and add appropriate iconv-rel= ated configure flags: GNU_CONFIGURE=3D yes CONFIGURE_ARGS+=3D --docdir=3D${DOCSDIR} --with-iconv-libraries=3D${LOCALBASE}/lib --with-iconv-includes=3D${LOCALBASE}/include CONFIGURE_ENV=3D ALEX=3D/usr/bin/true HAPPY=3D/usr/bin/true INSTALL_TARGET=3D install-strip After this, ghc has no problem finding iconv and the build progresses past = this error. I thought I'd share this information in case anyone else is having difficul= ty building ghc-9.4.6 or to suggest a tweak to the Makefile. --=20 You are receiving this mail because: You are the assignee for the bug.=