Hi Adrian,
I hope all is well.
I had pretty much decimated my Cygwin 64 build but I didn't uninstall
it. I found it useful in Windows because its bash shell can change to
any directory in my system. Where as WSL is confined to local drives
(there may be a way to mount network drives but I'm still research it).
Anyway, while I put the latest antiprism on an up to date Cygwin 64 and
tried to make the static exe files for Cygwin. It all compiles without a
hitch except for of course glut, our familiar problem. I get the error
statements below.
From what I'm reading there, there is someone who has explained whey we
allways get the __imp (2 dashes) problem. If I understand this, it is
when the glut is compiled for Cygwin some microsoft tool adds another
underscore to its library names. He mentions what he think should work
but he never follows up on it. I think our former solution was to
compile our own glut, and I have throws that away. But it seems things
are very close for getting build just to work with built in libraries
for any who wants to do it.
https://stackoverflow.com/questions/18816323/cygwin-opengl-compiling-returns-undefined-references-to-imp-iob
What do you think?
Roger
make[2]: Entering directory '/home/Roger/antiprism_addons/aview'
/bin/sh ../libtool --tag=CXX --mode=link x86_64-w64-mingw32-g++ -W
-Wall -Wextra -static -static-libgcc -static-libstdc++ -Wl,-Bstatic
-lstdc++ -lpthread -g -O2 -o antiview.exe antiview-antiview.o
antiview-vw_glut.o
libantiprism_dispgl.la ../base/
libantiprism.la -lglut
-lwinmm -lgdi32 -lglu32 -lopengl32 -lm -lm -lm -lm -lm -lm
libtool: link: x86_64-w64-mingw32-g++ -W -Wall -Wextra -static-libgcc
-static-libstdc++ -Wl,-Bstatic -g -O2 -o antiview.exe
antiview-antiview.o antiview-vw_glut.o -lstdc++ -lpthread
./.libs/libantiprism_dispgl.a ../base/.libs/libantiprism.a -lglut
-lwinmm -lgdi32 -lglu32 -lopengl32
/usr/lib/gcc/x86_64-w64-mingw32/12/../../../../x86_64-w64-mingw32/bin/ld:
antiview-antiview.o: in function `glutInit_ATEXIT_HACK':
/usr/x86_64-w64-mingw32/sys-root/mingw/include/GL/freeglut_std.h:620:(.text.startup+0xd1):
undefined reference to `__imp___glutInitWithExit'
/usr/lib/gcc/x86_64-w64-mingw32/12/../../../../x86_64-w64-mingw32/bin/ld:
antiview-antiview.o: in function `main':
/home/Roger/antiprism_addons/aview/antiview.cc:213:(.text.startup+0xdc):
undefined reference to `__imp_glutInitDisplayMode'
/usr/lib/gcc/x86_64-w64-mingw32/12/../../../../x86_64-w64-mingw32/bin/ld:
antiview-antiview.o: in function `glutCreateWindow_ATEXIT_HACK':
/usr/x86_64-w64-mingw32/sys-root/mingw/include/GL/freeglut_std.h:622:(.text.startup+0xf4):
undefined reference to `__imp___glutCreateWindowWithExit'
/usr/lib/gcc/x86_64-w64-mingw32/12/../../../../x86_64-w64-mingw32/bin/ld:
antiview-antiview.o: in function `main':
/home/Roger/antiprism_addons/aview/antiview.cc:216:(.text.startup+0x106):
undefined reference to `__imp_glutInitWindowSize'
/usr/lib/gcc/x86_64-w64-mingw32/12/../../../../x86_64-w64-mingw32/bin/ld:
/home/Roger/antiprism_addons/aview/antiview.cc:217:(.text.startup+0x116):
undefined reference to `__imp_glutInitWindowPosition'
/usr/lib/gcc/x86_64-w64-mingw32/12/../../../../x86_64-w64-mingw32/bin/ld:
/home/Roger/antiprism_addons/aview/antiview.cc:220:(.text.startup+0x129):
undefined reference to `__imp_glutDisplayFunc'
/usr/lib/gcc/x86_64-w64-mingw32/12/../../../../x86_64-w64-mingw32/bin/ld:
/home/Roger/antiprism_addons/aview/antiview.cc:221:(.text.startup+0x136):
undefined reference to `__imp_glutIdleFunc'
/usr/lib/gcc/x86_64-w64-mingw32/12/../../../../x86_64-w64-mingw32/bin/ld:
/home/Roger/antiprism_addons/aview/antiview.cc:222:(.text.startup+0x143):
undefined reference to `__imp_glutReshapeFunc'
/usr/lib/gcc/x86_64-w64-mingw32/12/../../../../x86_64-w64-mingw32/bin/ld:
/home/Roger/antiprism_addons/aview/antiview.cc:223:(.text.startup+0x150):
undefined reference to `__imp_glutMouseFunc'
/usr/lib/gcc/x86_64-w64-mingw32/12/../../../../x86_64-w64-mingw32/bin/ld:
/home/Roger/antiprism_addons/aview/antiview.cc:224:(.text.startup+0x15d):
undefined reference to `__imp_glutKeyboardFunc'
/usr/lib/gcc/x86_64-w64-mingw32/12/../../../../x86_64-w64-mingw32/bin/ld:
/home/Roger/antiprism_addons/aview/antiview.cc:225:(.text.startup+0x16a):
undefined reference to `__imp_glutSpecialFunc'
/usr/lib/gcc/x86_64-w64-mingw32/12/../../../../x86_64-w64-mingw32/bin/ld:
/home/Roger/antiprism_addons/aview/antiview.cc:226:(.text.startup+0x177):
undefined reference to `__imp_glutMotionFunc'
/usr/lib/gcc/x86_64-w64-mingw32/12/../../../../x86_64-w64-mingw32/bin/ld:
/home/Roger/antiprism_addons/aview/antiview.cc:238:(.text.startup+0x4d1):
undefined reference to `__imp_glutMainLoop'
/usr/lib/gcc/x86_64-w64-mingw32/12/../../../../x86_64-w64-mingw32/bin/ld:
antiview-vw_glut.o: in function `glutCreateMenu_ATEXIT_HACK':
/usr/x86_64-w64-mingw32/sys-root/mingw/include/GL/freeglut_std.h:624:(.text+0x54b):
undefined reference to `__imp___glutCreateMenuWithExit'
/usr/lib/gcc/x86_64-w64-mingw32/12/../../../../x86_64-w64-mingw32/bin/ld:
antiview-vw_glut.o: in function `glut_state::make_menu()':
/home/Roger/antiprism_addons/aview/vw_glut.cc:43:(.text+0x55a):
undefined reference to `__imp_glutAddMenuEntry'
/usr/lib/gcc/x86_64-w64-mingw32/12/../../../../x86_64-w64-mingw32/bin/ld:
/home/Roger/antiprism_addons/aview/vw_glut.cc:61:(.text+0x653):
undefined reference to `__imp_glutAddSubMenu'
/usr/lib/gcc/x86_64-w64-mingw32/12/../../../../x86_64-w64-mingw32/bin/ld:
/home/Roger/antiprism_addons/aview/vw_glut.cc:64:(.text+0x685):
undefined reference to `__imp_glutAttachMenu'
/usr/lib/gcc/x86_64-w64-mingw32/12/../../../../x86_64-w64-mingw32/bin/ld:
antiview-vw_glut.o: in function `glut_idle_cb()':
/home/Roger/antiprism_addons/aview/vw_glut.cc:369:(.text+0x97d):
undefined reference to `__imp_glutPostRedisplay'
/usr/lib/gcc/x86_64-w64-mingw32/12/../../../../x86_64-w64-mingw32/bin/ld:
antiview-vw_glut.o: in function `display_cb()':
/home/Roger/antiprism_addons/aview/vw_glut.cc:395:(.text+0x9d6):
undefined reference to `__imp_glutSwapBuffers'
/usr/lib/gcc/x86_64-w64-mingw32/12/../../../../x86_64-w64-mingw32/bin/ld:
antiview-vw_glut.o: in function `reshape_cb(int, int)':
/home/Roger/antiprism_addons/aview/vw_glut.cc:414:(.text+0xabf):
undefined reference to `__imp_glutPostRedisplay'
/usr/lib/gcc/x86_64-w64-mingw32/12/../../../../x86_64-w64-mingw32/bin/ld:
antiview-vw_glut.o: in function `motion_cb(int, int)':
/home/Roger/antiprism_addons/aview/vw_glut.cc:358:(.text+0xc10):
undefined reference to `__imp_glutPostRedisplay'
/usr/lib/gcc/x86_64-w64-mingw32/12/../../../../x86_64-w64-mingw32/bin/ld:
antiview-vw_glut.o: in function `keyboard_cb(unsigned char, int, int)':
/home/Roger/antiprism_addons/aview/vw_glut.cc:287:(.text+0x1623):
undefined reference to `__imp_glutPostRedisplay'
collect2: error: ld returned 1 exit status
make[2]: *** [Makefile:511: antiview.exe] Error 1
make[2]: Leaving directory '/home/Roger/antiprism_addons/aview'
make[1]: *** [Makefile:512: all-recursive] Error 1
make[1]: Leaving directory '/home/Roger/antiprism_addons'
make: *** [Makefile:419: all] Error 2