This archive contains answers to questions sent to Unidata support through mid-2025. Note that the archive is no longer being updated. We provide the archive for reference; many of the answers presented here remain technically correct, even if somewhat outdated. For the most up-to-date information on the use of NSF Unidata software and data services, please consult the Software Documentation first.
Dan, Your problem is probably through your -L$GEMLIB definition. $GEMLIB should be pointing to the $NAWIPS/lib/linux directory, and not the gemlib.a file itself. And, the -L flag is only used when using the -l option with file named using the lib*.a (for example libm.a is referenced using -lm). You probably want: g77 -o rean_comp3 ream_comp3.f $GEMLIB/gemlib.a Steve Chiswell Unidata User Support >From: "Dan Stjean" <address@hidden> >Organization: DOC/NOAA/NWS - National Weather Service >Keywords: 200206230410.g5N4Aha12655 >This is a multi-part message in MIME format. >--------------9CDC046F02714987CA56BC5E >Content-Type: multipart/alternative; > boundary="------------BB79DBA662BF6290F239BCF2" > > >--------------BB79DBA662BF6290F239BCF2 >Content-Type: text/plain; charset=us-ascii >Content-Transfer-Encoding: 7bit > >Hi, > >I'm using Unidata's gempak 5.6e (gempak_upc5.6.e.1.tar) installation on >a Linux machine. I just did a clean reinstall to see if that would >solve the following problem I've been having. It didn't: > >My goal is to extract multiple Gempak grids from existing Gempak grid >files for the purpose of doing some compositing of these fields. The >only method with which I am familiar for doing this is via fortran >(f77/g77) code. My program utilizes the following GEMPAK program >subroutine calls: >in_bdta >gd_opnf >gd_rdat >gd_wdat >gd_clos > >my compile line is: > f77 -o rean_comp3 rean_comp3.f -L$GEMLIB > >and I get these compiling errors: > >/tmp/ccORzAU2.o: In function `MAIN__': >/tmp/ccORzAU2.o(.text+0x86f): undefined reference to `in_bdta__' >/tmp/ccORzAU2.o(.text+0x8eb): undefined reference to `gd_opnf__' >/tmp/ccORzAU2.o(.text+0x946): undefined reference to `gd_rdat__' >/tmp/ccORzAU2.o(.text+0x9f2): undefined reference to `gd_clos__' >/tmp/ccORzAU2.o(.text+0x1154): undefined reference to `gd_opnf__' >/tmp/ccORzAU2.o(.text+0x11b7): undefined reference to `gd_wdat__' >/tmp/ccORzAU2.o(.text+0x11cd): undefined reference to `gd_clos__' >collect2: ld returned 1 exit status > >Am I linking to the wrong libraries to make these programs run? (They >used to work fine in the Nawips5.4 for HP-UX (HP-UX v10.2) release. ) > >Any assistance you can offer would be greatly appreciated. Please allow >me to forward any additional information about my code, my system, or my >gempak installation which you require. > >Thank you, > >Dan St. Jean >National Weather Service Burlington VT > >--------------BB79DBA662BF6290F239BCF2 >Content-Type: text/html; charset=us-ascii >Content-Transfer-Encoding: 7bit > ><!doctype html public "-//w3c//dtd html 4.0 transitional//en"> ><html> >Hi, ><p>I'm using Unidata's gempak 5.6e (gempak_upc5.6.e.1.tar) installation >on a Linux machine. I just did a clean reinstall to see if that would >solve the following problem I've been having. It didn't: ><p>My goal is to extract multiple Gempak grids from existing Gempak grid >files for the purpose of doing some compositing of these fields. >The only method with which I am familiar for doing this is via fortran >(f77/g77) code. My program utilizes the following GEMPAK program >subroutine calls: ><br>in_bdta ><br>gd_opnf ><br>gd_rdat ><br>gd_wdat ><br>gd_clos ><p>my compile line is: ><br><b> f77 -o rean_comp3 rean_comp3.f -L$GEMLIB</b> ><p>and I get these compiling errors: ><p>/tmp/ccORzAU2.o: In function `MAIN__': ><br>/tmp/ccORzAU2.o(.text+0x86f): undefined reference to `in_bdta__' ><br>/tmp/ccORzAU2.o(.text+0x8eb): undefined reference to `gd_opnf__' ><br>/tmp/ccORzAU2.o(.text+0x946): undefined reference to `gd_rdat__' ><br>/tmp/ccORzAU2.o(.text+0x9f2): undefined reference to `gd_clos__' ><br>/tmp/ccORzAU2.o(.text+0x1154): undefined reference to `gd_opnf__' ><br>/tmp/ccORzAU2.o(.text+0x11b7): undefined reference to `gd_wdat__' ><br>/tmp/ccORzAU2.o(.text+0x11cd): undefined reference to `gd_clos__' ><br>collect2: ld returned 1 exit status ><p>Am I linking to the wrong libraries to make these programs run? >(They used to work fine in the Nawips5.4 for HP-UX (HP-UX v10.2) release. >) ><p>Any assistance you can offer would be greatly appreciated. Please >allow me to forward any additional information about my code, my system, >or my gempak installation which you require. ><p>Thank you, ><p>Dan St. Jean ><br>National Weather Service Burlington VT</html> > >--------------BB79DBA662BF6290F239BCF2-- > >--------------9CDC046F02714987CA56BC5E >Content-Type: text/x-vcard; charset=us-ascii; > name="dan.stjean.vcf" >Content-Transfer-Encoding: 7bit >Content-Description: Card for Dan St. Jean >Content-Disposition: attachment; > filename="dan.stjean.vcf" > >begin:vcard >n:St. Jean;Dan >tel;fax:802.660.0705 >tel;work:802.658.0207 >x-mozilla-html:FALSE >url:http://205.156.54.206/er/btv/ >org:DOC/NOAA/National Weather Service;WFO Burlington VT >version:2.1 >email;internet:address@hidden >title:Senior Meteorologist >adr;quoted-printable:;;Burlington International Airport=0D=0A1200 Airport Road > =0D=0A;South Burlington;VT;05403; >fn:Dan St. Jean >end:vcard > >--------------9CDC046F02714987CA56BC5E-- >