From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pg1-x533.google.com (mail-pg1-x533.google.com [IPv6:2607:f8b0:4864:20::533]) by sourceware.org (Postfix) with ESMTPS id A035C38356A7 for ; Wed, 1 Jun 2022 09:31:04 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org A035C38356A7 Received: by mail-pg1-x533.google.com with SMTP id e66so1373501pgc.8 for ; Wed, 01 Jun 2022 02:31:04 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=yG4Qf4w50178+K1+zLzaUWU7wbSTYEdio/IUPREI200=; b=6E460+NekgeAt9fMZWigvkb3Xub0rSWLAyE7vKgVikSj/c/fhBzafsZvTiI+uTr3S5 A7B9/JWsIqnr/dc0wyecQ+hKozYW5CytzyXSR6WDAjskhatsuPlkQcOTMH0TqtvC5CGG REf8GBZnlEgeKeeXMOZWMBT5e9OQVjSfQgBeG+gGrr+ZZkJV82K8VlnvyAONDHI+P1Fr 4wPUOG78JA4cWiqFwMXmBqbXKzn6axZLH+Dpn+7BAPA1u+ru9bPoFv7Cdy+EKUdYD3Nf v+GNXPwrZQbP3MsD+PqxKplowGXyvudU8KcsDCgIoJ9veO/rn7LD4dwJAamKPRa54Glq bn/Q== X-Gm-Message-State: AOAM533imnxeIzgmxpwpH0BmHGsKeVOnCA78IMT6YRa1A10iH75zG+7Q rAtiYUC3+xVonaRJXVfAmeE5lQMuk6+tEWYCaAM= X-Google-Smtp-Source: ABdhPJysjRgVwSDlkwHXEar3BTXsYSRAgi7z61SPhW0xixKFUGwmgOEKbq6/A/KPHAUDHqWukyA2L93AwG0cjdCSmkw= X-Received: by 2002:aa7:8d1a:0:b0:519:314f:5bec with SMTP id j26-20020aa78d1a000000b00519314f5becmr25927665pfe.10.1654075863673; Wed, 01 Jun 2022 02:31:03 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Arjen Markus Date: Wed, 1 Jun 2022 11:30:52 +0200 Message-ID: Subject: Re: is there a way to find out gfortran version and/or options from a given binary? To: Kay Diederichs Cc: Fortran List X-Spam-Status: No, score=-0.4 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_ENVFROM_END_DIGIT, FREEMAIL_FROM, HTML_MESSAGE, RCVD_IN_DNSWL_NONE, 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 Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: fortran@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Fortran mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 01 Jun 2022 09:31:10 -0000 Are you perhaps looking for the compiler_version() and compiler_options() functions? I use them like this, they were defined in Fortran 2008 if I am not mistaken: WRITE( lurep, '(a)' ) 'Report of simulation' WRITE( lurep, '(a)' ) '--------------------' WRITE( lurep, '(a)' ) 'Compiler version: ', compiler_version() WRITE( lurep, '(a)' ) 'Compiler options: ', compiler_options() Regards, Arjen Op wo 1 jun. 2022 om 10:42 schreef Kay Diederichs < kay.diederichs@uni-konstanz.de>: > Hi, > > is there any gfortran option and/or version information available from/in > a binary? Maybe accessible with objdump or strings? > > For ifort, we use the -sox option ("This option tells the compiler to save > the compilation options and version number in the executable file. ..."). > This enables e.g. > strings /path/to/binary | grep Intel > > Or is there a gfortran option that makes this accessible in a binary? > > Thanks, > Kay > > >