24小时热门版块排行榜    

查看: 703  |  回复: 2

hakuna

木虫 (知名作家)


[交流] 【求助】TB-LMTO-ASA编译时的libpgplot.a问题

最近在玩个老程序TB-MLTO-ASA,编译时遇到库文件libpgplot.a,搜了老半天也没能找到,SUSE系统不带这个,网上也没找到,如果把PGFLAGS= -lX11 -lm /usr/local/server/pgplot/AIX/libpgplot.a注释掉,编译刚开始就退出了,返回一大堆问题。
那位鼓捣过这个,指点一下,先谢过了。
本人用ifort+icc/SUSE干活.
回复此楼

» 猜你喜欢

» 本主题相关价值贴推荐,对您同样有帮助:

» 抢金币啦!回帖就可以得到:

查看全部散金贴

已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖

锐利的碎片

木虫 (正式写手)


★ ★ ★
小木虫(金币+0.5):给个红包,谢谢回帖交流
zzy870720z(金币+2): 谢谢指教 2011-03-07 15:23:56
hakuna(金币+50): 谢谢提供信息! 2011-03-07 15:24:47
//------------------------------//
                //  PGPLOT quick installation   //
                //         on a Linux computer        //
                //------------------------------//

0/ Make sure the devel package for X11 library is installed on your computer.
For instance, on a Mandriva 2010 Spring Linux distribution, it is the package libx11_6-devel; on Ubuntu 7.10, it is libx11-dev.

1/ Get the PGPLOT source tar file from http://astro.caltech.edu/~tjp/pgplot/


2/ Execute the following, as super-user (su) :

cp pgplot5.2.tar.gz /usr/local/src

cd /usr/local/src           # directory for the sources

tar -zxvf pgplot5.2.tar.gz

cd pgplot

mkdir /usr/local/pgplot          # create the directory for the binaries and font files

cd !$

cp /usr/local/src/pgplot/drivers.list .

emacs drivers.list &             # select (by removing the ! sign) the drivers to be
                          # used for pgplot outputs: typically:
                          # PSDRIV 1,2,3,4 : EPS figures
                          # XWDRIV 1,2 : X-window output (requires that the
                          #    package libxorg-x11-devel or an equivalent one
                          #    is installed on your system)

# ----- Optional part : to increase the number of simultaneous devices -------
#                           from 8 to 32

cd /usr/local/src/pgplot/src

cp grpckg1.inc grpckg1.inc_backup  # to keep a copy of the original source file
cp pgplot.inc pgplot.inc_backup    #

emacs grpckg1.inc & # Replace " PARAMETER (GRIMAX = 8) " in line 29
                    #    by   " PARAMETER (GRIMAX = 32) "
                    
emacs pgplot.inc &  # Replace " PARAMETER (PGMAXD=8) " in line 7
                    #    by   " PARAMETER (PGMAXD=32) "               

cd /usr/local/pgplot

# ---------------------- End of optional part ---------------------------------

/usr/local/src/pgplot/makemake /usr/local/src/pgplot linux g77_gcc  # prepares
                          # the makefile for linux system + gcc compiler

# ---------------- Special treatment for gcc 4.* ------------------
#
# If you are using the gcc 4.0 (or above) compilers (i.e. gfortran instead
# of g77), perform the following:

emacs makefile & # Replace "FCOMPL=g77"       in line 25
                 #   by    "FCOMPL=gfortran"
                 #
                 # Replace "FFLAGC=-u -Wall -fPIC -O" in line 26
                 #   by    "FFLAGC=-ffixed-form -ffixed-line-length-none -u -Wall -fPIC -O"

# ---------------- End of special treatment for gcc 4.* ----------------------

make                          # compiles the Fortran part

make cpg                  # compiles the C part (binding to Fortran)

emacs /usr/local/src/pgplot/makehtml &        # this file needs to be edited to
                          #  replace the first line by
                          #         #!/usr/bin/perl
make pgplot.html          #  produces the html documentation       

make clean

cd /usr/local/lib          #  libraries for local installations

ln -s /usr/local/pgplot/libpgplot.a libpgplot.a           # F77 static library

ln -s /usr/local/pgplot/libcpgplot.a libcpgplot.a  # C static library

cp /usr/local/pgplot/libpgplot.so .                     # dynamic (runtine) library

emacs /etc/ld.so.conf &          # edit this file to add the line /usr/local/lib

/sbin/ldconfig -v          # updates the path for runtime libraries

ln -s /usr/local/pgplot/cpgplot.h /usr/local/include/cpgplot.h


3/ Each end user should type (or put in his .bashrc or .tcshrc file):

# if csh or tcsh shells:
setenv PGPLOT_DIR /usr/local/pgplot/   
setenv PGPLOT_DEV /xwin          # prefered output device, an alternative is /xserve

# if bash shell:
PGPLOT_DIR=/usr/local/pgplot/
export PGPLOT_DIR
PGPLOT_DEV=/xwin          # prefered output device, an alternative is /xserve
export PGPLOT_DEV

cd /usr/local/pgplot

./pgdemo1                   # it should work !
http://www.lorene.obspm.fr/pgplot_quick.txt
2楼2011-03-07 12:57:47
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖

龙莹23333

新虫 (初入文坛)



小木虫: 金币+0.5, 给个红包,谢谢回帖
这个程序可以在哪里下载啊?求求给个链接吧
3楼2022-03-24 20:11:38
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖
相关版块跳转 我要订阅楼主 hakuna 的主题更新
普通表情 高级回复 (可上传附件)
最具人气热帖推荐 [查看全部] 作者 回/看 最后发表
[考研] 308求调剂 +4 是Lupa啊 2026-03-16 4/200 2026-03-17 17:12 by ruiyingmiao
[考研] 332求调剂 +6 Zz版 2026-03-13 6/300 2026-03-17 17:03 by ruiyingmiao
[考研] 东南大学364求调剂 +5 JasonYuiui 2026-03-15 5/250 2026-03-16 21:28 by 木瓜膏
[考研] 0703化学调剂 ,六级已过,有科研经历 +7 曦熙兮 2026-03-15 7/350 2026-03-16 16:34 by houyaoxu
[考研] 085600调剂 +5 漾漾123sun 2026-03-12 6/300 2026-03-16 15:58 by 漾漾123sun
[考研] 327求调剂 +6 拾光任染 2026-03-15 11/550 2026-03-15 22:47 by 拾光任染
[考研] 070305求调剂 +3 mlpqaz03 2026-03-14 4/200 2026-03-15 11:04 by peike
[考研] 289求调剂 +4 这么名字咋样 2026-03-14 6/300 2026-03-14 18:58 by userper
[考研] 【0703化学调剂】-一志愿华中师范大学-六级475 +5 Becho359 2026-03-11 5/250 2026-03-14 11:35 by 哦哦123
[考研] 266求调剂 +4 学员97LZgn 2026-03-13 4/200 2026-03-14 08:37 by zhukairuo
[考研] 求调剂(材料与化工327) +4 爱吃香菜啦 2026-03-11 4/200 2026-03-13 22:11 by JourneyLucky
[考研] 26调剂/材料科学与工程/总分295/求收留 +9 2026调剂侠 2026-03-12 9/450 2026-03-13 20:46 by 18595523086
[考研] 求调剂 +5 一定有学上- 2026-03-12 5/250 2026-03-13 18:31 by ms629
[考研] 310求调剂 +3 【上上签】 2026-03-11 3/150 2026-03-13 16:16 by JourneyLucky
[考研] 求调剂 +7 18880831720 2026-03-11 7/350 2026-03-13 16:10 by JourneyLucky
[考研] 314求调剂 +7 无懈可击的巨人 2026-03-12 7/350 2026-03-13 15:40 by JourneyLucky
[考研] 工科调剂 +4 Jiang191123! 2026-03-11 4/200 2026-03-13 15:15 by Miko19
[考研] 308求调剂 +3 是Lupa啊 2026-03-12 3/150 2026-03-13 14:30 by 求调剂zz
[考研] 289求调剂 +3 李政莹 2026-03-12 3/150 2026-03-13 11:02 by 求调剂zz
[考研] 化工学硕306求调剂 +9 42838695 2026-03-12 9/450 2026-03-13 10:16 by houyaoxu
信息提示
请填处理意见