* Linking fortran with C libs
@ 2008-07-22 20:18 Vardhan, Sundara (GE Infra, Energy)
2008-07-23 21:52 ` Vardhan, Sundara (GE Infra, Energy)
0 siblings, 1 reply; 2+ messages in thread
From: Vardhan, Sundara (GE Infra, Energy) @ 2008-07-22 20:18 UTC (permalink / raw)
To: gcc-help
Hi All
I installed gcc 4.2.3 with gfortran on AIX 5.3. Compiled and created a shared object with programs written in C. Compiled fortran code with gfortran and tried to link with the earlier created shared object. I get the following error
undefined reference to `.rtregister_'
where rt_register is the 'C' function call that is required.
The same set of programs worked fine on a Linux box with g77. Am I missing anything? Your help will be greatly appreciated.
With Regards
Vardhan
^ permalink raw reply [flat|nested] 2+ messages in thread
* RE: Linking fortran with C libs
2008-07-22 20:18 Linking fortran with C libs Vardhan, Sundara (GE Infra, Energy)
@ 2008-07-23 21:52 ` Vardhan, Sundara (GE Infra, Energy)
0 siblings, 0 replies; 2+ messages in thread
From: Vardhan, Sundara (GE Infra, Energy) @ 2008-07-23 21:52 UTC (permalink / raw)
To: Vardhan, Sundara (GE Infra, Energy), gcc-help
Hi All
Ignore my earlier mail. Since I was porting this software, I was not aware that there was a macro converting Fortran calls to equivalent C function names. Upon using the macros and also using -fno-second-underscore, I was able to successfully get past the issue.
With Regards
Vardhan
-----Original Message-----
From: gcc-help-owner@gcc.gnu.org [mailto:gcc-help-owner@gcc.gnu.org]On
Behalf Of Vardhan, Sundara (GE Infra, Energy)
Sent: Tuesday, July 22, 2008 3:24 PM
To: gcc-help@gcc.gnu.org
Subject: Linking fortran with C libs
Hi All
I installed gcc 4.2.3 with gfortran on AIX 5.3. Compiled and created a shared object with programs written in C. Compiled fortran code with gfortran and tried to link with the earlier created shared object. I get the following error
undefined reference to `.rtregister_'
where rt_register is the 'C' function call that is required.
The same set of programs worked fine on a Linux box with g77. Am I missing anything? Your help will be greatly appreciated.
With Regards
Vardhan
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2008-07-23 14:47 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-07-22 20:18 Linking fortran with C libs Vardhan, Sundara (GE Infra, Energy)
2008-07-23 21:52 ` Vardhan, Sundara (GE Infra, Energy)
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).