From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp-out.cybermesa.com (mx.cybermesa.com [65.19.2.50]) by sourceware.org (Postfix) with ESMTPS id 60A143858D1E for ; Sat, 22 Jul 2023 19:05:37 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 60A143858D1E Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=newmexico.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=newmexico.com Received: from smtpclient.apple (unknown [65.144.169.43]) (Authenticated sender: hagar) by smtp-out.cybermesa.com (Postfix) with ESMTPSA id 25D7740190; Sat, 22 Jul 2023 13:05:34 -0600 (MDT) Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3696.120.41.1.3\)) Subject: Re: What .dylib files does gfortran v 11.2.0 need on a Mac? From: Leigh House In-Reply-To: <6702C866-B84E-49C5-B52D-2B13E6B61353@sandoe.co.uk> Date: Sat, 22 Jul 2023 13:05:23 -0600 Cc: GCC Fortran Content-Transfer-Encoding: quoted-printable Message-Id: References: <6702C866-B84E-49C5-B52D-2B13E6B61353@sandoe.co.uk> To: Iain Sandoe X-Mailer: Apple Mail (2.3696.120.41.1.3) X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,KAM_DMARC_STATUS,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS,TXREP,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: Iain, Thanks for your fast reply! My Mac is an intel iMac from 2019.=20 I didn=E2=80=99t keep detailed notes about where I got the compiler = package, though I=E2=80=99ve often gone to hpc.sourceforge.net in the = past, under =E2=80=9CComputation Tools=E2=80=9D. I suspect that is where = I got my current compiler from.=20 And I didn=E2=80=99t keep notes about which .dylib file I had to find = and copy into /usr/local/lib, though from a colleague=E2=80=99s = experience it may have been libgfortran.5.dylib. And thanks for your help. Leigh > On Jul 22, 2023, at 12:49 PM, Iain Sandoe wrote: >=20 > Hi Leigh >=20 >> On 22 Jul 2023, at 19:20, Leigh House via Fortran = wrote: >>=20 >> I=E2=80=99ve not been able to get any output written to a file by a = program I compiled with gfortran v11.2.0 on my Mac. The Mac has MacOS = Monterey (v12.6.7). This seems like a simple problem, yet I=E2=80=99ve = not been able to find a solution. And it is an increasing obstacle for = me. The problem includes fortran programs that were compiled years ago. = Suddenly, they can no longer write output to a file. For example, = writing to standard out (lun 6) works fine to the screen, but when = redirected to a file, that file is empty. >=20 > Is your mac Intel or Arm64**? >=20 > You do not say where you got the compiler from (or if you built from = source), it might be relevant to a resolution. >=20 >> A colleague got a clue that the problem may be in an out-of-date, = faulty or corrupted .dylib file. Perhaps = /usr/local/lib/libgfortran.5.dylib? The file = /usr/local/lib/libgfortran.dylib is a symbolic link to = /usr/local/lib/libgfortran.5.dylib. That file has a date of Nov 9, 2021 = on my Mac. Should I have a newer file? If so, how do I get it? I would = have thought it would be included in the gfortran install, but maybe = not? >=20 > Actually, there was an operating system change in the way that = initialization was handled that is backwards-incompatible. We raised a = =E2=80=98feedback=E2=80=99 with Apple, but the response was that this = was intentional - it is possible that you are running into this - I=E2=80=99= d need to check the exact versions at which we fixed it. >=20 >> More generally, can I get a list of the .dylib files that gfortran = (11.2.0) and gcc (also 11.2.0) need for programs they compile to = function properly? And the dates for them? Do these files need to be = owned by user =E2=80=9Croot=E2=80=9D or have other special permissions = (on my Mac, I own them as a regular user). >=20 > No, nothing in GCC requires elevated permissions. >=20 > (of course, if you elect to build it from source and install to some = place that requires admin privs., but that=E2=80=99s only for = installation). >=20 >> This seems like a very obscure, yet debilitating problem that I have = encountered. If I cannot write or modify my fortran codes and have them = work properly, I am SOL.=20 >=20 > gfortran works fine on Monterey - so I am sure that we will be able to = fix this. >=20 > Iain >=20 > ** Arm64 does require building an out-of-tree branch, but that is = being used widely, so also very well-tested. >=20 >=20