Ticket #2295 (closed defect: fixed)

Opened 7 months ago

Last modified 3 months ago

hdf4 compiled with compression support fails during configure

Reported by: vincentschut Assigned to: dron
Priority: normal Milestone:
Component: ConfigBuild Version: unspecified
Severity: normal Keywords: hdf4
Cc: warmerdam

Description

when hdf4 has been compiled with szip and/or jpeg compression support, the config check always fails because it has no "-lsz -ljpeg" in the check.

Current workaround for me is to add a 'LDFLAGS="lsz -ljpeg"' before my ./configure command. But maybe the configure machinery should be revised?

Attachments

config.log (100.8 kB) - added by vincentschut on 03/28/08 06:32:23.
config.log

Change History

03/27/08 11:22:18 changed by dron

  • owner changed from warmerdam to dron.

Actually it does check with "-lsz -ljpeg", but I have implemented this several years ago and it is possible to be broken now for some reason. Your config.log with the failed check will help to fix this.

Best regards, Andrey

03/28/08 06:23:59 changed by vincentschut

It appears to check with -ljpeg, but not with -lsz (with -lz though, maybe you meant that?). Relevant part of config.log:

configure:21992: checking for SDreaddata in -lmfhdf configure:22027: gcc -o conftest -g -O2 conftest.c -lmfhdf -ldf -ljpeg -ltiff -lpng -lpq -L/usr/lib -lpq -lz -lm -lrt -ldl >&5 /usr/lib/libdf.a(cszip.o): In function `HCIcszip_term': cszip.c:(.text+0x2d7): undefined reference to `SZ_BufftoBuffCompress' /usr/lib/libdf.a(cszip.o): In function `HCPcszip_write': cszip.c:(.text+0x7b2): undefined reference to `SZ_encoder_enabled' cszip.c:(.text+0x7e1): undefined reference to `SZ_encoder_enabled' /usr/lib/libdf.a(cszip.o): In function `HCIcszip_decode': cszip.c:(.text+0xbd5): undefined reference to `SZ_BufftoBuffDecompress' /usr/lib/libdf.a(cszip.o): In function `HCIcszip_staccess': cszip.c:(.text+0x12a8): undefined reference to `SZ_encoder_enabled' /usr/lib/libdf.a(hcomp.o): In function `HCget_config_info': hcomp.c:(.text+0x1171): undefined reference to `SZ_encoder_enabled' collect2: ld returned 1 exit status configure:22033: $? = 1 configure: failed program was: | /* confdefs.h. */

If you think you need to see the entire config.log, please let me know.

03/28/08 06:28:01 changed by dron

Vincent,

I would like to see the full log. There is logic fo -lsz, but it does not work for some reason.

Best regards, Andrey

03/28/08 06:32:23 changed by vincentschut

  • attachment config.log added.

config.log

03/28/08 06:33:00 changed by vincentschut

Attached full log. Have fun :)

03/28/08 06:35:48 changed by dron

  • status changed from new to assigned.

Ok, I see where is the problem from the first line of log :-)

With --with-hdf4 switch supplied the mentioned logic does not work. I will implement more robust test today.

Best regards, Andrey

03/28/08 12:08:55 changed by dron

  • status changed from assigned to closed.
  • resolution set to fixed.

I have tried to fix it in r14099 in trunk.

Best regards, Andrey

04/08/08 16:07:24 changed by warmerdam

  • keywords set to hdf4.
  • component changed from default to ConfigBuild.
  • status changed from closed to reopened.
  • resolution deleted.

The r14099 patch appears to have caused problems. In particular, if hdf4 libraries are not available on the system, and no hdf switch is provided to configure, the hdf4 format will be enabled anyways.

I have temporarily modified configure so that hdf4 is only enabled if specifically requested instead of the default probe for it on the system in trunk (r14229).

04/09/08 08:01:39 changed by dron

  • status changed from reopened to closed.
  • resolution set to fixed.

Oops, mea culpa. I hope r14237 fixes it.

07/11/08 16:29:21 changed by warmerdam

  • cc set to warmerdam.

Found another problem (missing word "test") and hopefully fixed in r14891 in trunk.