Thanks Eric. You are right. I add &quot;-L$(PNG_LIB) -lpng12 -lpng&quot; to NCARG_LIBS2. Then every goes well.<div><br></div><div>brick<br><br><div class="gmail_quote">On Tue, Apr 6, 2010 at 3:19 PM, Eric Altshuler <span dir="ltr">&lt;<a href="mailto:ela@cola.iges.org">ela@cola.iges.org</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">Hello brick,<br>
<br>
Try adding -lpng to the NCARG_LIBS makefile variable. (Instead, you could add it to NCARG_LIBS2. It should work either way.) Prior to NCL version 5.1, this was not necessary, but with recent versions of NCL it is.<br>
<br>
Best regards,<br>
<br>
Eric L. Altshuler<br>
Assistant Research Scientist<br>
Center for Ocean-Land-Atmosphere Studies<br>
4041 Powder Mill Road, Suite 302<br>
Calverton, MD 20705-3106<br>
USA<br>
<br>
E-mail: <a href="mailto:ela@cola.iges.org">ela@cola.iges.org</a><br>
Phone: (301) 902-1257<br>
Fax: (301) 595-9793<br>
<div class="im"><br>
----- Original Message -----<br>
From: &quot;brick&quot; &lt;<a href="mailto:brickflying@gmail.com">brickflying@gmail.com</a>&gt;<br>
To: <a href="mailto:wrf-users@ucar.edu">wrf-users@ucar.edu</a><br>
</div><div><div></div><div class="h5">Sent: Monday, April 5, 2010 10:53:35 PM<br>
Subject: [Wrf-users] [wrf-users] Error when make plotgrids.exe and      plotfmt.exe<br>
<br>
<br>
Hi<br>
<br>
<br>
I use icc and ifort compile wps and wrf. All lib include Ncl were compiled by icc and ifort. There are no error appear when compile zlib libpng jasper or ncl.<br>
<br>
This is part of configure.wps. I link all needed path in it.<br>
All lib about X11 was create a link to /home/q/Program/IntelCompiled/lib_wrf<br>
CODE: SELECT ALL 9 # To permanently change options, change the settings for your platform<br>
10 # in the file arch/configure.defaults, the preamble, and the postamble -<br>
11 # then rerun configure.<br>
12 #<br>
13<br>
14 .SUFFIXES: .F .f .c .o<br>
15<br>
16 SHELL = /bin/sh<br>
17<br>
18 COMPRESSION_LIBS = -L/data3a/mp/gill/WPS_LIBS/local/lib \<br>
19 -L$(JASPERLIB) -L$(PNG_LIB) -L$(ZLIB_LIB) \<br>
20 -ljasper -lpng12 -lpng -lz<br>
21<br>
22 COMPRESSION_INC = -I/data3a/mp/gill/WPS_LIBS/local/include \<br>
23 -I$(JASPERINC) -I$(PNG_INC) -I$(ZLIB_INC)<br>
24<br>
25 NCARG_LIBS = -L$(NCARG_ROOT)/lib -lncarg -lncarg_gks -lncarg_c \<br>
26 -L/home/q/Program/IntelCompiled/lib_wrf -lX11<br>
27<br>
28 NCARG_LIBS2 =<br>
29<br>
30 FDEFS = -DUSE_JPEG2000 -DUSE_PNG<br>
<br>
Below are the errors I met.<br>
<br>
<br>
<br>
<br>
1300 ifort -o plotfmt.exe plotfmt.o read_met_module.o module_debug.o \<br>
1301 misc_definitions_module.o cio.o met_data_module.o \<br>
1302 -L/home/q/Program/IntelCompiled/Ncl_ncarg-5.1.1/lib -lncarg -lncarg_gks -lncarg_c -L/home/q/Program/IntelCompiled/lib_wrf -lX11<br>
1303 ld: skipping incompatible /home/q/Program/IntelCompiled/lib_wrf/libX11.so wh en searching for -lX11<br>
1304 /home/q/Program/IntelCompiled/Ncl_ncarg-5.1.1/lib/ libncarg_gks. a(pixwrite_pn g.o): In function `write_png&#39;:<br>
1305 pixwrite_png.c:(.text+0x43a): undefined reference to `png_create_write_struct&#39;<br>
1306 pixwrite_png.c:(.text+0x44f): undefined reference to `png_create_info_struct&#39;<br>
1307 pixwrite_png.c:(.text+0x47a): undefined reference to `png_init_io&#39;<br>
1308 pixwrite_png.c:(.text+0x48b): undefined reference to `png_malloc&#39;<br>
1309 pixwrite_png.c:(.text+0x4d9): undefined reference to `png_set_rows&#39;<br>
1310 pixwrite_png.c:(.text+0x505): undefined reference to `png_set_IHDR&#39;<br>
1311 pixwrite_png.c:(.text+0x530): undefined reference to `png_write_png&#39;<br>
1312 pixwrite_png.c:(.text+0x53d): undefined reference to `png_destroy_write_struct&#39;<br>
1313 pixwrite_png.c:(.text+0x563): undefined reference to `png_destroy_write_struct&#39;<br>
1314 pixwrite_png.c:(.text+0x58d): undefined reference to `png_destroy_write_struct&#39;<br>
1315 make[1]: [plotfmt.exe] Error 1 (ignored)<br>
<br>
<br>
<br>
<br>
1375 ifort -o plotgrids.exe module_map_utils.o module_debug.o cio.o constants_module .o misc_definitions_module.o \<br>
1376 plotgrids.o -L/home/q/Program/IntelCompiled/Ncl_ncarg-5.1.1/ lib -lncarg -lncarg_gks -lncarg_c -L/home/q/Program/IntelCompiled/lib_wrf -l X11<br>
1377 ld: skipping incompatible /home/q/Program/IntelCompiled/lib_wrf/libX11.so wh en searching for -lX11<br>
1378 /home/q/Program/IntelCompiled/Ncl_ncarg-5.1.1/lib/ libncarg_gks.a (pixwrite_pn g.o): In function `write_png&#39;:<br>
1379 pixwrite_png.c:(.text+0x43a): undefined reference to `png_create_write_struct&#39;<br>
1380 pixwrite_png.c:(.text+0x44f): undefined reference to `png_create_info_struct&#39;<br>
1381 pixwrite_png.c:(.text+0x47a): undefined reference to `png_init_io&#39;<br>
1382 pixwrite_png.c:(.text+0x48b): undefined reference to `png_malloc&#39;<br>
1383 pixwrite_png.c:(.text+0x4d9): undefined reference to `png_set_rows&#39;<br>
1384 pixwrite_png.c:(.text+0x505): undefined reference to `png_set_IHDR&#39;<br>
1385 pixwrite_png.c:(.text+0x530): undefined reference to `png_write_png&#39;<br>
1386 pixwrite_png.c:(.text+0x53d): undefined reference to `png_destroy_write_struct&#39;<br>
1387 pixwrite_png.c:(.text+0x563): undefined reference to `png_destroy_write_struct&#39;<br>
1388 pixwrite_png.c:(.text+0x58d): undefined reference to `png_destroy_write_struct&#39;<br>
1389 make[1]: [plotgrids.exe] Error 1 (ignored)<br>
<br>
What is the reason for these error? X11 lib incompatible? png lib connect incorrectly?<br>
<br>
Thanks.<br>
</div></div>_______________________________________________<br>
Wrf-users mailing list<br>
<a href="mailto:Wrf-users@ucar.edu">Wrf-users@ucar.edu</a><br>
<a href="http://mailman.ucar.edu/mailman/listinfo/wrf-users" target="_blank">http://mailman.ucar.edu/mailman/listinfo/wrf-users</a><br>
</blockquote></div><br></div>