Running gtest sample in AIX with xlC compiler

552 views
Skip to first unread message

holchu

unread,
Aug 24, 2011, 7:50:25 PM8/24/11
to Google C++ Testing Framework
hi,

I am trying to run gtest (gtest-1.6.0) in AIX platform. But getting
the following error in AIX platform.

Disabled the following and added -brtl in the make file. Sill getting
the error

#CXXFLAGS += -g -Wall -Wextra
#CXXFLAGS += -G
CXXFLAGS += -brtl


error:

ld: 0706-006 Cannot find or open library file: -l m
ld:open(): A file or directory in the path name does not
exist.
make: 1254-004 The error code from the last command is 255.



make all output:

bash-3.2# make clean
rm -f sample1_unittest gtest.a gtest_main.a *.o
bash-3.2# make all
xlC -I/opt/astests/gtest/gtest/gtest-1.6.0/include -brtl -c ../
samples/sample1.cc
xlC -I/opt/astests/gtest/gtest/gtest-1.6.0/include -brtl -c ../
samples/sample1_unittest.cc
xlC -I/opt/astests/gtest/gtest/gtest-1.6.0/include -I/opt/
astests/gtest/gtest/gtest-1.6.0 -brtl -c /opt/astests/gtest/gtest/
gtest-1.6.0/src/gtest-all.cc
xlC -I/opt/astests/gtest/gtest/gtest-1.6.0/include -I/opt/
astests/gtest/gtest/gtest-1.6.0 -brtl -c /opt/astests/gtest/gtest/
gtest-1.6.0/src/gtest_main.cc
ar -rv gtest_main.a
ar: Creating an archive file gtest_main.a.
xlC -I/opt/astests/gtest/gtest/gtest-1.6.0/include -brtl -
lpthread -o sample1_unittest
ld: 0706-006 Cannot find or open library file: -l m
ld:open(): A file or directory in the path name does not
exist.
make: 1254-004 The error code from the last command is 255.

Any help will be appreciated.

thanks.
S

Reply all
Reply to author
Forward
0 new messages