[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: configure: how to skip a test?
From: |
Grzegorz Jakacki |
Subject: |
Re: configure: how to skip a test? |
Date: |
Tue, 11 May 2004 08:28:46 +0800 (CST) |
On Mon, 10 May 2004, Andreas Schallenberg wrote:
> Hi!
>
> I'd like to use the autoconf/automake/configure tools
> for a project which uses SystemC. (http://www.systemc.org/)
> SystemC is a hardware description language based on
> C++ and comes with a simulation library which has
> the symbol "main" built-in.
>
> When I run configure a test is performed to determine
> if the C++ compiler can create executables. Since the
> test includes a source with its own main() the linker
> complains having multiple definitions of it.
Why does this test link against libsystemc.a ? It looks like you are
adding it to LIBS or LDFLAGS, right?
If so, don't do it. Instead write your own test to check for libsystemc.a.
Ideally you could use AC_CHECK_LIB([systemc],[main]). If that does not
work, just write this test by hand (generate file with empty sc_main(),
compile, link against -lsystemc).
Hope this helps.
Grzegorz
##################################################################
# Grzegorz Jakacki Huada Electronic Design #
# Senior Engineer, CAD Dept. 1 Gaojiayuan, Chaoyang #
# tel. +86-10-64365577 x2074 Beijing 100015, China #
# Copyright (C) 2004 Grzegorz Jakacki, HED. All Rights Reserved. #
##################################################################