grass-addons
grass-addons copied to clipboard
[Bug] Windows 7.8.6 C addons builds all fail
Name of the addon Many addons fail Windows builds fail, 157/342 failed when looking at the logs for GRASS c AddOns (x86_64) / MSYS_NT-10.0-14393 (logs generated Thu, 27 Jan 2022 11:21:53 +0100). For example, look at r.gwr
Describe the bug
Found in #690
Many Windows addons written in C builds fail for the 7.8.6 version, the one used by the majority of people. The failed builds mean they can't run to return the --html-description
, and then the manual pages aren't build in the zip downloaded.
It seems that the error is
C:/Users/landamar/grass_packager/grass786/addons/r.gwr/bin/r.gwr.exe: error while loading shared libraries: libgrass_raster.7.8.dll: cannot open shared object file: No such file or directory
To Reproduce Steps to reproduce the behavior:
- Go to https://wingrass.fsv.cvut.cz/grass78/x86_64/addons/grass-7.8.6/logs/
- Click on a failed plugin
- Look at the logs.
- See error
or else, try to install r.gwr on Windows like #690
Expected behavior Builds should be successful, with zip packages containing html documentations when installed with the g.extension on Windows.
Screenshots If applicable, add screenshots to help explain your problem.
See logs in https://wingrass.fsv.cvut.cz/grass78/x86_64/addons/grass-7.8.6/logs/, like https://wingrass.fsv.cvut.cz/grass78/x86_64/addons/grass-7.8.6/logs/r.gwr.log https://wingrass.fsv.cvut.cz/grass78/x86_64/addons/grass-7.8.6/logs/r.gwr.log
Log file https://wingrass.fsv.cvut.cz/grass78/x86_64/addons/grass-7.8.6/logs/r.gwr.log
``` mkdir -p /c/Users/landamar/grass_packager/grass786/addons/r.gwr/bin mkdir -p /c/Users/landamar/grass_packager/grass786/addons/r.gwr/etc mkdir -p /c/Users/landamar/grass_packager/grass786/addons/r.gwr/docs/html mkdir -p /c/Users/landamar/grass_packager/grass786/addons/r.gwr/docs/man mkdir -p /c/Users/landamar/grass_packager/grass786/addons/r.gwr/docs/man/man1 test -d OBJ.x86_64-w64-mingw32 || mkdir -p OBJ.x86_64-w64-mingw32 x86_64-w64-mingw32-gcc -I/c/osgeo4w/include -g -O2 -I/c/osgeo4w/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -D_FILE_OFFSET_BITS=64 -DPACKAGE=\""grassmods"\" -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -DRELDIR=\"/c/msys64/usr/src/grass7-addons/src/raster/r.gwr\" -o OBJ.x86_64-w64-mingw32/bufs.o -c bufs.c x86_64-w64-mingw32-gcc -I/c/osgeo4w/include -g -O2 -I/c/osgeo4w/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -D_FILE_OFFSET_BITS=64 -DPACKAGE=\""grassmods"\" -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -DRELDIR=\"/c/msys64/usr/src/grass7-addons/src/raster/r.gwr\" -o OBJ.x86_64-w64-mingw32/estimate_bw.o -c estimate_bw.c x86_64-w64-mingw32-gcc -I/c/osgeo4w/include -g -O2 -I/c/osgeo4w/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -D_FILE_OFFSET_BITS=64 -DPACKAGE=\""grassmods"\" -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -DRELDIR=\"/c/msys64/usr/src/grass7-addons/src/raster/r.gwr\" -o OBJ.x86_64-w64-mingw32/flag.o -c flag.c x86_64-w64-mingw32-gcc -I/c/osgeo4w/include -g -O2 -I/c/osgeo4w/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -D_FILE_OFFSET_BITS=64 -DPACKAGE=\""grassmods"\" -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -DRELDIR=\"/c/msys64/usr/src/grass7-addons/src/raster/r.gwr\" -o OBJ.x86_64-w64-mingw32/gwr.o -c gwr.c x86_64-w64-mingw32-gcc -I/c/osgeo4w/include -g -O2 -I/c/osgeo4w/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -D_FILE_OFFSET_BITS=64 -DPACKAGE=\""grassmods"\" -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -DRELDIR=\"/c/msys64/usr/src/grass7-addons/src/raster/r.gwr\" -o OBJ.x86_64-w64-mingw32/gwra.o -c gwra.c x86_64-w64-mingw32-gcc -I/c/osgeo4w/include -g -O2 -I/c/osgeo4w/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -D_FILE_OFFSET_BITS=64 -DPACKAGE=\""grassmods"\" -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -DRELDIR=\"/c/msys64/usr/src/grass7-addons/src/raster/r.gwr\" -o OBJ.x86_64-w64-mingw32/main.o -c main.c x86_64-w64-mingw32-gcc -I/c/osgeo4w/include -g -O2 -I/c/osgeo4w/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -D_FILE_OFFSET_BITS=64 -DPACKAGE=\""grassmods"\" -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -DRELDIR=\"/c/msys64/usr/src/grass7-addons/src/raster/r.gwr\" -o OBJ.x86_64-w64-mingw32/pavl.o -c pavl.c x86_64-w64-mingw32-gcc -I/c/osgeo4w/include -g -O2 -I/c/osgeo4w/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -D_FILE_OFFSET_BITS=64 -DPACKAGE=\""grassmods"\" -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -DRELDIR=\"/c/msys64/usr/src/grass7-addons/src/raster/r.gwr\" -o OBJ.x86_64-w64-mingw32/rclist.o -c rclist.c x86_64-w64-mingw32-gcc -I/c/osgeo4w/include -g -O2 -I/c/osgeo4w/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -D_FILE_OFFSET_BITS=64 -DPACKAGE=\""grassmods"\" -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -I/usr/src/grass786/dist.x86_64-w64-mingw32/include -DRELDIR=\"/c/msys64/usr/src/grass7-addons/src/raster/r.gwr\" -o OBJ.x86_64-w64-mingw32/weights.o -c weights.c make OBJ.x86_64-w64-mingw32/r.gwr.manifest.res && x86_64-w64-mingw32-gcc -L/usr/src/grass786/dist.x86_64-w64-mingw32/lib -L/usr/src/grass786/dist.x86_64-w64-mingw32/lib -Wl,--export-dynamic,--enable-runtime-pseudo-reloc -L/c/osgeo4w/lib -o /c/Users/landamar/grass_packager/grass786/addons/r.gwr/bin/r.gwr.exe OBJ.x86_64-w64-mingw32/bufs.o OBJ.x86_64-w64-mingw32/estimate_bw.o OBJ.x86_64-w64-mingw32/flag.o OBJ.x86_64-w64-mingw32/gwr.o OBJ.x86_64-w64-mingw32/gwra.o OBJ.x86_64-w64-mingw32/main.o OBJ.x86_64-w64-mingw32/pavl.o OBJ.x86_64-w64-mingw32/rclist.o OBJ.x86_64-w64-mingw32/weights.o /usr/src/grass786/dist.x86_64-w64-mingw32/lib/fmode.o OBJ.x86_64-w64-mingw32/r.gwr.manifest.res -lgrass_raster.7.8 -lgrass_segment.7.8 -lgrass_gis.7.8 -lintl -lgrass_gmath.7.8 make[1]: Entering directory '/c/msys64/usr/src/grass7-addons/src/raster/r.gwr' make[1]: Circular /c/msys64/usr/src/grass786/mswindows/generic.manifest.rc OBJ.x86_64-w64-mingw32/r.gwr.manifest.rc sed 's/@CMD@/r.gwr/' /c/msys64/usr/src/grass786/mswindows/generic.manifest > OBJ.x86_64-w64-mingw32/r.gwr.exe.manifest windres --input=OBJ.x86_64-w64-mingw32/r.gwr.manifest.rc --input-format=rc --output=OBJ.x86_64-w64-mingw32/r.gwr.manifest.res --output-format=coff -I/c/msys64/usr/src/grass786/mswindows rm OBJ.x86_64-w64-mingw32/r.gwr.exe.manifest OBJ.x86_64-w64-mingw32/r.gwr.manifest.rc make[1]: Leaving directory '/c/msys64/usr/src/grass7-addons/src/raster/r.gwr' C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: warning: --export-dynamic is not supported for PE+ targets, did you mean --export-all-symbols? if [ "/c/Users/landamar/grass_packager/grass786/addons/r.gwr/bin/r.gwr.exe" != "" ] ; then GISRC=/usr/src/grass786/dist.x86_64-w64-mingw32/demolocation/.grassrc78 GISBASE=C:/msys64/usr/src/grass786/dist.x86_64-w64-mingw32 PATH="/usr/src/grass786/dist.x86_64-w64-mingw32/bin:/usr/src/grass786/dist.x86_64-w64-mingw32/bin:/usr/src/grass786/dist.x86_64-w64-mingw32/scripts:$PATH" PYTHONPATH="C:/msys64/usr/src/grass786/dist.x86_64-w64-mingw32/etc/python;C:/msys64/usr/src/grass786/dist.x86_64-w64-mingw32/gui/wxpython;$PYTHONPATH" PATH="/c/Users/landamar/grass_packager/grass786/addons/r.gwr/bin:/usr/src/grass786/dist.x86_64-w64-mingw32/bin:/usr/src/grass786/dist.x86_64-w64-mingw32/scripts:/usr/src/grass786/dist.x86_64-w64-mingw32/lib:/usr/src/grass786/dist.x86_64-w64-mingw32/lib:/C/OSGeo4W/apps/Python39/Scripts:/C/OSGeo4W/bin:/C/Windows/system32:/C/Windows:/C/Windows/system32/WBem:/usr/bin:/mingw64/bin/:/c/Users/landamar/grass_packager/grass78/addons/mswindows/osgeo4w/lib:/c/Users/landamar/grass_packager/grass78/addons/mswindows/osgeo4w:/c/windows32/system32:/c/windows:/c/windows32/system32:/c/windows:/c/msys64/usr/bin:/c/msys64/mingw64/bin" LC_ALL=C LANG=C LANGUAGE=C /c/Users/landamar/grass_packager/grass786/addons/r.gwr/bin/r.gwr.exe --html-description \|' > r.gwr.tmp.html ; fi C:/Users/landamar/grass_packager/grass786/addons/r.gwr/bin/r.gwr.exe: error while loading shared libraries: libgrass_raster.7.8.dll: cannot open shared object file: No such file or directory make: *** [/c/msys64/usr/src/grass786/include/Make/Html.make:14: r.gwr.tmp.html] Error 1 rm r.gwr.tmp.html ```
System description (please complete the following information):
- Operating System: Windows
- GRASS GIS version 7.8.6
Additional context The logs in 7.8.dev, and the zips in 7.8.dev seem to show that builds are fine. https://wingrass.fsv.cvut.cz/grass78/x86_64/addons/grass-7.8.dev/ https://wingrass.fsv.cvut.cz/grass78/x86_64/addons/grass-7.8.dev/logs/
I am not sure if this is related, but if I install a python addons using g.extension, the bat file in the bin folder reads (for example):
@"%GRASS_PYTHON%" "%GRASS_ADDON_PATH%/scripts/r.clip.py" %*
The addon does not open. However, I can open the addon after I replace 'PATH' with 'BASE':
@"%GRASS_PYTHON%" "%GRASS_ADDON_BASE%/scripts/r.clip.py" %*
error while loading shared libraries: libgrass_gis.7.8.dll: >cannot open shared object file: No such file or directory make: ***
@landam any idea?
It seems that winGRASS compilation has some issue
Do we know where the code/setup for this WinGRASS architecture is set up, to take a look at the scripts/config?
Do we know where the code/setup for this WinGRASS architecture is set up, to take a look at the scripts/config?
Sure ;-) it's in the source:
https://github.com/OSGeo/grass/tree/releasebranch_7_8/mswindows/osgeo4w
I guess it's an issue with the build server and not with the code. @landam
@landam Could you please log on the build server, and make sure that the sources from 7.8.6 are still downloaded regularly from the tag?
Last time I tried to figure out what could've happened, I wasn't quite sure what to pinpoint, but I think that the branch releasebranch_7_8 is pulled, and built upon, making it 7.8.7-dev, instead of 7.8.6. So I think that what was backported to 7.8.6 doesn't come through. Maybe like a make clean or manual clean should be enough.
What's the real source of the error is that the linker option -Wl,--export-dynamic
now appears instead of -Wl,-export-dynamic
, which I think could've been ignored of some sort, and that option now breaks in MinGW builds?
There are a lot of hypotheses that I would need to verify in order to be able to tell you exactly what to do and check, but unfortunately, I can't explore the state inside of that build server.
For GRASS GIS 7.8.7, addons are now mostly available again: https://wingrass.fsv.cvut.cz/grass78/x86_64/addons/grass-7.8.7/logs/ Can this be closed @echoix ?
@ninsbl seems like it could! I don't have the chance to try and install one of them right now, but the original problem isn't there anymore.
Thanks, @echoix for the swift reply. Then I close this issue for now as fixed. Please feel free to open issues with specific modules that do not work.