你好,游客 登录 注册 搜索
背景:
阅读新闻

Linux下GAMIT安装备忘

[日期:2016-02-11] 来源:Linux社区  作者:Linux [字体:大 中 小]

系统环境:

VMware Workstation9 + Ubuntu 10.04

操作

1.安装VMware Workstation

参考:

VMware Workstation下载:http://www.linuxidc.com/Linux/2015-08/122297.htm

安装说明:http://www.linuxidc.com/Linux/2014-02/97388.htm

2.安装Ubuntu 10.04

安装说明:http://www.linuxidc.com/Linux/2014-04/100473.htm

3.安装GAMIT

最后出现了这样的错误:

++++++++++++++++++++++++++++++++++++++++++

Make sure the common libraries are current

++++++++++++++++++++++++++++++++++++++++++

Running unimake to create Makefile for comlib

System name:  Linux ubuntu 2.6.35-22-generic #33-Ubuntu SMP Sun Sep 19 20:34:50 UTC 2010 i686 GNU/Linux

System release number translated to  2635

No i86 compiler specification--assuming G77

ls: No match.

Machine-dependent source-files selected for com_lib :  bit_util_g77 cand_g77 cor_g77 fmpopen_g77 getdir_g77 getmac_g77 inkey_g77 irename_g77 pickfn_g77 fseekg_g77 fmprename_g77 fmpshortname_g77 fmprunprog_g77 ferror_g77 systime_g77 execute_g77

bit_util_g77.[cf]: No match.

Failure in make_gamit -- install_software terminated

解决方案:通过安装G77解决

1. 在/etc/apt/source.list中最后头添加如下源(以root的身份,或用 sudo):

deb http://hu.archive.ubuntu.com/ubuntu/ hardy universe
deb-src http://hu.archive.ubuntu.com/ubuntu/ hardy universe
deb http://hu.archive.ubuntu.com/ubuntu/ hardy-updates universe
deb-src http://hu.archive.ubuntu.com/ubuntu/ hardy-updates universe

2. 安装aptitude

 sudo apt-get install aptitude

3. 然后执行如下:

sudo aptitude update

 sudo aptitude install g77

2.之后提示

rnx2crx.c:87:13: warning: built-in function ‘y0’ declared as non-function [enabled by default]

rnx2crx.c:87:34: warning: built-in function ‘y1’ declared as non-function [enabled by default]

rnx2crx.c:108:6: error: conflicting types for ‘getline’

/usr/include/stdio.h:671:20: note: previous declaration of ‘getline’ was here

rnx2crx.c:559:6: error: conflicting types for ‘getline’

/usr/include/stdio.h:671:20: note: previous declaration of ‘getline’ was here

rnx2crx.c: In function ‘putdiff’:

rnx2crx.c:671:9: warning: '0' flag ignored with precision and ‘%d’ gnu_printf format [-Wformat]

rnx2crx.c: In function ‘put_clock’:

rnx2crx.c:689:9: warning: '0' flag ignored with precision and ‘%d’ gnu_printf format [-Wformat]

make: *** [rnx2crx] Error 1

Failure in make_gamit -- install_software terminated

解决方案:

根据错误实体是getline这个函数出了点问题,解决方法,找到rnx2crx.c,修改里面所有的getline为mygetline,具体位置在:

/opt/gamit/gamit/utils/rnx2crx.c(此处gamit为自己解压缩放置的路径)

之后就安装成功了!

GAMIT相关阅读:http://www.linuxidc.com/GAMIT/

GAMIT10.4下载在Linux公社5号FTP服务器,具体下载见 http://www.linuxidc.net/thread-1186-1-1.html

本文永久更新链接地址:http://www.linuxidc.com/Linux/2016-02/128247.htm

linux
本文评论   查看全部评论 (0)
表情: 表情 姓名: 字数

       

评论声明
  • 尊重网上道德,遵守中华人民共和国的各项有关法律法规
  • 承担一切因您的行为而直接或间接导致的民事或刑事法律责任
  • 本站管理人员有权保留或删除其管辖留言中的任意内容
  • 本站有权在网站内转载或引用您的评论
  • 参与本评论即表明您已经阅读并接受上述条款