Hi, Trying to emerge zygrib on a rather clean computer (new disk), I got the following error: .../bin/ld: cannot find -ljasper Emerging "media-libs/jasper" (1.900.6, current stable) before emerging "zygrib-8.0.1" fixes this issue. Thanks for your appreciated work ! Best regards, po valles
Thanks for your report. jpeg2000-Support is disabled in this version. Do you have a build log? I want to understand, why it failed for you. How does the "DEFS=" Variable look like after it failed in your build directory in "src/g2clib/makefile"? TIA
$ sudo emerge -C jasper * This action can remove important packages! In order to be safer, use * `emerge -pv --depclean <atom>` to check for reverse dependencies before * removing packages. media-libs/jasper selected: 1.900.6 protected: none omitted: none All selected packages: =media-libs/jasper-1.900.6 >>> 'Selected' packages are slated for removal. >>> 'Protected' and 'omitted' packages will not be removed. >>> Waiting 5 seconds before starting... >>> (Control-C to abort)... >>> Unmerging in: 5 4 3 2 1 >>> Unmerging (1 of 1) media-libs/jasper-1.900.6... >>> needed sym /usr/lib64/libjasper.so.1 >>> needed obj /usr/lib64/libjasper.so.1.0.0 * GNU info directory index is up-to-date. !!! existing preserved libs: >>> package: media-libs/jasper-1.900.6 * - /usr/lib64/libjasper.so.1 * - /usr/lib64/libjasper.so.1.0.0 * used by /opt/zyGrib/bin/zyGrib (app-misc/zygrib-8.0.1) * used by /usr/lib64/gimp/2.0/plug-ins/file-jp2-load (media-gfx/gimp-2.8.14-r2) * used by /usr/lib64/qt5/plugins/imageformats/libqjp2.so (dev-qt/qtimageformats-5.7.1) So it looks like zygrib is linked against "libjasper.so". Then sudo emerge -qv1 zygrib gives : [...] g++ -Wl,-O1 -O3 -o zyGrib objs/PositionEditorWidget.o objs/ColorEditorWidget.o objs/LineEditorWidget.o objs/TextStyleEditorWidget.o objs/AngleConverterWidget.o objs/AngleConverterDialog.o objs/BoatSpeed.o objs/CurveDrawer.o objs/CustomQwtClasses.o objs/Astro.o objs/MbzFile.o objs/MblueRecord.o objs/MblueReader.o objs/MbluePlot.o objs/BoardPanel.o objs/ColorScale.o objs/ColorScaleWidget.o objs/DataColors.o objs/DataQString.o objs/DataMeteoAbstract.o objs/DataPointInfo.o objs/DateChooser.o objs/DialogBoxColumn.o objs/DialogFonts.o objs/DialogGraphicsParams.o objs/DialogLoadGRIB.o objs/DialogLoadIAC.o objs/DialogLoadMBLUE.o objs/DialogProxy.o objs/DialogSelectMetar.o objs/DialogServerStatus.o objs/DialogUnits.o objs/FileLoaderGRIB.o objs/FileLoaderIAC.o objs/FileLoaderMBLUE.o objs/Font.o objs/GriddedPlotter.o objs/GriddedReader.o objs/GriddedRecord.o objs/GshhsRangsReader.o objs/GshhsReader.o objs/GribAnimator.o objs/GribPlot.o objs/Grib2Plot.o objs/GisReader.o objs/GribReader.o objs/Grib2Reader.o objs/GribRecord.o objs/Grib2Record.o objs/IacPlot.o objs/IacReader.o objs/IacReaderUtil.o objs/ImageWriter.o objs/IrregularGridded.o objs/IsoLine.o objs/LongTaskProgress.o objs/LonLatGrid.o objs/main.o objs/MainWindow.o objs/MapDrawer.o objs/MenuBar.o objs/Metar.o objs/MeteoTable.o objs/MeteoTableWidget.o objs/MeteotableOptionsDialog.o objs/Orthodromie.o objs/POI.o objs/POI_Editor.o objs/PositionEditor.o objs/Projection.o objs/Projection_libproj.o objs/Settings.o objs/SkewT.o objs/SkewTWindow.o objs/Terrain.o objs/Therm.o objs/Util.o objs/zuFile.o objs/moc_PositionEditorWidget.o objs/moc_ColorEditorWidget.o objs/moc_LineEditorWidget.o objs/moc_TextStyleEditorWidget.o objs/moc_AngleConverterWidget.o objs/moc_AngleConverterDialog.o objs/moc_CurveDrawer.o objs/moc_BoardPanel.o objs/moc_ColorScaleWidget.o objs/moc_DataQString.o objs/moc_DateChooser.o objs/moc_DialogBoxColumn.o objs/moc_DialogFonts.o objs/moc_DialogGraphicsParams.o objs/moc_DialogLoadGRIB.o objs/moc_DialogLoadIAC.o objs/moc_DialogLoadMBLUE.o objs/moc_DialogProxy.o objs/moc_DialogSelectMetar.o objs/moc_DialogServerStatus.o objs/moc_DialogUnits.o objs/moc_FileLoaderGRIB.o objs/moc_FileLoaderIAC.o objs/moc_FileLoaderMBLUE.o objs/moc_GribAnimator.o objs/moc_ImageWriter.o objs/moc_LongTaskProgress.o objs/moc_Metar.o objs/moc_MeteoTable.o objs/moc_MeteoTableWidget.o objs/moc_MeteotableOptionsDialog.o objs/moc_MainWindow.o objs/moc_MapDrawer.o objs/moc_MenuBar.o objs/moc_POI.o objs/moc_POI_Editor.o objs/moc_PositionEditor.o objs/moc_Projection.o objs/moc_SkewT.o objs/moc_Terrain.o objs/moc_Util.o -lbz2 -lz -lproj -lnova -lqwt6-qt5 -Lg2clib -lg2c -lpng -ljasper -L/usr/lib64 -lQt5PrintSupport -lQt5Widgets -lQt5Gui -lQt5Xml -lQt5Network -lQt5Core -lGL -lpthread /usr/lib/gcc/x86_64-pc-linux-gnu/4.9.4/../../../../x86_64-pc-linux-gnu/bin/ld: cannot find -ljasper collect2: error: ld returned 1 exit status Makefile:635: recipe for target 'zyGrib' failed make[1]: *** [zyGrib] Error 1 make[1]: Leaving directory '/var/tmp/portage/app-misc/zygrib-8.0.1/work/zyGrib-8.0.1/src' Makefile:37: recipe for target 'zyGrib' failed make: *** [zyGrib] Error 2 * ERROR: app-misc/zygrib-8.0.1::gentoo failed (compile phase): * emake failed * * If you need support, post the output of `emerge --info '=app-misc/zygrib-8.0.1::gentoo'`, * the complete build log and the output of `emerge -pqv '=app-misc/zygrib-8.0.1::gentoo'`. * The complete build log is located at '/var/tmp/portage/app-misc/zygrib-8.0.1/temp/build.log'. * The ebuild environment file is located at '/var/tmp/portage/app-misc/zygrib-8.0.1/temp/environment'. * Working directory: '/var/tmp/portage/app-misc/zygrib-8.0.1/work/zyGrib-8.0.1' * S: '/var/tmp/portage/app-misc/zygrib-8.0.1/work/zyGrib-8.0.1' The "DEFS" variable, as requested: $ grep -i '\(JPG2000\|JASPER\|^DEFS=\)' /var/tmp/portage/app-misc/zygrib-8.0.1/work/zyGrib-8.0.1/src/g2clib/makefile # -DUSE_JPEG2000 requires libjasper.a # ( and all the jasper/*.h include files). DEFS= -DUSE_PNG # can be found (jasper/*.h and png.h pngconf.h zconf.h zlib.h) In the following patch (/usr/portage/app-misc/zygrib/files/zygrib-8.0.1-libs.patch): --- src/zyGrib.pro.orig 2017-01-16 21:55:32.459388028 +0100 +++ src/zyGrib.pro 2017-01-16 22:17:18.509256966 +0100 @@ -8,7 +8,7 @@ TARGET = zyGrib DEPENDPATH += . util map GUI -INCLUDEPATH += . util map GUI curvedrawer qwt-6.1.3/src g2clib +INCLUDEPATH += . util map GUI curvedrawer /usr/include/qwt6 g2clib # ---------------------------------------------------- # platform specific @@ -35,7 +35,7 @@ } } -LIBS += -lbz2 -lz -lproj -lnova -Lqwt-6.1.3/lib/ -lqwt +LIBS += -lbz2 -lz -lproj -lnova -lqwt6-qt5 LIBS += -Lg2clib -lg2c -lpng -ljasper # respect order! # ---------------------------------------------------- we can see that the LIBS variable contains a reference to "jasper" lib. Hope it helps.
Ok, thank you. So its a bug in the build system of zygrib. I will first fix this so that jasper is not required anymore and maybe introduce a jpeg2k USE flag to enable jpeg2000 support.
Thanks again for the report! Should be fixed.