libs/lapack: fixed windows mingw build
ClosedPublic

Authored by maxrd2 on Apr 3 2020, 7:12 PM.

Details

Reviewers
vonreth
Group Reviewers
Craft

Diff Detail

Repository
R877 Craft Blueprints for KDE
Branch
lapack
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 24767
Build 24785: arc lint + arc unit
maxrd2 requested review of this revision.Apr 3 2020, 7:12 PM
maxrd2 created this revision.
maxrd2 added inline comments.Apr 3 2020, 7:18 PM
libs/lapack/lapack.py
17

@vonreth Do you know why this isn't installing 7.3.0? Craft still installs 8.1.0-0 and linking fails with gfortran 8.1
https://github.com/Reference-LAPACK/lapack/issues/305
I have successfully built it with mingw 7.3.0 and 9.1.0, but 9.1.0 is still not available in craft.

I had to do craft --set version=7.3.0-0 mingw-w64 in order to downgrade mingw

Because mingw builds stopped providing builds.
I won't donwngrade mingw for some weird package.
Can we disable the fortran part?

And you setting the mingw Version there won't work. That is only assuring that at least that version is installed. >=.

maxrd2 updated this revision to Diff 79348.Apr 4 2020, 9:13 PM

Changed liblapack on windows builds to produce only static library (because libgfortran 8.1 in mingw provides only static lib and dll linking fails)
Fixed pocketsphinx/sphinxbase build to work against both static and dynamic liblapack and co.
Tested on windows mingw and linux.

maxrd2 updated this revision to Diff 79349.Apr 4 2020, 9:16 PM

Removed useless dependency to dev-utils/mingw-w64 on lapack

maxrd2 marked an inline comment as done.Apr 4 2020, 9:16 PM

I’d the fortran part used at all? Can we just disable it?

maxrd2 added a comment.EditedApr 4 2020, 10:00 PM

I’d the fortran part used at all? Can we just disable it?

Nope :(
Whole library is written in Fortran 90. It's linear algebra library (http://www.netlib.org/lapack/)

EDIT: There are other BLAS (and some LAPACK) implementations as listed here: https://www.wikiwand.com/en/Basic_Linear_Algebra_Subprograms#/Implementations
Will try to build pocketsphinx with those at some point.

Well if the patch works...
Else pls motivate the maintainers if mingw to provide a new binary release.

Well if the patch works...
Else pls motivate the maintainers if mingw to provide a new binary release.

Are you talking about these binary releases? https://sourceforge.net/projects/mingw-w64/files/mingw-w64/mingw-w64-release/
Will look into it... sure

I have a question tho... msys in craft already contains gcc 9.3.0 and latest mingw-gcc 32/64 binaries and environment.. is there a reason why those are not used?
Or maybe use those to compile mingw-w64 releases ourselves. I have cross compiled before qt5, kf5 and all dependencies needed for windows builds, don't think it's that hard to setup scripts to create windows toolchains etc.

Max@vs-win81 MINGW64_CRAFT /h/CraftMinGW
# pacman -Ss gcc
mingw32/mingw-w64-i686-gcc 9.3.0-1 (mingw-w64-i686-toolchain)
    GNU Compiler Collection (C,C++,OpenMP) for MinGW-w64
mingw32/mingw-w64-i686-gcc-ada 9.3.0-1 (mingw-w64-i686-toolchain)
    GNU Compiler Collection (Ada) for MinGW-w64
mingw32/mingw-w64-i686-gcc-fortran 9.3.0-1 (mingw-w64-i686-toolchain)
    GNU Compiler Collection (Fortran) for MinGW-w64
mingw32/mingw-w64-i686-gcc-libgfortran 9.3.0-1 (mingw-w64-i686-toolchain)
    GNU Compiler Collection (libgfortran) for MinGW-w64
mingw32/mingw-w64-i686-gcc-libs 9.3.0-1 (mingw-w64-i686-toolchain)
    GNU Compiler Collection (libraries) for MinGW-w64
mingw32/mingw-w64-i686-gcc-objc 9.3.0-1 (mingw-w64-i686-toolchain)
    GNU Compiler Collection (ObjC,Obj-C++) for MinGW-w64
mingw32/mingw-w64-i686-lcov 1.14-1
    front-end for GCC's coverage testing tool gcov
mingw32/mingw-w64-i686-perl 5.28.0-1
    A highly capable, feature-rich programming language (mingw-w64)
mingw64/mingw-w64-x86_64-gcc 9.3.0-1 (mingw-w64-x86_64-toolchain)
    GNU Compiler Collection (C,C++,OpenMP) for MinGW-w64
mingw64/mingw-w64-x86_64-gcc-ada 9.3.0-1 (mingw-w64-x86_64-toolchain)
    GNU Compiler Collection (Ada) for MinGW-w64
mingw64/mingw-w64-x86_64-gcc-fortran 9.3.0-1 (mingw-w64-x86_64-toolchain)
    GNU Compiler Collection (Fortran) for MinGW-w64
mingw64/mingw-w64-x86_64-gcc-libgfortran 9.3.0-1 (mingw-w64-x86_64-toolchain)
    GNU Compiler Collection (libgfortran) for MinGW-w64
mingw64/mingw-w64-x86_64-gcc-libs 9.3.0-1 (mingw-w64-x86_64-toolchain)
    GNU Compiler Collection (libraries) for MinGW-w64
mingw64/mingw-w64-x86_64-gcc-objc 9.3.0-1 (mingw-w64-x86_64-toolchain)
    GNU Compiler Collection (ObjC,Obj-C++) for MinGW-w64
mingw64/mingw-w64-x86_64-lcov 1.14-1
    front-end for GCC's coverage testing tool gcov
mingw64/mingw-w64-x86_64-perl 5.28.0-1
    A highly capable, feature-rich programming language (mingw-w64)
msys/gcc 9.3.0-1 (msys2-devel) [installed]
    The GNU Compiler Collection - C and C++ frontends
msys/gcc-fortran 9.3.0-1 (msys2-devel) [installed]
    Fortran front-end for GCC
msys/gcc-libs 9.3.0-1 (base) [installed]
    Runtime libraries shipped by GCC
msys/mingw-w64-cross-gcc 9.3.0-1 (mingw-w64-cross-toolchain mingw-w64-cross)
    Cross GCC for the MinGW-w64
vonreth accepted this revision.Sep 8 2020, 1:26 PM
This revision is now accepted and ready to land.Sep 8 2020, 1:26 PM