Hi Arthur,
Look carefully at your configure.ac file or any scripts calling your
makefile. See if you find anyone setting CFLAGS, CPPFLAGS, etc on the
way in. They maybe adding -c (erroneously) to these variables.
To answer your question, the TEST macro should be completely independent
of the check programs being built - it merely specifies which
scripts/programs to run when tests are actually executed.
Regards,
John
On 3/12/2015 4:23 PM, Arthur Schwarz wrote:
Win7-64 bit
Cygwin 64-bit
g++ 4.9.2
I'm trying to link test program. The linker command option given to g++
during 'make check' says don't link. Any way around this?
check_PROGRAMS = test
test_INCLUDE = -I$(top_srcdir)/src
test_SOURCES = $(testCPP) $(testHead)
test_LDADD = libslip.a
'make check' contains:
g++ -std=gnu++11 -Wall -Wno-reorder -Wno-unused-value -Wno-address
-Wno-sequence-point -Wmaybe-uninitialized -c -g -o test.exe Test.o
TestErrors.o TestGlobal.o TestHeader.o TestIO.o TestMisc.o TestOperators.o
TestReader.o TestReplace.o TestSequencer.o TestUtilities.o libslip.a
which works when the -c option is removed.
g++ --help = -c Compile and assemble, but do not link
Is the linker command supposed to be given in a test script in the
Makefile.am file (TEST=script)?
The failure of the past is the challenge of the present and the success of
the future.