Changeset 84c376 in git


Ignore:
Timestamp:
May 4, 2011, 8:10:55 PM (12 years ago)
Author:
Oleksandr Motsak <motsak@…>
Branches:
(u'jengelh-datetime', 'ceac47cbc86fe4a15902392bdbb9bd2ae0ea02c6')(u'spielwiese', '0604212ebb110535022efecad887940825b97c3f')
Children:
e25a9942ffbe09b3e9cd1348617f1c1886c896bd
Parents:
2271fcf77152d68ee4d4f31ac7125d4183f54bcf
git-author:
Oleksandr Motsak <motsak@mathematik.uni-kl.de>2011-05-04 20:10:55+02:00
git-committer:
Mohamed Barakat <mohamed.barakat@rwth-aachen.de>2011-11-09 12:31:36+01:00
Message:
ADD: FreeBSD-related fixes in build system (no libdl, $^, $<)
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • libpolys/configure.ac

    r2271fcf r84c376  
    55AC_CONFIG_HEADER([config.h misc/auxiliary.h])
    66AM_INIT_AUTOMAKE
     7
     8dnl Check if build env is sane
     9AM_SANITY_CHECK
    710
    811LT_INIT(dlopen disable-static)
     
    2326AC_FUNC_VPRINTF
    2427AC_FUNC_MALLOC
    25 AC_CHECK_FUNC([vsnprintf], [AC_DEFINE([HAVE_VSNPRINTF], [1],
    26                                [Define if vsnprintf exists.])])
     28AC_CHECK_FUNC([vsnprintf], [AC_DEFINE([HAVE_VSNPRINTF], [1], [Define if vsnprintf exists.])])
    2729
    2830# Checks for header files.
    2931AC_HEADER_STDC
     32AC_STDC_HEADERS
    3033AC_CHECK_HEADERS([stdlib.h string.h unistd.h pwd.h sys/param.h limits.h float.h])
    3134
     
    4952esac
    5053
     54dnl INCLUDES=""
     55dnl dnl OS specific flags and options
     56dnl case "$host" in
     57dnl     *-*-freebsd*)
     58dnl         LIBS="$LIBS -L/usr/local/lib -lc"
     59dnl     CFLAGS="$CFLAGS -I/usr/local/include"
     60dnl     INCLUDES="$INCLUDES -I/usr/local/include"
     61dnl     ;;
     62dnl esac       
     63dnl AC_SUBST(INCLUDES)
     64
    5165SING_CHECK_P_PROCS
    5266
  • libpolys/tests/Makefile.am

    r2271fcf r84c376  
    2424
    2525
    26 if ENABLE_P_PROCS_DYNAMIC
    27   ### TODO -> ${LD_LIBS} ??? instead of -ldl,
    28   ### add it to AM_LDFLAGS?
    29   # '-ldl' wouldn't work on FreeBSD!!!???
    30   USEPPROCSDYNAMICLD = -ldl
    31   USEPPROCSDYNAMICLDFLAGS =  -rdynamic
    32 else
    33   USEPPROCSDYNAMICLD =
    34   USEPPROCSDYNAMICLDFLAGS =
    35 endif
    36 
    37 polys_test_LDFLAGS = ${AM_LDFLAGS} $(USEPPROCSDYNAMICLDFLAGS)
     26polys_test_LDFLAGS = ${AM_LDFLAGS} ${USEPPROCSDYNAMICLDFLAGS}
    3827rings_test_LDFLAGS = $(polys_test_LDFLAGS)
    3928
    4029coeffs_test_LDADD = -lcoeffs_g ${GMP_LIBS} -lresources_g -lreporter_g -lmisc_g -lomalloc_debug
    41 polys_test_LDADD = -lpolys_g $(USEPPROCSDYNAMICLD) $(coeffs_test_LDADD)
     30polys_test_LDADD = -lpolys_g ${USEPPROCSDYNAMICLD} $(coeffs_test_LDADD)
    4231rings_test_LDADD = $(polys_test_LDADD)
    4332
     
    4736
    4837
    49 # How to generate the test simple_test_runner
    50 ###### $^ needs GNU make : use gmake!
     38# How to generate *_runner.cpp
    5139simple_test_runner.cpp: simple_test.h
    52         ${srcdir}/cxxtestgen.pl --no-eh -o $@ --error-printer $^
     40        ${srcdir}/cxxtestgen.pl --no-eh -o $@ --error-printer simple_test.h
    5341
    5442coeffs_test_runner.cpp: coeffs_test.h
    55         ${srcdir}/cxxtestgen.pl --no-eh -o $@ --error-printer $^
     43        ${srcdir}/cxxtestgen.pl --no-eh -o $@ --error-printer coeffs_test.h
    5644
    5745polys_test_runner.cpp: polys_test.h
    58         ${srcdir}/cxxtestgen.pl --no-eh -o $@ --error-printer $^
     46        ${srcdir}/cxxtestgen.pl --no-eh -o $@ --error-printer polys_test.h
    5947
    6048rings_test_runner.cpp: rings_test.h
    61         ${srcdir}/cxxtestgen.pl --no-eh -o $@ --error-printer $^
     49        ${srcdir}/cxxtestgen.pl --no-eh -o $@ --error-printer rings_test.h
  • m4/p-procs.m4

    r2271fcf r84c376  
    2121AC_DEFUN([SING_CHECK_P_PROCS],
    2222[
     23USEPPROCSDYNAMICLDFLAGS=""
     24USEPPROCSDYNAMICLD=""   
     25
    2326AC_ARG_ENABLE(p-procs-static,
    2427[  --enable-p-procs-static Enable statically compiled p_Procs-modules
     
    4851    AC_MSG_ERROR([--enable-pprocs-dynamic requested but your system appears not to support dynamic modules properly])
    4952  fi
     53
     54  AC_CHECK_FUNC(dlopen,,[AC_CHECK_LIB(dl,dlopen,USEPPROCSDYNAMICLD="-ldl", [
     55   AC_MSG_WARN(Could not use dlopen)
     56  ]) ]) 
     57 
    5058elif test x$NO_P_PROCS_DYNAMIC_GIVEN = xyes -a x$NO_P_PROCS_STATIC_GIVEN = xyes; then
    5159  SING_SYSTEM_SUPPORTS_DYNAMIC_MODULES
     
    5462    ENABLE_P_PROCS_DYNAMIC="yes"
    5563    ENABLE_P_PROCS_STATIC="no"
     64    USEPPROCSDYNAMICLDFLAGS="-rdynamic"
     65    AC_CHECK_FUNC(dlopen,,[AC_CHECK_LIB(dl,dlopen,USEPPROCSDYNAMICLD="-ldl", [
     66      AC_MSG_WARN(Could not use dlopen)
     67    ]) ]) 
    5668  elif test $SUPPORTS_DYNAMIC_MODULES = no; then
    5769    AC_MSG_NOTICE([Enabling static modules and disabling dynamic modules])
     
    6779fi
    6880
     81AC_SUBST(USEPPROCSDYNAMICLDFLAGS)
     82AC_SUBST(USEPPROCSDYNAMICLD)
     83
    6984AM_CONDITIONAL([ENABLE_P_PROCS_DYNAMIC],[test x$ENABLE_P_PROCS_DYNAMIC = xyes])
    7085AM_CONDITIONAL([ENABLE_P_PROCS_STATIC],[test x$ENABLE_P_PROCS_STATIC = xyes])
Note: See TracChangeset for help on using the changeset viewer.