Ignore:
Timestamp:
Apr 14, 2009, 12:33:37 AM (13 years ago)
Author:
Peter
Message:

Removed dependency to cblas in libyat. There are three new make
variables: YAT_LIBS, YAT_LIBS_WITHOUT_CLAS and YAT_CBLAS_LIB.

  • The variable YAT_LIBS is created as follows: First the LIBS provided

by user is saved (most often empty). Then when detecting libs, they
are added to the variable LIBS and in the end of the configure run
YAT_LIBS is created as the difference between LIBS and the original
LIBS.

  • YAT_CLAS_LIB is detected as before.
  • YAT_LIBS_WITHOUT_CLAS is copied from YAT_LIBS but ignoring YAT_CLAS_LIB

I also changed the name of some variables to make the code clearer (I
hope). The prefix INTERNAL_ is used for flags that should only be used
when building yat and not needed for a user building against
yat. Flags that should be propagated have no prefix, for example,
CPPFLAGS.

In the end of configure these flags are used to create YAT_CPPFLAGS
using the same mechanism as when creating YAT_LIBS.

In the last step variables such as AM_CPPFLAGS is created as the
'union' of YAT_CPPFLAGS and INTERNAL_CPPFLAGS and these are propagated
to the Makefiles where they are used by Automake generated rules.

refs #518

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/build_support/yat-config.in

    r1857 r1892  
    3333LDFLAGS="@LDFLAGS@"
    3434LIBS="@LIBS@"
    35 EXTRA_CPPFLAGS="@EXTRA_CPPFLAGS@"
    36 EXTRA_CXXFLAGS="@EXTRA_CXXFLAGS@"
    37 EXTRA_LDFLAGS="@EXTRA_LDFLAGS@"
     35YAT_CPPFLAGS="@YAT_CPPFLAGS@"
     36YAT_CXXFLAGS="@YAT_CXXFLAGS@"
     37YAT_LDFLAGS="@YAT_LDFLAGS@"
     38YAT_LIBS="@YAT_LIBS@"
     39
     40# FIXME, this should honor environment variable
     41YAT_CBLAS_LIB=@YAT_CBLAS_LIB@
    3842
    3943LA_FILE="$libdir/lib@YAT_LIBNAME@.la"
     
    121125       flags="$flags -I@abs_top_srcdir@ -I@abs_top_builddir@"
    122126    fi
    123     flags="$flags $EXTRA_CPPFLAGS $CPPFLAGS"
     127    flags="$flags $YAT_CPPFLAGS $CPPFLAGS"
    124128    ;;
    125129    --cxxflags)
    126     flags="$flags $EXTRA_CXXFLAGS $CXXFLAGS"
     130    flags="$flags $YAT_CXXFLAGS $CXXFLAGS"
    127131    ;;
    128132    --libs)
    129     flags="$flags -l@YAT_LIBNAME@ $LIBS"
     133    flags="$flags -l@YAT_LIBNAME@ $YAT_LIBS $LIBS"
    130134    ;;
    131135    --ldflags)
     
    138142      flags="$flags -L$libdir"
    139143    fi
    140     flags="$flags $EXTRA_LDFLAGS $LDFLAGS"
     144    flags="$flags $YAT_LDFLAGS $LDFLAGS"
    141145    ;;
    142146    --link-libtool)
    143     flags="$flags $LA_FILE"
     147    flags="$flags $LA_FILE $YAT_CBLAS_LIB"
    144148    ;;
    145149    --atleast-version=*)
Note: See TracChangeset for help on using the changeset viewer.