Greetings Liang, Your $PATH variable have many entries, but these two: /Applications/Xcode.app/Contents/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin make me wonder if there is some issue - you should not need these in $PATH (if you set those in your .profile, try removing those enteries). Have you tried to compile a simple hello_world.c example to check if gcc is working that way? Also, there should be a config.log in the top level directory of the netCDF distribution folder - would you mind sending me a copy of that? Thanks! Sean > Hi Sean, > > I correct the instance of Xcode, but the problem is still there. > > Here is the my env: > ======================= > TERM_PROGRAM=Apple_Terminal > TERM=xterm-256color > SHELL=/bin/bash > TMPDIR=/var/folders/lv/2nyv__qj0c5_j6xn4j4lxts40000gn/T/ > Apple_PubSub_Socket_Render=/tmp/launch-riM1pQ/Render > TERM_PROGRAM_VERSION=303 > TERM_SESSION_ID=2B75AD56-CEE6-4022-AA60-3B6195F42D95 > USER=liangguo > COMMAND_MODE=unix2003 > SSH_AUTH_SOCK=/tmp/launch-hGOXKH/Listeners > __CF_USER_TEXT_ENCODING=0x1F5:0:0 > Apple_Ubiquity_Message=/tmp/launch-Y87ClN/Apple_Ubiquity_Message > PATH=/usr/local/texlive/2011/bin/universal-darwin:/usr/texbin:/opt/local/bin:/opt/local/sbin:/usr/local/texlive/2011/bin/universal-darwin:/usr/texbin:/opt/local/bin:/opt/local/sbin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/X11/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin > PWD=/Users/liangguo/Downloads/netcdf-4.2 > LANG=en_GB.UTF-8 > SHLVL=1 > HOME=/Users/liangguo > LOGNAME=liangguo > DISPLAY=/tmp/launch-zCC5U4/org.x:0 > _=/usr/bin/env > OLDPWD=/Users/liangguo/Downloads > ======================= > > Thank you very much, > Liang > > > On 5 May 2012, at 11:40, Unidata netCDF Support wrote: > > > Greetings Liang, > > > > /Developer/usr/bin/gcc is an old path, but it seems to be picking the right > > gcc version for you (which is interesting). What is the output of > > > > xcode-select -print-path > > > > It should be > > > > /Applications/Xcode.app/Contents/Developer > > > > If not, run this command to select the correct instance of Xcode: > > > > sudo xcode-select -switch /Applications/Xcode.app/Contents/Developer > > > > Then try running configure again. Also, if you are really only interested > > in the classic library, then make sure to add --disable-netcdf-4 to the > > flags in your configure command: > > > > ./configure --prefix=/Users/liangguo/Applications --disable-netcdf-4 > > --disable-dap > > > > Let me know how this goes for you. If none of these things work, could you > > send me the output of the command env? > > > > Cheers! > > > > Sean > > > >> Hi Sean, > >> > >> I update the Xcode to the latest version (4.3.2) from apple store. The > >> problem is still there. > >> > >>> which gcc > >> /Developer/usr/bin/gcc > >> > >>> gcc --version > >> i686-apple-darwin10-gcc-4.2.1 (GCC) 4.2.1 (Apple Inc. build 5664) > >> Copyright (C) 2007 Free Software Foundation, Inc. > >> This is free software; see the source for copying conditions. There is NO > >> warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. > >> > >> Thank you ver much, > >> Liang > >> > >> > >> > > > > > > Ticket Details > > =================== > > Ticket ID: XDX-509004 > > Department: Support netCDF > > Priority: Normal > > Status: Open > > > > > > Ticket Details =================== Ticket ID: XDX-509004 Department: Support netCDF Priority: Normal Status: Open
NOTE: All email exchanges with Unidata User Support are recorded in the Unidata inquiry tracking system and then made publicly available through the web. If you do not want to have your interactions made available in this way, you must let us know in each email you send to us.