G95 - Fortran Compiler (Based of g77)
Hey everyone,
I'm working on a Macbook Pro Retina of mid 2014 running OS X 10.10 Yosemite.
Recently I tried installing the g95 fortran compiler, derived from the older g77. I simply moved the binary file to the right folder and performed a make install. Command line instructions seemed to work fine, but when I tried to run my compiled code it gave me the following error:
dyld: no valid entry point
Trace/BPT trap: 5
I figured I was missing certain gcc-libs, so I dug into my usr/local/lib folder and copied all the gcc-lib files I didn't already have (that came with the tarball for installing g95) there. However, it still doesn't work.
When I use otool on my binary file I get this:
g95:
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 125.0.1)
I know there should be another path specified there, but I have no idea as to what I could do to solve my problem. (I'm new to unix systems and the file system is challenging to say the least ;-))
PS: When I googled the error, it seemed to be a common problem with g77 that could only be solved by downgrading to an earlier version of OS X because of something named "Rosetta" that was no longer included. However, since g95 is "new" unlike g77, I think this rather an error caused by my inaptitude than an actual problem with my system.
Eventually, we will, Xiangyun.
It�s not simple to just switch it overnight. As a global enterprise, it�s a long and weary process in our shop to switch compilers, since we have to build, evaluate, compare outputs between old and new compilers, benchmark them, before we can put them into production, globally.
Not to mention that I always have problems with code-related, system-libraries related, undefined symbols, linking errors, etc. and etc. when switching compilers.
Therefore, if we can keep the reliable and proven compilers in the work, then we would keep it. So, if you could provide a patch to our current version; we�d keep it a year or so longer, then that would be a great great help, while we'll be working on pushing the new compilers out.
Thanks,
lhn
Similar Messages
-
Absoft fortran compiling and debugging
Hello eveyone,
I have recently purchased an iBook G4. My problem is that I do not know Unix or Darwin and I have witten a code using Fortran on Windows. Now that I am using a Macintosh I would like to debug and compile this code on my iBook. Can anybody advise me on how to do this and what Fortran compiler is the easiest to run on a Mac.
Thanks for taking interest.I have recently purchased an iBook G4. My problem is
that I do not know Unix or Darwin and I have witten a
code using Fortran on Windows. Now that I am using a
Macintosh I would like to debug and compile this code
on my iBook. Can anybody advise me on how to do this
and what Fortran compiler is the easiest to run on a
Mac.
This is a golden opportunity to learn some Unix. The Fink project
http://fink.sourceforge.net/
will permit you to quite painlessly install (in addition to what is already available when you install the developer tools that came with OS X) the excellent g77 (GNU Fortran 77) or g95 (GNU-related Fortran 95) compilers and crunch away.
The learning curve for command line tools is not as steep as you might think!
Depending on your needs, it could be as simple as
g77 -o mybin mysource.f
./mybin < input.data
Snoop around the Unix forum Apple discussion group for more info. Good luck! -
[SOLVED] Intel Fortran Compiler v11.1.072 installation failed
hi everyone!
i have some problems with the intel fortran installation. i try to install both ia32 and intel64 version, but without success. i launch from the shell the file "install.sh" and i follow the instructions on the screen, it says that i have missing optional pre-requisites, but also in other linux distribution such as ubuntu or debian, i always skip missing optional pre-requisites and go on. so i do that, but in the step no. 6 when the installation begins, there are a lot of errors:
Installing Intel(R) Fortran Compiler for applications running on IA-32
component...
Intel(R) Fortran Compiler for applications running on IA-32 component
installation failed.
Installing Intel(R) Math Kernel Library for applications running on IA-32
component...
Intel(R) Math Kernel Library for applications running on IA-32 component
installation failed.
what happens?
thanks all for your replies, i'm here for other infos if you want.
Last edited by zeruel85 (2010-06-28 07:56:26)ok, i solved the problem, but with another ifort version. first of all, install these required packages:
sudo pacman -S glibc libstdc++5
then download from aur the package "intel-compilers-common 11.0.074-2" and extract it. now:
cd /PATH/intel-compilers-common
makepkg
sudo pacman -U intel-compilers-common-11.0.074-2-x86_64.pkg.tar.xz
always from aur, download "ifort" and extract it. before compiling it, copy the file "l_cprof_p_11.0.074_intel64.tgz" from the "intel-compilers-common" folder into the "ifort" folder. now we must have the license file. we can get it from the official intel site:
https://registrationcenter.intel.com/Re … NCOM&lang=
just insert your email, select your country and click "Continue". we'll receive an email with the license key attached. now copy the file into the "ifort" folder. open a shell and do this:
cd /PATH/ifort
md5sum LICENSE.lic
where "LICENSE.lic" is the name of your license key. after that, we have to modify the "PKGBUILD" file, always into the "ifort" folder. in line 19, write the correct license file name. in line 24 write the correct md5sum result. save and exit. now we can compile:
cd /PATH/ifort
makepkg
sudo pacman -U ifort-11.0.074-2-x86_64.pkg.tar.xz
now we have ifort installed! just logout/login to complete the installation! then type:
ifort -help
to verify if ifort was correctly installed. if the ifort guide appears, well done! -
Bug report for SS10U1 fortran compiler
I am getting an internal error when compiling a larger fortran source file:
f90: Internal Error, code=fw-assert-einln-835, last src=mbd.f:14
If I first split the file and then compile the separate routines, the compiler survives:
fsplit mbd.f
f95 -c addblk.f fperio.f getblk.f mbbwi.f mgmbwi.f puta2blk.f putblk.f
I'll be happy to provide a tar-ball to a Sun engineer.
f90 -V
Intel(R) Fortran Compiler for 32-bit applications, Version 8.1 Build 20050309Z Package ID: l_fc_pc_8.1.025
Copyright (C) 1985-2005 Intel Corporation. All rights reserved.
FOR NON-COMMERCIAL USE ONLY
GNU ld version 2.15.90.0.1.1 20040303 (SuSE Linux)
Supported emulations:
elf_i386
i386linux
elf_x86_64
best regards
Dieteruups.
sorry for printing the intel compiler version I am running.
I veryfied that the problem persists
This is the release of the Sun compiler causing the problem:
/opt/sun/sunstudio10u1/bin/f90 -V
f90: Sun Fortran 95 8.3 __version_f9x_patch_linux Build2_0 2005/08/01 -
Intel Fortran compiler broken under Mavericks
After upgrading to OS 9 on a Mac Pro and a MacBook Pro, and installing Xcode 5.0.1 on both, my Intel Fortran compiler (vs 12.0.5) no longer works. I have updated the command line tools. When I try compiling a source file it fails with the message:
ifort: error #10001: could not find directory in which g++ resides
There is a compiler option to specify the location of g++ "-gxx-name=" but this doesn't help - same error message. I'm not sure if I need to set a system variable or if I need to go back to an earlier version of Xcode. Has anyone managed to get their Intel Fortran compiler working under Mavericks?I haven't found this topic in the other Categories, so I'll reply here:
I'm having the same problem!!! Leopard has crashed ifort 32 bits! So I can't run my programs on my macbook core duo (32 bits), although it's ok with the ifort 64 bits version. But I really REALLY need the 32 version working on Leopard. Anyone has any clue about how to solve it? I've tried some 9.1 ifort's versions and the new 10.1 version. You can find evaluation versions on the intel's site.
Please someone help us.
Thanks,
Filipe -
How do I link in a Fortran Compiler into MatrixX/Sy​stembuild ?
We currently use MatrixX and have Visual C++ ver 5 installed. I would like to add a Fortran compiler to the system. How do I get MatrixX to point to the fortran compiler ? Are there environmental variables I need to set ?
I believe that there are several things that you will need to do. I am checking on them since I did not find a lot explicit in the manual.
First, Like the C++ compiler, I believe that you will need to set the environment variables for the Compiler path, lib and include. This will enable the compiler to be called from the command line as is the C++ Compiler. There are probably instructions with the compiler on how to do this operation.
I believe that the compatible compiler is the Visiual FORTRAN from Microsoft. Version 6 maybe.
Second, you may need to take a look at the makefile.mk and ensure that the appropriate changes are made.
Finally, I think you need to call the fortran function from a C wrapper, appropriately
configuring the User Code Block.
Again, I hope that I hear some more definitive information back from whom I asked, once I do I'll let you know.
There are some example files attached passed to me from a user "Chris" in Canada.
Garrett Thurston
[email protected]
Phone: 781.993.5540
Attachments:
sa_user.c 3 KB
SA_USRF.f 4 KB
Makefile.mk 6 KB -
Intel Fortran compiler - ifortbin: No such file or.. [solved]
Dear all!
I am running arch64 with updated packages (I updated this morning). I am trying to install the intel fortran compiler. I took the "ifort" PKGBUILD file from AUR and I edited it to use the "em64t" packages instead of the "i386" packages. The package building and the installation went fine, but when I launch ifort, I get the following error:
/opt/intel/fc/9.1.036/bin/ifort: line 42: /opt/intel/fc/9.1.036/bin/ifortbin: No such file or directory
/opt/intel/fc/9.1.036/bin/ifort: line 42: /opt/intel/fc/9.1.036/bin/ifortbin: Success
Instead, I should get a message saying that I gave no input files (I had the compiler working on Suse, that's how I know).
Does anyone know why this is happening?
Thanks for your help
Valerio
Last edited by valmar (2007-04-03 16:41:08)Thank to all those who looked at the thread. It seems that even if you install a 64 bit version on a 64 bit machine, you still have to have the following packages installed:
lib32-glibc lib32-gcc.
Which means that the 64 bit compiler is actually designed to run in a mixed system, and not a pure 64 bit system... very bizarre
Valerio -
Fortran Compiler Bug? USE statement renaming
The Fortran compiler
f90: Sun Fortran 95 8.2 Patch 121020-05 2006/12/08
complain, incorrectly I believe, about a renaming in a USE statement. Here is the source code:
MODULE mod
INTEGER :: m
CONTAINS
SUBROUTINE sub_mod(m1,x)
INTEGER, INTENT(in) :: m1
REAL :: x(m)
x = 3.
END SUBROUTINE sub_mod
END MODULE mod
SUBROUTINE sub(m,isum)
USE mod, mod_m => m
INTEGER :: m, isum
isum = m + mod_m
RETURN
END
The compiler says:
f90 -c LStest16.f
USE mod, mod_m => m
^
"LStest16.f", Line = 12, Column = 11: ERROR: "M" is the name of a dummy argument to program unit "SUB", therefore it must not be use associated from module "MOD".
^
"LStest16.f", Line = 12, Column = 11: ERROR: "M" has been use associated from module "MOD" and at least one more module. It must not be referenced.
f90comp: 16 SOURCE LINES
f90comp: 2 ERRORS, 0 WARNINGS, 0 OTHER MESSAGES, 0 ANSI
Note that changing from
REAL :: x(m)
to
REAL :: x(m1)
in the sixth line makes the compiler happy.
Seems odd to me.It looks like a bug. I'll have someone look into it.
Bob Corbett -
Compiling based on variable remote machine
I am having great trouble getting a script to compile based on a repeat loop from a record. The script compiles fine if the finder actions are something simple like a beep but when I put in my required actions it fails to compile.
I think the problem is related to how I refer to the "of machine ....." but can't work out why it is related to my finder actions...
Any help much appreciated.
set catlist to {{catname:"Ollie", catip:"eppc://192.168.1.12", ssdDrive:":Volumes:Cat109 Content A:"}, {catname:"Richard", catip:"eppc://192.168.1.13", ssdDrive:":Volumes:Cat109 Content A:"}}
repeat with cat_ref in catlist
set theMachine to catip of cat_ref
with timeout of 10 seconds
tell application "Finder" of machine theMachine
activate
set sourceFile1 to document file "001_Sahr.mov" of folder "096-Act 1 - Club shots" of folder "Cast Rotation" of folder "SSD" of disk "Cat109 Content A"
set destinationFile1 to folder "096-Act 1 - Club shots" of folder "Active" of disk "Cat109 Content A"
duplicate sourceFile1 to destinationFile1 with replacing
set foldercontents1 to result
end tell
end timeout
end repeatThere are many issues to deal with when using remote Apple Events, especially with regard to user permissions/access. In general you can't easily target an application on a remote machine that's running as a different user (e.g. you're logged in as 'joe', but the 'bob' is logged in the remote machine - 'joe' can't tell 'bob's Finder what to do.
Once you address that issue, please never, ever, ever do this:
tell application "Finder" of machine theMachine
activate
Imagine you're bob running on the remote machine, in the middle of writing a document, editing an image, browsing the web - it doesn't really matter - when all of a sudden, without any notice or warning, the Finder pops to the front for no apparent reason. Aaagghhhh! How annoying would that be?
There is rarely, if ever, any need to activate the Finder. If it's running, even in the background, you can send it commands and it will do what you ask. It does not have to be frontmost to do so.
That said, I'd take a slightly different approach to your task and eschew the Finder altogether. A shell command is probably an easier way to achieve what you're trying here:
tell application "System Events" of machine theMachine
do shell script "cp -r '/Cat109 Content A/SSD/Cast Rotation/096-Act 1 - Club shots/001_Sahr.mov' '/Cat109 Content A/Active/096-Act 1 - Club shots/'"
end tell -
Leopard broke Intel Fortran Compiler, both ver9 and 10
Intel Fortran Compiler for Mac OS X Ver 9.1 and 10.0 is broken under Leopard. It can compile code, but the created executable segfaults with messages like these.
forrtl: severe (174): SIGSEGV, segmentation fault occurred
Image PC Routine Line Source
read.out 0005B601 Unknown Unknown Unknown
read.out 0005AAA3 Unknown Unknown Unknown
read.out 00031A4A Unknown Unknown Unknown
read.out 0000F664 Unknown Unknown Unknown
read.out 00015FDE Unknown Unknown Unknown
libSystem.B.dylib 94BF997B Unknown Unknown Unknown
The program can be as easy as:
parameter(ilon=144,ilat=73,igrid=ilon*ilat)
parameter(iday=365)
real*4 :: data(igrid), ave(igrid)
open(10,file='u.bin',form='unformatted',access='direct',recl=igrid*4)
open(11,file='u-daily.bin',form='unformatted',access='direct',recl=igrid*4)
do it = 1, 365
write(6,*) it
read(10,rec=it) data
ave = ave + data
end do
ave = ave / 365
write(11,rec=1) ave
stop
end
The program crashes at line 9 or 11 where vectorization comes into place.
I went to the Intel homepage, and they acknowledge this as a problem but they are only willing to update IFC ver10 and leave the users of ver9 in the cold.
Does anyone have a solution to this?
(At least I will leave this message up so that hopefully someone at Apple will notice.)I haven't found this topic in the other Categories, so I'll reply here:
I'm having the same problem!!! Leopard has crashed ifort 32 bits! So I can't run my programs on my macbook core duo (32 bits), although it's ok with the ifort 64 bits version. But I really REALLY need the 32 version working on Leopard. Anyone has any clue about how to solve it? I've tried some 9.1 ifort's versions and the new 10.1 version. You can find evaluation versions on the intel's site.
Please someone help us.
Thanks,
Filipe -
Unexpected Fortran compiler behavior on variable declarations.
There are several problems concerning Sun Fortran compiler for Linux, concerning variable declarations:
(1) A variable can be declared two or more times within the same
program scope. Surprisingly, the compiler accepts this, without any error or
warning message. This is clearly a bug.
(2) There is no warning message if a variable is used but never set, even if the -w4 flag is used. This is a serious bug.
(3) There is no warning message if a variable is declared but never
used.
To illustrate the bugs, compile the following simple program:
module fooModule
implicit none
public :: add
contains
function add(x,y)
real, intent(in) :: x,y
real :: unused ! This variable is never used and never set; no warning message.
real :: add
add=x+y
end function add
end module fooModule
program TryProg
use fooModule
implicit none
real :: x
integer :: i
integer :: i ! Duplicated declaration. The compiler accepts this!
i=3
print*,i
print*,add(x,2.0) ! Variable x is used but not set; no warning message.
end program TryProg
EXPECTED BEHAVIOR:
(1) Something like "ERROR: Duplicate declaration of 'i'" or "ERROR:
Symbol 'i' already has basic type of INTEGER."
(2) WARNING: Variable 'x' is used but not set.
(3) WARNING: Variable 'unused' is never used and never set.
ACTUAL BEHAVIOR:
No error or warning messages; expected one error and two warnings.
The bugs appear in all Fortran compilers for Linux, including latest release, SSX2.There are several problems concerning Sun Fortran
compiler for Linux, concerning variable
declarations:
(1) A variable can be declared two or more times
within the same
program scope. Surprisingly, the compiler accepts
this, without any error or
warning message. This is clearly a bug.
The bugs appear in all Fortran compilers for Linux,
including latest release, SSX2.You have cited a number of constraint violations. The
Fortran standard states
A processor conforms to this standard if
(3) It contains the capability to detect and report the
use within a sumitted program unit of an
additional form or relationship that is not
permitted by the numbered syntax rules or
constraints, including the deleted features
described in Annex B;
In English, this statement means that a conforming
implementation must be able to detect and report
syntax errors and constraint violations. It does not
mean that it must detect and report them by default.
Sun f95, like most other Fortran compilers, does not
give errors or warnings for the use of common
extensions by default. The option -ansi enables
the compilation mode that reports such uses.
For example, when I compile the program
PROGRAM MAIN
REAL X
REAL X
END
with the option -ansi, I get
REAL X
^
"t.f", Line = 2, Column = 1: ANSI: Use of the tab character is an extension of the Fortran standard.
REAL X
^
"t.f", Line = 3, Column = 7: ANSI: "X" has been given the REAL attribute more than once. This is nonstandard.
f90comp: 4 SOURCE LINES
f90comp: 0 ERRORS, 0 WARNINGS, 0 OTHER MESSAGES, 2 ANSI
The caret lines up with the identifer X in the output. The column
number is given as column 7, because the letter X is the seventh
character in the line. -
G77 Fortran compiler on Intel MacBook?
Does anyone know if G77 works on intel macs? I was using it on my iBook (Power PC) - it was installed using Fink+ X code tools.
I'm trying to get g77 to work on my intel MacBook now but Fink seems to suggest g77 is not available for intels. Has anyone tried this?
Alternatively, are there any other fortran compilers out there that will work on intel macs?
thanks,
ash
MacBook Mac OS X (10.4.6)That worked, thanks! I think the executable it produces are for PPC but they still run ok.
However, I am having some problems linking a series of object files. I get this error:
/usr/bin/ld: Undefined symbols:
MAIN_
collect2: ld returned 1 exit status
Does anyone have any insight into what could be causing this? Those object files link perfectly fine on a linux machine. Seems to be something to do with the ld binary??
MacBook Mac OS X (10.4.6) -
SQL query won't compile based on DB role privileges
Can someone give me an explanation why the SQL query in a report won't compile if an object is owned by another schema and the parsing schema is given privileges to the table via a role grant?
Or to phrase it another way, why do we have to make direct grants on tables to the parsing schema for reports based on SQL queries that access tables in other schemas?
Thanks in advance,
PaulPaul - In Oracle, roles are not enabled during the execution of definer's rights stored procedures which is the environment in which all Application Express application code is parsed/executed. There are scads of posts about this topic in this forum.
Scott -
64bit support for SS10U1 fortran compiler
Hi folks,
I've problems to compile fortran 90 code with the recent compiler version to 64 bit code (option -xarch=amd64). Code fragments with string/real conversion doesn't work, at runtime the following error message is thrown:
YOU CALLED AN ENTRY(econvert) FROM AN AS YET UNDELIVERED LIBRARY
It seems that these routines located in the libc_sol library are
not proper implemented. The same code works in 32 bit mode
fine.
Does anyone have further information?
Thanks & Bye,
ChristianSupport for 64bit econvert was added in Build7_0.
Check your version string using -V to see which
version you are using. When I see
f90: Sun Fortran 95 8.3 Build7_0 2005/10/10
I am able to compile and run
WRITE(6, '(E10.2)') 3.14159_8
END
without error, but not so with Build6_0. -
Performance issue studio 10 fortran compiler on 2500 blade solaris 10
Dear All,
We facing performance issue on sun blade 2500 with fortran (studio 10).
when we run our code it took 14 min. where same code tokk 1min IRIS/Apple Power Mac/HP/Linux .
if u any solution on this pl. mail me [email protected]
regards
NarayanYou'll need to provide more details before we can help you. You could start by using the performance analyzer to find the slowest parts of your program. You might also be using inappropriate flags (e.g., compiling without optimization would be a problem).
Maybe you are looking for
-
How do I install Premiere Elements 11 onto a Windows 8 computer?
It only gives me options for Windows 7 64 bit and the earlier Windows system. Whichever one I choose, it tells me it cannot save the file onto the c: drive. Advice?
-
Hi All, This is my first JDBC Pgm... I got the driver mysql driver and placed the same in the lib of the jdk... when i compile teh java file without the Statement and Resultset it compiles fine.. but when i compile tis file, import java.sql.Connectio
-
I am new to iMac. I plugged in my iPhone to upload all my trip pictures into an event in iPhoto. Only some of them came and the others seem to be in photo stream album. I wanted to move them from photo stream and put them into an event. I dont think
-
Installing at base path / Installer: The install failed
When attempting to install Adobe Reader XI (11.0.0.7), the installer fails with the above error message and the addendum of: "the Installer encountered an error that caused the installation to fail. contact the software manufacturer for assistance.)"
-
How to debug the webdynpro application
Hi , i am facing a problem for debugging web dynpro application from offshore (my server is located in onsite) and i connected using VPN and also i changed my SDM Debug Mode to ON and also enable debugging of process also but it is giving error mes