help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to build ATLAS libraries with mingw gfortran on cygwin


From: Benjamin Lindner
Subject: Re: How to build ATLAS libraries with mingw gfortran on cygwin
Date: Mon, 08 Jun 2009 15:47:14 +0200
User-agent: Thunderbird 2.0.0.18 (Windows/20081105)

Tatsuro MATSUOKA wrote:
Hello Benjamin

This is essentially the ATLAS issue but you have already solved this problem.

I have been so far used the ATLAS libraries built using the cygwin GCC-4 and 
used the libf77blas.a and
libatlas.a. This might be illegal because the cygwin complier is not compatible 
to Mingw one.
However no problem has been occurred in octave 3.0.x.

I wouldn't term it illegal and I think that the cygwin compiler is indeed compatible here, since you create a static library i.e. only object code. So you have to just make sure to use the same gcc version, since sytem libraries may be incompatible across different versions.

I have tried the same procedure on the octave 3.2.0, configure script reject to 
use the libf77blas.a
and libatlas.a generated by cygwin GCC-4.


Does it?
I seem to have no problems here.
What is the error message?

I have tried to build atlas libraries  -Si nocygwin 1.
However gcc-mingw on cygwin is still GCC-3.4.4 so that we cannot use for Mingw 
GCC-4 because gfortran
is not compatible to g77.

True, but I think I saw that there is a native gcc-4 available for cygwin installable via cygwin's setup.exe. I believe it's also a 4.3.x version.


To solve this, one has to use native GCC-4 Mingw compiler for ATLAS build on 
cygwin.

I have tried this but I cannot solved to translate cygwin path to windows path.

It will be grateful for me if you will give some suggestions to me.


Here is what I did.
I built myself a native cygwin gcc of version 4.3.0 and used it to build atlas.
The creation of the shared libraries I do with the native mingw gcc.
Building a cygwin gcc is straightforward,
1) download gcc-core-4.3.0.tar.bz2 and gcc-fortran-4.3.0.tar.bz2
2) configure and set a useful prefix to have a seprarate installation tree, and configure for gcc and gfortran only (that's all you need for atlas)
3) make && make install

Have a look at the attached quick-and-dirty script I used

This worked for me so far.
What's not considered here yet is a multi-threaded build.

benjamin

#!/usr/bin/sh

BUILDDIR=.build_cygwin_gcc-3.3.3

TOPDIR=`pwd`

SRCDIR=gcc-4.3.0

unpack()
{
   tar xjvf gcc-core-4.3.0.tar.bz2
   tar xjvf gcc-fortran-4.3.0.tar.bz2
}

mkdirs()
{
   rm -rf $BUILDDIR
   mkdir $BUILDDIR
}

conf()
{
   cd $BUILDDIR && ${TOPDIR}/${SRCDIR}/configure --srcdir=${TOPDIR}/${SRCDIR} \
        --prefix=/opt/gcc-4.3.0 \
        --with-cpu=i686 \
        --enable-languages=c,fortran \
        --enable-version-specific-runtime-libs \
        --disable-shared \
        --disable-nls
}

build()
{
   cd $BUILDDIR && make
}

install()
{
   cd $BUILDDIR && make install
}

$*

reply via email to

[Prev in Thread] Current Thread [Next in Thread]