Hello, I am trying to build ghostscript-9.27rc1 from: https://github.com/ArtifexSoftware/ghostpdl-downloads/releases/download/9.27rc1/ghostscript-9.27rc1.tar.g for Alpine Linux, via 'abuild'. During `make`, I faile with following. I have disabled options in configure including --with-jbig2dec: -Os -fomit-frame-pointer -Wall -Wstrict-prototypes -Wundef -Wmissing-declarations -Wmissing-prototypes -Wwrite-strings -fno-strict-aliasing -Werror=declaration-after-statement -fno-builtin -fno-common -Werror=return-type -DHAVE_STDINT_H=1 -DHAVE_DIRENT_H=1 -DHAVE_SYS_DIR_H=1 -DHAVE_SYS_TIME_H=1 -DHAVE_SYS_TIMES_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_LIBDL=1 -DGX_COLOR_INDEX_TYPE="unsigned long long" -D__USE_UNIX98=1 -Os -fomit-frame-pointer -g -DHAVE_RESTRICT=1 -fno-strict-aliasing -DHAVE_POPEN_PROTO=1 -I./soobj -I./base -I./devices -Isrc -o ./soobj/sjbig2.o -c ./base/sjbig2.c ./base/sjbig2.c: In function 's_jbig2decode_make_global_data': ./base/sjbig2.c:238:21: error: invalid use of void expression allocator = (s_jbig2decode_allocator_t *) jbig2_ctx_free(ctx); ^ ./base/sjbig2.c: In function 's_jbig2decode_free_global_data': ./base/sjbig2.c:257:17: error: invalid use of void expression allocator = (s_jbig2decode_allocator_t *) jbig2_global_ctx_free(global_ctx); ^ ./base/sjbig2.c: In function 's_jbig2decode_release': ./base/sjbig2.c:391:21: error: invalid use of void expression allocator = (s_jbig2decode_allocator_t *) jbig2_ctx_free(state->decode_ctx); ^ make[2]: *** [base/lib.mak:1780: soobj/sjbig2.o] Error 1 make[2]: *** Waiting for unfinished jobs.... make[2]: Leaving directory '/tmp/apk/src/ghostscript-9.27rc1' make[1]: *** [base/unix-dll.mak:281: so-only-subtarget] Error 2 make[1]: Leaving directory '/tmp/apk/src/ghostscript-9.27rc1' make: *** [base/unix-dll.mak:243: so] Error 2 >>> ERROR: ghostscript: build failed
Hi, I had the same error on the newly released 9.27 as well. Thanks
I had a hard time understanding your bug report. What I think you meant is: you are building ghostscript 9.27rc1 and later 9.27, not with the version of jbig2dec (0.16) in the source code tarball, but with the jbig2dec installed on your system (presumably 0.15). Can you please confirm this? By installing libjbig2dec 0.15 on my system, and then downloading the tarball, removing the jbig2dec subdirectory and attempting to build ghostscript with jbig2dec support... > tar xvf ghostscript-9.27.tar.gz && cd ghostscript-9.27 && rm -r jbig2dec && ./configure --with-jbig2dec && make -j10 I get error messages similar to yours. The issue is that ghostscript 9.27rc1 and 9.27 both depend on libjbig2dec 0.16. Do you mind updating to libjbig2dec 0.16 to confirm that I have understood the issue correctly?
The problem has been identified and a solution has been offered. Closing for the lack of response from the user.