bugGNU Octave - Bugs: bug #55724, [MXE Octave] Ghostscript fails to...

 
 

bug #55724: [MXE Octave] Ghostscript fails to compile for native GNU/Linux

Submitter:  Markus Mützel <mmuetzel>
Submitted:  Sat 16 Feb 2019 08:32:00 PM UTC
   
 
Category:  None Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Build Failure
Status:  Fixed Assigned to:  None
Originator Name:  Open/Closed:  * Closed
Release:  * other Operating System:  * GNU/Linux
Fixed Release:  None Planned Release:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Jump to the original submission

Tue 26 Feb 2019 10:32:37 PM UTC, comment #28: 

Ok I create a new ticket and set you in CC list

Tatsuro MATSUOKA <tmacchant>
Tue 26 Feb 2019 10:13:52 PM UTC, comment #27: 

Can you attach the full log ? Although I guess really it should all be on a new ticket

John Donoghue <lostbard>
Group Member
Tue 26 Feb 2019 10:10:56 PM UTC, comment #26: 

I retried and got failure in build of qtbase.


[build]    qtbase

Failed to build package qtbase!
------------------------------------------------------------
    combine -libproxy with -qtnamespace when configuring Qt.
ERROR: Feature 'xcb' was enabled, but the pre-condition 'features.thread && features.xkbcommon && libs.xcb' failed.
/home/mousei7/work/octave/mxe-octave/linux/mxe-octave/Makefile:931: recipe for target 'build-only-qtbase' failed
make[2]: *** [build-only-qtbase] Error 3
make[2]: Leaving directory '/home/mousei7/work/octave/mxe-octave/linux/mxe-octave'
real    2m6.380s
user    1m53.068s
sys     0m11.572s
------------------------------------------------------------
[log]      /home/mousei7/work/octave/mxe-octave/linux/mxe-octave/log/qtb


*************


WARNING: Some of libproxy's plugins may use incompatible Qt versions.

    Some platforms and distributions ship libproxy with plugins, such
    as config_kde4.so, that are linked against old versions of Qt; and
    libproxy loads these plugins automatically when initialized. If Qt
    is not in a namespace, that loading causes a crash. Even if the
    systems on which you build and test have no such plugins, your
    users' systems may have them. We therefore recommend that you
    combine -libproxy with -qtnamespace when configuring Qt.

ERROR: Feature 'xcb' was enabled, but the pre-condition 'features.thread && features.xkbcommon && libs.xcb' failed.


Tatsuro MATSUOKA <tmacchant>
Mon 25 Feb 2019 07:23:06 PM UTC, comment #25: 

I pushed up a change that lets me compile native qtbase after the changes for ghostscript

https://hg.octave.org/mxe-octave/rev/46f4053aa6a3


John Donoghue <lostbard>
Group Member
Sun 24 Feb 2019 11:07:39 PM UTC, comment #24: 

John

Sorry my mistakes.

Tatsuro MATSUOKA <tmacchant>
Sun 24 Feb 2019 11:06:08 PM UTC, comment #23: 

./configure --enable-devel-tools --enable-octave=stable --enable-binary-packages --enable-64 --enable-fortran-int64 --enable-native-build --enable-pic-flag host_alias=gnu-linux --enable-openblas

Tatsuro MATSUOKA <tmacchant>
Sun 24 Feb 2019 10:46:08 PM UTC, comment #22: 

that would be a direct copy and paste, not a directory paste :)

John Donoghue <lostbard>
Group Member
Sun 24 Feb 2019 10:45:21 PM UTC, comment #21: 

@tatsuro, isthe configure part a directory copy and paste ? If so, its got some typos in it.

./configure --enabledevel-tools --enable-octave=stable \
 --enable-binary-packages \
 --enable-64 --enable-fortran-int64 --enable-native-build --enable-pic-flag hot_alias=gnu-linux --enable-openblas


hot_alias=gnu-linux hould be host_alias=gnu-linux

--enabledevel-tools should be --enable-devel-tools



Also, that looks like its compiling the old version of ghostscript (/home/mousei7/work/octave/mxe-octave/linux/mxe-octave/tmp-ghostscript/ghostscript-9.16), not v9.26 that is the current now in mxe.

John Donoghue <lostbard>
Group Member
Sun 24 Feb 2019 09:55:59 PM UTC, comment #20: 

I have tried mxe native build for linux and fails at build of ghostscript.


./configure --enabledevel-tools --enable-octave=stable \
 --enable-binary-packages \
 --enable-64 --enable-fortran-int64 --enable-native-build --enable-pic-flag hot_alias=gnu-linux --enable-openblas



[build]    ghostscript

Failed to build package ghostscript!
------------------------------------------------------------
base/jpeg.mak:375: recipe for target 'obj/jdmarker.o' failed
make[3]: *** [obj/jdmarker.o] Error 1
make[3]: Leaving directory '/home/mousei7/work/octave/mxe-octave/linux/mxe-octave/tmp-ghostscript/ghostscript-9.16'
/home/mousei7/work/octave/mxe-octave/linux/mxe-octave/Makefile:931: recipe for target 'build-only-ghostscript' failed
make[2]: *** [build-only-ghostscript] Error 2
make[2]: Leaving directory '/home/mousei7/work/octave/mxe-octave/linux/mxe-octave'
real    0m26.799s
user    0m19.568s
sys     0m2.148s
------------------------------------------------------------
[log]      /home/mousei7/work/octave/mxe-octave/linux/mxe-octave/log/ghostscript




gcc  -DHAVE_MKSTEMP -DHAVE_FILE64 -DHAVE_FSEEKO -DHAVE_MKSTEMP64 -DHAVE_FONTCONFIG  -DHAVE_SETLOCALE -DHAVE_SSE2  -DHAVE_BSWAP32 -DHAVE_BYTESWAP_H -DHAVE_STRERROR -DHAVE_PREAD_PWRITE=1 -DGS_RECURSIVE_MUTEXATTR=PTHREAD_MUTEX_RECURSIVE -O2 -I/home/mousei7/work/octave/mxe-octave/linux/mxe-octave/usr/include  -Wall -Wstrict-prototypes -Wundef -Wmissing-declarations -Wmissing-prototypes -Wwrite-strings -Wno-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 -DGX_COLOR_INDEX_TYPE="unsigned long int" -D__USE_UNIX98=1   -I/home/mousei7/work/octave/mxe-octave/linux/mxe-octave/usr/include   -I./obj -I./jpeg  -o ./obj/jdmarker.o -c ./obj/jdmarker.c
In file included from ./obj/jpeglib.h:1151:0,
                 from ./obj/jdmarker.c:18:
./obj/jdmarker.c: In function 'get_sos':
./obj/jdmarker.c:335:20: error: 'JERR_SOS_NO_SOF' undeclared (first use in this function)
     ERREXIT(cinfo, JERR_SOS_NO_SOF);
                    ^
/home/mousei7/work/octave/mxe-octave/linux/mxe-octave/usr/include/jerror.h:210:30: note: in definition of macro 'ERREXIT'
   ((cinfo)->err->msg_code = (code), \
                              ^
./obj/jdmarker.c:335:20: note: each undeclared identifier is reported only once for each function it appears in
     ERREXIT(cinfo, JERR_SOS_NO_SOF);
                    ^
/home/mousei7/work/octave/mxe-octave/linux/mxe-octave/usr/include/jerror.h:210:30: note: in definition of macro 'ERREXIT'
   ((cinfo)->err->msg_code = (code), \
                              ^
/home/mousei7/work/octave/mxe-octave/linux/mxe-octave/usr/include/jerror.h:210:35: warning: left-hand operand of comma expression has no effect [-Wunused-value]
   ((cinfo)->err->msg_code = (code), \
                                   ^
./obj/jdmarker.c:335:5: note: in expansion of macro 'ERREXIT'
     ERREXIT(cinfo, JERR_SOS_NO_SOF);
     ^
base/jpeg.mak:375: recipe for target 'obj/jdmarker.o' failed
make[3]: *** [obj/jdmarker.o] Error 1
make[3]: Leaving directory '/home/mousei7/work/octave/mxe-octave/linux/mxe-octave/tmp-ghostscript/ghostscript-9.16'
/home/mousei7/work/octave/mxe-octave/linux/mxe-octave/Makefile:931: recipe for target 'build-only-ghostscript' failed




Tatsuro MATSUOKA <tmacchant>
Sun 24 Feb 2019 06:10:42 PM UTC, comment #19: 

yeah - still doesnt looks right in qtbase, it should be setting PKG_CONFIG_LIBDIR to the combination of the mxe pkg config  path plus the one from the make.

Instead, for whatever reason, its setting both parts the same

ie: qtbase should be showing:

PKG_CONFIG_LIBDIR="/home/osboxes/Documents/Repositories/Octave/mxe-octave-native-1/usr/lib/pkgconfig:/usr/lib/x86_64-linux-gnu/pkgconfig"




John Donoghue <lostbard>
Group Member
Sun 24 Feb 2019 04:34:37 PM UTC, comment #18: 

I kept your patch in (just removed duplicate quotes) and tried with:

make all 7z-dist JOBS=3 PKG_CONFIG_PATH=/usr/lib/x86_64-linux-gnu/pkgconfig


It is compiling qtbase right now, but the configure command doesn't look right:

cd '/home/osboxes/Documents/Repositories/Octave/mxe-octave-native-1/tmp-qtbase/qtbase-everywhere-src-5.12.1' &&  PKG_CONFIG="pkg-config" PKG_CONFIG_SYSROOT_DIR="/" PKG_CONFIG_LIBDIR="/usr/lib/x86_64-linux-gnu/pkgconfig:/usr/lib/x86_64-linux-gnu/pkgconfig" ./configure  -I '/home/osboxes/Documents/Repositories/Octave/mxe-octave-native-1/usr/include/freetype2' -I '/home/osboxes/Documents/Repositories/Octave/mxe-octave-native-1/usr/include' -I '/home/osboxes/Documents/Repositories/Octave/mxe-octave-native-1/usr/include/dbus-1.0' -I '/home/osboxes/Documents/Repositories/Octave/mxe-octave-native-1/usr/lib/dbus-1.0/include'  -L '/home/osboxes/Documents/Repositories/Octave/mxe-octave-native-1/usr/lib' -no-strip -opensource -c++std c++11 -confirm-license   -device-option PKG_CONFIG='pkg-config' -pkg-config -force-pkg-config -no-use-gold-linker -shared -prefix '/home/osboxes/Documents/Repositories/Octave/mxe-octave-native-1/usr' -hostprefix '/home/osboxes/Documents/Repositories/Octave/mxe-octave-native-1/usr' -opengl desktop -no-glib -accessibility -nomake examples -nomake tests  -system-sqlite -system-zlib -system-libpng -system-libjpeg -system-sqlite -fontconfig -system-freetype -system-pcre -system-doubleconversion -no-openssl -dbus-linked -libproxy -no-pch -v  -icu -qpa xcb -qt-xcb


Shouldn't PKG_CONFIG_LIBDIR point to the MXE Octave path as well?


Markus Mützel <mmuetzel>
Group administrator
Sun 24 Feb 2019 03:41:14 PM UTC, comment #17: 

ok thats expected at least - not sure why its repeating the new paths in the qtbase make file then.

what happens when running

make PKG_CONFIG_PATH=/usr/lib64/pkgconfig


(or whereever the system configs are)


John Donoghue <lostbard>
Group Member
Sun 24 Feb 2019 03:34:47 PM UTC, comment #16: 

They are both empty.

Markus Mützel <mmuetzel>
Group administrator
Sun 24 Feb 2019 03:14:03 PM UTC, comment #15: 

The 2nd one should be whatever the system has set for PKG_CONFIG_PATH before setting them in the makefile, so if you just run

echo $PKG_CONFIG_PATH

and


echo $PKG_CONFIG_LIBDIR


what does it display ?

John Donoghue <lostbard>
Group Member
Sun 24 Feb 2019 03:01:06 PM UTC, comment #14: 

Both variables seem to be set to the MXE path:

cd '/home/osboxes/Documents/Repositories/Octave/mxe-octave-native-1/tmp-qtbase/qtbase-everywhere-src-5.12.1' &&  PKG_CONFIG="pkg-config" PKG_CONFIG_SYSROOT_DIR="/" PKG_CONFIG_LIBDIR=""/home/osboxes/Documents/Repositories/Octave/mxe-octave-native-1/usr/lib/pkgconfig:/home/osboxes/Documents/Repositories/Octave/mxe-octave-native-1/usr/lib/pkgconfig"" ./configure  -I '/home/osboxes/Documents/Repositories/Octave/mxe-octave-native-1/usr/include/freetype2' -I '/home/osboxes/Documents/Repositories/Octave/mxe-octave-native-1/usr/include' -I '/home/osboxes/Documents/Repositories/Octave/mxe-octave-native-1/usr/include/dbus-1.0' -I '/home/osboxes/Documents/Repositories/Octave/mxe-octave-native-1/usr/lib/dbus-1.0/include'  -L '/home/osboxes/Documents/Repositories/Octave/mxe-octave-native-1/usr/lib' -no-strip -opensource -c++std c++11 -confirm-license   -device-option PKG_CONFIG='pkg-config' -pkg-config -force-pkg-config -no-use-gold-linker -shared -prefix '/home/osboxes/Documents/Repositories/Octave/mxe-octave-native-1/usr' -hostprefix '/home/osboxes/Documents/Repositories/Octave/mxe-octave-native-1/usr' -opengl desktop -no-glib -accessibility -nomake examples -nomake tests  -system-sqlite -system-zlib -system-libpng -system-libjpeg -system-sqlite -fontconfig -system-freetype -system-pcre -system-doubleconversion -no-openssl -dbus-linked -libproxy -no-pch -v  -icu -qpa xcb -qt-xcb


Markus Mützel <mmuetzel>
Group administrator
Sun 24 Feb 2019 02:20:37 PM UTC, comment #13: 

Something like this perhaps ? (untested)

(file #46347)

John Donoghue <lostbard>
Group Member
Sun 24 Feb 2019 02:14:41 PM UTC, comment #12: 

ok that makes sense.

When I tried, i had disabled system-xlibs.


From comment #9, I am pretty sure you are right.
We could pass the old PKG_CONFIG_PATH value to pkg config as well as the mxe paths if compiling native.

Theres a good chace that PKG_CONFIG_PATH isnt set however, but would allow at least setting it in order to compile

John Donoghue <lostbard>
Group Member
Sun 24 Feb 2019 01:54:42 PM UTC, comment #11: 

make xkbcommon fails with the following error in the log:

cd '/home/osboxes/Documents/Repositories/Octave/mxe-octave-native-1/tmp-xkbcommon/libxkbcommon-xkbcommon-0.8.3' && ./autogen.sh &&  '/home/osboxes/Documents/Repositories/Octave/mxe-octave-native-1/tmp-xkbcommon/libxkbcommon-xkbcommon-0.8.3/configure' CPPFLAGS='-I/home/osboxes/Documents/Repositories/Octave/mxe-octave-native-1/usr/include' LDFLAGS='-L/home/osboxes/Documents/Repositories/Octave/mxe-octave-native-1/usr/lib'  --prefix='/home/osboxes/Documents/Repositories/Octave/mxe-octave-native-1/usr' && true
autoreconf: Entering directory `.'
autoreconf: configure.ac: not using Gettext
autoreconf: running: aclocal -I m4 --force --warnings=all
configure.ac:44: error: must install xorg-macros 1.16 or later before running autoconf/autogen
configure.ac:44: the top level
autom4te: /home/osboxes/Documents/Repositories/Octave/mxe-octave-native-1/usr/bin/m4 failed with exit status: 1
aclocal: error: echo failed with exit status: 1
autoreconf: aclocal failed with exit status: 1
make[1]: *** [/home/osboxes/Documents/Repositories/Octave/mxe-octave-native-1/Makefile:935: build-only-xkbcommon] Error 1


I configured with:

./configure --enable-64 --enable-native-build --enable-octave=stable --enable-pic-flag host_alias=gnu-linux --with-pkg-dir=../mxe-octave-pkg --with-ccache --enable-openblas --enable-system-x11-libs


Markus Mützel <mmuetzel>
Group administrator
Sun 24 Feb 2019 01:24:17 PM UTC, comment #10: 

What happens if you do a make xkbcommon before make qtbase ?

John Donoghue <lostbard>
Group Member
Sat 23 Feb 2019 12:40:23 PM UTC, comment #9: 

The problem might be that MXE Octave's pkgconfig is used to query the configuration of xkbcommon. But that fails to provide the information for the host's xkbcommon.

Part of the log/qtbase file reads:

Checking for xkbcommon >= 0.5.0...
Trying source 0 (type pkgConfig) of library xkbcommon ...
+ pkg-config --exists --silence-errors xkbcommon '>=' 0.5.0
pkg-config did not find package.
  => source produced no result.
test config.qtbase_gui.libraries.xkbcommon FAILED


I have "libxkbcommon-dev" installed.

Markus Mützel <mmuetzel>
Group administrator
Sat 23 Feb 2019 11:59:16 AM UTC, comment #8: 

ive seen that before - its missing xkbcommon or xcb, which care in mxe, but get installed if you enable the xlibs etc in configure. Otherwise you need to have them installed as dev packages in your main system.

John Donoghue <lostbard>
Group Member
Sat 23 Feb 2019 11:35:12 AM UTC, comment #7: 

I re-ran a clean native build for stable Octave and the ghostscript target compiled successfully.
The build stopped at the configure step for qtbase with this error:

ERROR: Feature 'xcb' was enabled, but the pre-condition 'features.thread && features.xkbcommon && libs.xcb' failed.


This is a different issue however.

Closing this report as fixed.

Markus Mützel <mmuetzel>
Group administrator
Thu 21 Feb 2019 10:17:26 PM UTC, comment #6: 

Pushed https://hg.octave.org/mxe-octave/rev/506a61f959e4

I then updated a couple with a single autoreconf call rather than using aclocal && automake --add-missing - works for me, so hopefully still works for native builds

John Donoghue <lostbard>
Group Member
Thu 21 Feb 2019 06:11:17 PM UTC, comment #5: 

The attached patch (replacing any of the previous patches) should fix compiling a couple more packages with the newer automake.
It is failing for of-general that doesn't compile with the current default Octave.
I haven't tried a stable or any native build.


(file #46327)

Markus Mützel <mmuetzel>
Group administrator
Wed 20 Feb 2019 09:14:59 PM UTC, comment #4: 

jasper also fails for me, but am trying an update to it as well

John Donoghue <lostbard>
Group Member
Wed 20 Feb 2019 08:52:08 PM UTC, comment #3: 

cool - I also got it working with an updated glpk, so maybe will use that if it all works

the new patch is the same as the previous one but with the added glpk change ?

John Donoghue <lostbard>
Group Member
Wed 20 Feb 2019 08:40:09 PM UTC, comment #2: 

Thanks for testing.
I haven't tested on a clean MXE Octave repo. Sorry for that.

With the attached patch glpk is compiling for me.
I am running a clean build with the patch now. I'll report if that succeeds or is stuck again.

(file #46318)

Markus Mützel <mmuetzel>
Group administrator
Wed 20 Feb 2019 07:24:42 PM UTC, comment #1: 

glpk fails for me after the automake update

John Donoghue <lostbard>
Group Member
Sat 16 Feb 2019 08:32:00 PM UTC, original submission:  

Native builds with MXE Octave fail for Ghostscript.

The attached patch updates Ghostscript to version 9.26. It is heavily borrowed from mxe.cc. It builds native on Linux and cross-builds for Windows.

It's also necessary to update libidn and automake. If you prefer, I can split these updates into separate changesets.

Markus Mützel <mmuetzel>
Group administrator

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

Attached Files
file #46347:  qtbase-pkg.patch added by lostbard (1KiB - text/x-patch)
file #46327:  ghostscript_926_v3.patch added by mmuetzel (88KiB - application/octet-stream)
file #46318:  ghostscript_926_v2.patch added by mmuetzel (86KiB - application/octet-stream)
file #46284:  ghostscript_926.patch added by mmuetzel (86KiB - application/octet-stream)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by tmacchant (Posted a comment)
  • -email is unavailable- added by lostbard (Posted a comment)
  • -email is unavailable- added by mmuetzel (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only group members can vote.

     

    Follow 6 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2019-02-24 lostbard Attached File- Added qtbase-pkg.patch, #46347
    2019-02-23 mmuetzel StatusNone Fixed
        Open/ClosedOpen Closed
    2019-02-21 mmuetzel Attached File- Added ghostscript_926_v3.patch, #46327
    2019-02-20 mmuetzel Attached File- Added ghostscript_926_v2.patch, #46318
    2019-02-16 mmuetzel Attached File- Added ghostscript_926.patch, #46284

    Back to the top

    Powered by Savane 3.13-758e.
    Corresponding source code