Opened 9 years ago

Closed 5 years ago

#48281 closed defect (fixed)

py27-pygrib @1.9.9: ld: library not found for -lopenjpeg

Reported by: christopher.edwards@… Owned by: jswhit (Jeff Whitaker)
Priority: Normal Milestone:
Component: ports Version: 2.3.3
Keywords: Cc: tenomoto (Takeshi Enomoto)
Port: py27-pygrib

Description (last modified by ryandesign (Ryan Carsten Schmidt))

I have tried to install/build through Macports and src with no luck. Attached MACPORT Log.

Building version 2.0.0 Output:

python setup.py build
reading from setup.cfg...running build
running build_py
running build_ext
building 'pygrib' extension
cc -fno-strict-aliasing -fno-common -dynamic -arch x86_64 -arch i386 -g -Os -pipe -fno-common -fno-strict-aliasing -fwrapv -DENABLE_DTRACE -DMACOSX -DNDEBUG -Wall -Wstrict-prototypes -Wshorten-64-to-32 -DNDEBUG -g -fwrapv -Os -Wall -Wstrict-prototypes -DENABLE_DTRACE -arch x86_64 -arch i386 -pipe -I/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/numpy/core/include -I/opt/local/include -I/opt/local/include -I/opt/local/include/jasper -I/opt/local/include -I/usr/include -I/usr/include -Ig2clib_src -I/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7 -c pygrib.c -o build/temp.macosx-10.9-intel-2.7/pygrib.o
pygrib.c:12092:18: warning: assigning to 'char *' from 'const char *' discards qualifiers [-Wincompatible-pointer-types-discards-qualifiers]
    __pyx_v_name = grib_keys_iterator_get_name(__pyx_v_gi);
                 ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
pygrib.c:12502:18: warning: assigning to 'char *' from 'const char *' discards qualifiers [-Wincompatible-pointer-types-discards-qualifiers]
    __pyx_v_name = grib_keys_iterator_get_name(__pyx_v_gi);
                 ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
pygrib.c:16175:53: warning: passing 'void **' to parameter of type 'const void **' discards qualifiers in nested pointer types [-Wincompatible-pointer-types-discards-qualifiers]
  __pyx_v_err = grib_get_message(__pyx_v_self->_gh, (&__pyx_v_message), (&__pyx_v_size));
                                                    ^~~~~~~~~~~~~~~~~~
/opt/local/include/grib_api.h:562:51: note: passing argument to parameter 'message' here
int grib_get_message(grib_handle* h ,const void** message, size_t *message_length  );
                                                  ^
pygrib.c:35462:32: warning: unused function '__Pyx_PyUnicode_FromString' [-Wunused-function]
static CYTHON_INLINE PyObject* __Pyx_PyUnicode_FromString(const char* c_str) {
                               ^
pygrib.c:301:29: warning: unused function '__Pyx_Py_UNICODE_strlen' [-Wunused-function]
static CYTHON_INLINE size_t __Pyx_Py_UNICODE_strlen(const Py_UNICODE *u)
                            ^
pygrib.c:35577:33: warning: unused function '__Pyx_PyIndex_AsSsize_t' [-Wunused-function]
static CYTHON_INLINE Py_ssize_t __Pyx_PyIndex_AsSsize_t(PyObject* b) {
                                ^
pygrib.c:33784:28: warning: unused function '__Pyx_CyFunction_InitDefaults' [-Wunused-function]
static CYTHON_INLINE void *__Pyx_CyFunction_InitDefaults(PyObject *func, size_t size, int pyobjects) {
                           ^
pygrib.c:33793:27: warning: unused function '__Pyx_CyFunction_SetDefaultsTuple' [-Wunused-function]
static CYTHON_INLINE void __Pyx_CyFunction_SetDefaultsTuple(PyObject *func, PyObject *tuple) {
                          ^
pygrib.c:33798:27: warning: unused function '__Pyx_CyFunction_SetDefaultsKwDict' [-Wunused-function]
static CYTHON_INLINE void __Pyx_CyFunction_SetDefaultsKwDict(PyObject *func, PyObject *dict) {
                          ^
pygrib.c:33803:27: warning: unused function '__Pyx_CyFunction_SetAnnotationsDict' [-Wunused-function]
static CYTHON_INLINE void __Pyx_CyFunction_SetAnnotationsDict(PyObject *func, PyObject *dict) {
                          ^
pygrib.c:33901:27: warning: unused function '__Pyx_ErrFetch' [-Wunused-function]
static CYTHON_INLINE void __Pyx_ErrFetch(PyObject **type, PyObject **value, PyObject **tb) {
                          ^
pygrib.c:34412:32: warning: unused function '__Pyx_GetItemInt_List_Fast' [-Wunused-function]
static CYTHON_INLINE PyObject *__Pyx_GetItemInt_List_Fast(PyObject *o, Py_ssize_t i,
                               ^
pygrib.c:34426:32: warning: unused function '__Pyx_GetItemInt_Tuple_Fast' [-Wunused-function]
static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Tuple_Fast(PyObject *o, Py_ssize_t i,
                               ^
pygrib.c:34520:26: warning: unused function '__Pyx_PyUnicode_Equals' [-Wunused-function]
static CYTHON_INLINE int __Pyx_PyUnicode_Equals(PyObject* s1, PyObject* s2, int equals) {
                         ^
pygrib.c:35241:26: warning: function '__Pyx_PyInt_As_int' is not needed and will not be emitted [-Wunneeded-internal-declaration]
static CYTHON_INLINE int __Pyx_PyInt_As_int(PyObject *x) {
                         ^
15 warnings generated.
pygrib.c:12092:18: warning: assigning to 'char *' from 'const char *' discards qualifiers [-Wincompatible-pointer-types-discards-qualifiers]
    __pyx_v_name = grib_keys_iterator_get_name(__pyx_v_gi);
                 ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
pygrib.c:12502:18: warning: assigning to 'char *' from 'const char *' discards qualifiers [-Wincompatible-pointer-types-discards-qualifiers]
    __pyx_v_name = grib_keys_iterator_get_name(__pyx_v_gi);
                 ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
pygrib.c:16175:53: warning: passing 'void **' to parameter of type 'const void **' discards qualifiers in nested pointer types [-Wincompatible-pointer-types-discards-qualifiers]
  __pyx_v_err = grib_get_message(__pyx_v_self->_gh, (&__pyx_v_message), (&__pyx_v_size));
                                                    ^~~~~~~~~~~~~~~~~~
/opt/local/include/grib_api.h:562:51: note: passing argument to parameter 'message' here
int grib_get_message(grib_handle* h ,const void** message, size_t *message_length  );
                                                  ^
pygrib.c:35462:32: warning: unused function '__Pyx_PyUnicode_FromString' [-Wunused-function]
static CYTHON_INLINE PyObject* __Pyx_PyUnicode_FromString(const char* c_str) {
                               ^
pygrib.c:301:29: warning: unused function '__Pyx_Py_UNICODE_strlen' [-Wunused-function]
static CYTHON_INLINE size_t __Pyx_Py_UNICODE_strlen(const Py_UNICODE *u)
                            ^
pygrib.c:35577:33: warning: unused function '__Pyx_PyIndex_AsSsize_t' [-Wunused-function]
static CYTHON_INLINE Py_ssize_t __Pyx_PyIndex_AsSsize_t(PyObject* b) {
                                ^
pygrib.c:33784:28: warning: unused function '__Pyx_CyFunction_InitDefaults' [-Wunused-function]
static CYTHON_INLINE void *__Pyx_CyFunction_InitDefaults(PyObject *func, size_t size, int pyobjects) {
                           ^
pygrib.c:33793:27: warning: unused function '__Pyx_CyFunction_SetDefaultsTuple' [-Wunused-function]
static CYTHON_INLINE void __Pyx_CyFunction_SetDefaultsTuple(PyObject *func, PyObject *tuple) {
                          ^
pygrib.c:33798:27: warning: unused function '__Pyx_CyFunction_SetDefaultsKwDict' [-Wunused-function]
static CYTHON_INLINE void __Pyx_CyFunction_SetDefaultsKwDict(PyObject *func, PyObject *dict) {
                          ^
pygrib.c:33803:27: warning: unused function '__Pyx_CyFunction_SetAnnotationsDict' [-Wunused-function]
static CYTHON_INLINE void __Pyx_CyFunction_SetAnnotationsDict(PyObject *func, PyObject *dict) {
                          ^
pygrib.c:33901:27: warning: unused function '__Pyx_ErrFetch' [-Wunused-function]
static CYTHON_INLINE void __Pyx_ErrFetch(PyObject **type, PyObject **value, PyObject **tb) {
                          ^
pygrib.c:34412:32: warning: unused function '__Pyx_GetItemInt_List_Fast' [-Wunused-function]
static CYTHON_INLINE PyObject *__Pyx_GetItemInt_List_Fast(PyObject *o, Py_ssize_t i,
                               ^
pygrib.c:34426:32: warning: unused function '__Pyx_GetItemInt_Tuple_Fast' [-Wunused-function]
static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Tuple_Fast(PyObject *o, Py_ssize_t i,
                               ^
pygrib.c:34520:26: warning: unused function '__Pyx_PyUnicode_Equals' [-Wunused-function]
static CYTHON_INLINE int __Pyx_PyUnicode_Equals(PyObject* s1, PyObject* s2, int equals) {
                         ^
pygrib.c:35241:26: warning: function '__Pyx_PyInt_As_int' is not needed and will not be emitted [-Wunneeded-internal-declaration]
static CYTHON_INLINE int __Pyx_PyInt_As_int(PyObject *x) {
                         ^
15 warnings generated.
cc -bundle -undefined dynamic_lookup -arch x86_64 -arch i386 -Wl,-F. build/temp.macosx-10.9-intel-2.7/pygrib.o -L/opt/local/lib -L/opt/local/lib64 -L/opt/local/lib -L/opt/local/lib64 -L/opt/local/lib -L/opt/local/lib64 -L/usr/lib -L/usr/lib64 -L/usr/lib -L/usr/lib64 -L/opt/local/lib -L/opt/local/lib64 -L/opt/local/lib -L/opt/local/lib64 -L/opt/local/lib -L/opt/local/lib64 -L/usr/lib -L/usr/lib64 -L/usr/lib -L/usr/lib64 -lgrib_api -ljasper -lopenjpeg -lpng -lz -o build/lib.macosx-10.9-intel-2.7/pygrib.so
ld: warning: directory not found for option '-L/opt/local/lib64'
ld: warning: directory not found for option '-L/opt/local/lib64'
ld: warning: directory not found for option '-L/opt/local/lib64'
ld: warning: directory not found for option '-L/usr/lib64'
ld: warning: directory not found for option '-L/usr/lib64'
ld: warning: directory not found for option '-L/opt/local/lib64'
ld: warning: directory not found for option '-L/opt/local/lib64'
ld: warning: directory not found for option '-L/opt/local/lib64'
ld: warning: directory not found for option '-L/usr/lib64'
ld: warning: directory not found for option '-L/usr/lib64'
ld: library not found for -lopenjpeg
clang: error: linker command failed with exit code 1 (use -v to see invocation)
error: command 'cc' failed with exit status 1

Attachments (1)

main.log (75.3 KB) - added by christopher.edwards@… 9 years ago.

Download all attachments as: .zip

Change History (7)

Changed 9 years ago by christopher.edwards@…

Attachment: main.log added

comment:1 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)

Description: modified (diff)
Keywords: pygrib removed
Owner: changed from macports-tickets@… to jswhit@…
Port: py27-pygrib added
Summary: py27-pygrib @1.9.9 - Install failed: Processing of port py27-pygrib failedpy27-pygrib @1.9.9: ld: library not found for -lopenjpeg

Looks like maybe a dependency on port openjpeg15 is needed.

comment:2 Changed 9 years ago by christopher.edwards@…

Not sure if it matters but I also have version 1.13.1_3 of grib_api installed

port info grib_api
grib_api @1.13.1_3 (science)

Thanks for your help

Last edited 9 years ago by ryandesign (Ryan Carsten Schmidt) (previous) (diff)

comment:3 Changed 9 years ago by christopher.edwards@…

Also I have

port info openjpeg
openjpeg @2.1.0 (graphics)
Last edited 9 years ago by ryandesign (Ryan Carsten Schmidt) (previous) (diff)

comment:4 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)

Note that "port info" shows you what is available, not what is installed. If you want to know what's installed, use "port installed".

comment:5 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)

Cc: takeshi@… added

The grib_api port (on which the py-pygrib port depends) was changed in June to use openjpeg2 (libopenjp2) instead of openjpeg15 (libopenjpeg). py-pygrib might need a revbump to pick that up, or a patch or version update. However, see also #49096 in which it is proposed that grib_api might switch back to openjpeg15.

comment:6 Changed 5 years ago by reneeotten (Renee Otten)

Resolution: fixed
Status: newclosed

In 53ba3ac24b14bc57cca70e540baa13880b814da4/macports-ports (master):

py-pygrib: update to 2.0.4

  • remove py34 subport
  • add size to checksums
  • remove patch, included upstream
  • explicitly add library dependencies

Closes: #48281

Note: See TracTickets for help on using tickets.