作者共發了11篇帖子。
【庆祝】ubuntu下终于成功编译了jenngo
1樓 巨大八爪鱼 2012-8-22 17:56
2樓 巨大八爪鱼 2012-8-22 17:57
octopus@pc3:~$ cd /home/octopus/文档/编程/C++/测试区/opengl
octopus@pc3:~/文档/编程/C++/测试区/opengl$ g++ test.cpp -o test -lglut
/tmp/ccuX7lKx.o: In function `reshape(int, int)':
test.cpp:(.text+0x2ec): undefined reference to `gluPerspective'
test.cpp:(.text+0x33b): undefined reference to `gluLookAt'
/tmp/ccuX7lKx.o: In function `cycle_view()':
test.cpp:(.text+0x3dc): undefined reference to `gluLookAt'
test.cpp:(.text+0x41f): undefined reference to `gluLookAt'
test.cpp:(.text+0x46f): undefined reference to `gluLookAt'
collect2: ld 返回 1
octopus@pc3:~/文档/编程/C++/测试区/opengl$ sudo apt-get install mesa-common-dev mesademos libgl1-mesa-dev libglu1-mesa-dev freeglut3-dev
[sudo] password for octopus:
正在读取软件包列表... 完成
正在分析软件包的依赖关系树       
正在读取状态信息... 完成       
E: 未发现软件包 mesademos
octopus@pc3:~/文档/编程/C++/测试区/opengl$ g++ sample.cpp -o sample -lglut
octopus@pc3:~/文档/编程/C++/测试区/opengl$ g++ example.cpp -o example -lglut
/tmp/ccee9W1e.o: In function `init()':
example.cpp:(.text+0x138): undefined reference to `gluLookAt'
collect2: ld 返回 1
octopus@pc3:~/文档/编程/C++/测试区/opengl$ g++ test2.cpp -o test2 -lglut -LGLU
/tmp/cckuU9L2.o: In function `main':
test2.cpp:(.text+0x21): undefined reference to `gluPerspective'
collect2: ld 返回 1
octopus@pc3:~/文档/编程/C++/测试区/opengl$ g++ test2.cpp -o test2 -lglut -lGLU
octopus@pc3:~/文档/编程/C++/测试区/opengl$ g++ example.cpp -o example -lglut -lGLU
octopus@pc3:~/文档/编程/C++/测试区/opengl$ g++ test.cpp -o test -lglut -lGLU
octopus@pc3:~/文档/编程/C++/测试区/opengl$ cd /home/octopus/程序/jenngo
octopus@pc3:~/程序/jenngo$ make
g++ -I/sw/include -o jenn jenn.o linalg.o todd_coxeter.o go_game.o animation.o drawing.o definitions.o
jenn.o: In function `_glut_update_projection()':
jenn.C:(.text+0xec): undefined reference to `glMatrixMode'
jenn.C:(.text+0xf1): undefined reference to `glLoadIdentity'
jenn.C:(.text+0x185): undefined reference to `glOrtho'
jenn.C:(.text+0x191): undefined reference to `glMatrixMode'
jenn.C:(.text+0x196): undefined reference to `glLoadIdentity'
jenn.C:(.text+0x19b): undefined reference to `glutPostRedisplay'
jenn.o: In function `unpause()':
jenn.C:(.text+0x244): undefined reference to `glutIdleFunc'
jenn.o: In function `toggle_pause()':
jenn.C:(.text+0x28e): undefined reference to `glutIdleFunc'
jenn.o: In function `display()':
jenn.C:(.text+0x2cb): undefined reference to `glClear'
jenn.C:(.text+0x32b): undefined reference to `glViewport'
jenn.C:(.text+0x365): undefined reference to `glViewport'
jenn.C:(.text+0x38d): undefined reference to `glRotatef'
jenn.C:(.text+0x3c2): undefined reference to `glRotatef'
jenn.C:(.text+0x3e6): undefined reference to `glViewport'
jenn.C:(.text+0x404): undefined reference to `glutSwapBuffers'
jenn.o: In function `mouse(int, int, int, int)':
jenn.C:(.text+0x6da): undefined reference to `glutSetWindowTitle'
jenn.o: In function `drift()':
jenn.C:(.text+0x7e5): undefined reference to `glutPostRedisplay'
jenn.o: In function `keyboard(unsigned char, int, int)':
jenn.C:(.text+0x862): undefined reference to `glutSetWindowTitle'
jenn.o: In function `special_keys(int, int, int)':
jenn.C:(.text+0x8c6): undefined reference to `glutSetWindowTitle'
jenn.o: In function `control_display()':
jenn.C:(.text+0x8da): undefined reference to `glClear'
jenn.o: In function `GlutManager::GlutManager(int*, char**)':
jenn.C:(.text+0xad2): undefined reference to `glutInit'
jenn.C:(.text+0xade): undefined reference to `glutInitDisplayMode'
jenn.C:(.text+0xaf2): undefined reference to `glutInitWindowSize'
jenn.C:(.text+0xb1f): undefined reference to `glutInitWindowPosition'
jenn.C:(.text+0xb2c): undefined reference to `glutCreateWindow'
jenn.C:(.text+0xb44): undefined reference to `glutSetWindowTitle'
jenn.C:(.text+0xb50): undefined reference to `glutGameModeString'
jenn.C:(.text+0xb5f): undefined reference to `glutMainLoop'
jenn.o: In function `GlutManager::init_callbacks()':
jenn.C:(.text+0xb74): undefined reference to `glutDisplayFunc'
jenn.C:(.text+0xb80): undefined reference to `glutReshapeFunc'
jenn.C:(.text+0xb8c): undefined reference to `glutMouseFunc'
jenn.C:(.text+0xb98): undefined reference to `glutKeyboardFunc'
jenn.C:(.text+0xba4): undefined reference to `glutSpecialFunc'
jenn.C:(.text+0xbb0): undefined reference to `glutMotionFunc'
jenn.C:(.text+0xbbc): undefined reference to `glutIdleFunc'
jenn.C:(.text+0xbe4): undefined reference to `glClearColor'
jenn.C:(.text+0xbf0): undefined reference to `glShadeModel'
jenn.C:(.text+0xbfc): undefined reference to `glEnable'
jenn.C:(.text+0xc10): undefined reference to `glHint'
jenn.C:(.text+0xc1c): undefined reference to `glEnable'
jenn.C:(.text+0xc30): undefined reference to `glBlendFunc'
jenn.o: In function `GlutManager::toggle_fullscreen()':
jenn.C:(.text+0xc44): undefined reference to `glutGameModeGet'
jenn.C:(.text+0xc52): undefined reference to `glutEnterGameMode'
jenn.C:(.text+0xc5e): undefined reference to `glutLeaveGameMode'
drawing.o: In function `Drawings::Drawing::display_vertex(int)':
drawing.C:(.text+0xf34): undefined reference to `glLineWidth'
drawing.C:(.text+0xf3f): undefined reference to `glColor4fv'
drawing.C:(.text+0xf4b): undefined reference to `glBegin'
drawing.C:(.text+0xf5d): undefined reference to `glVertex2f'
drawing.C:(.text+0xf6f): undefined reference to `glVertex2f'
drawing.C:(.text+0xf74): undefined reference to `glEnd'
drawing.C:(.text+0xf87): undefined reference to `glLineWidth'
drawing.C:(.text+0xf92): undefined reference to `glColor4fv'
drawing.C:(.text+0xf9e): undefined reference to `glBegin'
drawing.C:(.text+0xfb0): undefined reference to `glVertex2f'
drawing.C:(.text+0xfc2): undefined reference to `glVertex2f'
drawing.C:(.text+0xfc7): undefined reference to `glEnd'
drawing.C:(.text+0xfd2): undefined reference to `glLineWidth'
drawing.C:(.text+0xfdd): undefined reference to `glColor4fv'
drawing.C:(.text+0xfe9): undefined reference to `glBegin'
drawing.C:(.text+0xffb): undefined reference to `glVertex2f'
drawing.C:(.text+0x100d): undefined reference to `glVertex2f'
drawing.C:(.text+0x1012): undefined reference to `glEnd'
drawing.C:(.text+0x1100): undefined reference to `glLineWidth'
drawing.C:(.text+0x110b): undefined reference to `glColor4fv'
drawing.C:(.text+0x111f): undefined reference to `glPolygonMode'
drawing.C:(.text+0x112b): undefined reference to `glBegin'
drawing.C:(.text+0x1159): undefined reference to `glVertex2f'
drawing.C:(.text+0x116d): undefined reference to `glEnd'
drawing.C:(.text+0x117a): undefined reference to `glLineWidth'
drawing.C:(.text+0x1185): undefined reference to `glColor4fv'
drawing.C:(.text+0x1199): undefined reference to `glPolygonMode'
drawing.C:(.text+0x11a5): undefined reference to `glBegin'
drawing.C:(.text+0x11d3): undefined reference to `glVertex2f'
drawing.C:(.text+0x11e7): undefined reference to `glEnd'
drawing.C:(.text+0x11f4): undefined reference to `glLineWidth'
drawing.C:(.text+0x11ff): undefined reference to `glColor4fv'
drawing.C:(.text+0x1213): undefined reference to `glPolygonMode'
drawing.C:(.text+0x121f): undefined reference to `glBegin'
drawing.C:(.text+0x124d): undefined reference to `glVertex2f'
drawing.C:(.text+0x1261): undefined reference to `glEnd'
drawing.C:(.text+0x1655): undefined reference to `glLineWidth'
drawing.C:(.text+0x1660): undefined reference to `glColor4fv'
drawing.C:(.text+0x166c): undefined reference to `glBegin'
drawing.C:(.text+0x167e): undefined reference to `glVertex2f'
drawing.C:(.text+0x1690): undefined reference to `glVertex2f'
drawing.C:(.text+0x1695): undefined reference to `glEnd'
drawing.C:(.text+0x16a8): undefined reference to `glLineWidth'
drawing.C:(.text+0x16b3): undefined reference to `glColor4fv'
drawing.C:(.text+0x16bf): undefined reference to `glBegin'
drawing.C:(.text+0x16d1): undefined reference to `glVertex2f'
drawing.C:(.text+0x16e3): undefined reference to `glVertex2f'
drawing.C:(.text+0x16e8): undefined reference to `glEnd'
drawing.C:(.text+0x16f3): undefined reference to `glLineWidth'
drawing.C:(.text+0x16fe): undefined reference to `glColor4fv'
drawing.C:(.text+0x170a): undefined reference to `glBegin'
drawing.C:(.text+0x171c): undefined reference to `glVertex2f'
drawing.C:(.text+0x172e): undefined reference to `glVertex2f'
drawing.C:(.text+0x1733): undefined reference to `glEnd'
collect2: ld 返回 1
make: *** [jenn] 错误 1
octopus@pc3:~/程序/jenngo$ make
g++ -I/sw/include -o jenn jenn.o linalg.o todd_coxeter.o go_game.o animation.o drawing.o definitions.o -lglut -lGLU -lGL
octopus@pc3:~/程序/jenngo$

3樓 巨大八爪鱼 2012-8-22 18:01
已编译好的程序下载地址:http://www.kuaipan.cn/file/id_2997500625556728.htm
4樓 巨大八爪鱼 2012-8-22 18:05
接下来我要编译:Johann
5樓 巨大八爪鱼 2012-8-22 18:10
octopus@pc3:~$ cd 程序/johann/
octopus@pc3:~/程序/johann$ make
g++ -Wall -ggdb -DDEBUG_LEVEL=2  -c -o main.o main.C
g++ -Wall -ggdb -o jmapper main.o -lglut -lGLU -lGL -lpng
./jmapper
Johann mapper. Copyright (C) 2007 Fritz Obermeyer. License: GLPv3
Usage: jmapper [map file name]
Controls:
  +/-    resize points
  SPACE  clear state
  s      clear state and show simplest labels
  c      toggle circle drawing
  a      toggle parsing of ALL points
  p      toggle printing style
loading map file default.map

    failed to open default.map
    main.C : 238
    void Map::load(const char*)
octopus@pc3:~/程序/johann$ ./jmapper
Johann mapper. Copyright (C) 2007 Fritz Obermeyer. License: GLPv3
Usage: jmapper [map file name]
Controls:
  +/-    resize points
  SPACE  clear state
  s      clear state and show simplest labels
  c      toggle circle drawing
  a      toggle parsing of ALL points
  p      toggle printing style
loading map file default.map

    failed to open default.map
    main.C : 238
    void Map::load(const char*)
octopus@pc3:~/程序/johann$

johann不需要修改源代码,可以直接在ubuntu下编译
6樓 巨大八爪鱼 2012-8-22 18:25
jenn系列的三个源码包中,最难编译的就是jenngo
7樓 巨大八爪鱼 2015-4-4 21:58
回復:6樓
jmapper是最容易編譯的
9樓 巨大八爪鱼 2015-6-16 20:31
回復:3樓
服务维护中 在此期间:


1. 已发布的快盘外链将暂时无法访问。
2. 快盘文件分享功能将暂时无法使用。

10樓 巨大八爪鱼 2015-6-16 20:32
編譯jenngo時,我修改了源代碼的很多地方。
11樓 巨大八爪鱼 2016-8-26 16:11
回復8樓 @張樹人 的內容:
其實編譯好的一般不能移植,因為是根據每個計算機的硬體進行編譯的。或者是已經做成portable包的。
错,只要安装好相应的依赖包,即使不重新编译,可执行文件也能直接运行。
例如,opengl程序编译好后重装系统,只需要重新安装freeglut就能再次运行,而且编译过程中用到的软件包无需安装。

回復帖子

內容:
用戶名: 您目前是匿名發表
驗證碼:
 
 
©2010-2024 Arslanbar [手機版] [桌面版]
除非另有聲明,本站採用創用CC姓名標示-相同方式分享 3.0 Unported許可協議進行許可。