Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Expert guidance needed in understanding the part of a shell script

Status
Not open for further replies.

programmer400

Programmer
Nov 8, 2006
17
IN
Dear friends

I have been trying to run the demo programs from Systinet Server for C++ up and running on my HP-US box.
To run a demo , we need to compile the it first on Hp-UX and there is a ./configure script to be run. This configure.sh scrip while running gves an error at CXXFLAGS parameter which is the C++ flags variable that’s used by the configure script of the Systinet system. While running the ./configure script the erorr I m getting is
"error: CXXFLAGS used during compilation of SSC do not work. You are probably using different C++ compiler."

The part of a shell script which has the above error message is as below :
-----------------------------------------------------------
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
(eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } &&
{ ac_try='test -z "$ac_cxx_werror_flag"
|| test ! -s conftest.err'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
{ ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
:
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

{ { echo "$as_me:$LINENO: error: CXXFLAGS used during compilation of SSC do not work.
You are probably using different C++ compiler. The original flags
were: $WASP_CXXFLAGS" >&5
echo "$as_me: error: CXXFLAGS used during compilation of SSC do not work.
You are probably using different C++ compiler. The original flags
were: $WASP_CXXFLAGS" >&2;}
{ (exit 1); exit 1; }; }
fi
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu

---------------------------------------------------------
I did not understand properly the code part which throws the error.

I would be thankful for all the expert suggestion.
Thank you for your time.




 
I don't think you really need to understand the shell script so much as follow the recommendation in the error message; i.e. use the correct C++ compiler? The fact that it comes with a configure script leads me to believe that it is designed to be compiled with the GNU Compiler Collection (gcc). Do you have that installed? If not, try it...

Which C compiler are you using?

Annihilannic.
 
Annihilannic

Thanks for your reply.
We are using aCC compiler on our HP-UX machine.
We have not installed gcc compiler on HP-UX box.
If compiler is the problem then configure.sh needs to be modified accordlingly.

Thanks for your time
Amit
 
We cant install gcc compiler due to the requirement from senior manager so have to compile with aCC only.
The current version of aCC compiler installed on our HP-UX is
/orainst/rcsinbg1>what /opt/aCC/bin/aCC
/opt/aCC/bin/aCC:
HP aC++ B3910B A.03.37
HP aC++ B3910B A.03.30 Language Support Library
I executed the command as below on my HP-UX box
/export/home/amitbas/systinet/server_cpp65/share/doc/waspc/demos>./configur­e
CXX= /opt/aCC/bin/aCC CXXFLAGS="-g -O "

and Im posting the errors I have got
configure: WARNING: you should use --build, --host, --target


configure: WARNING: invalid host type: /opt/aCC/bin/aCC


checking for a BSD-compatible install... ./install-sh -c


checking whether build environment is sane... yes


checking for gawk... no


checking for mawk... no


checking for nawk... no


checking for awk... awk


checking whether make sets $(MAKE)... yes


checking for /opt/aCC/bin/aCC-gcc... no


checking for gcc... no


checking for /opt/aCC/bin/aCC-cc... no


checking for cc... cc


checking for C compiler default output file name... a.out


checking whether the C compiler works... yes


checking whether we are cross compiling... no


checking for suffix of executables...


checking for suffix of object files... o


checking whether we are using the GNU C compiler... no


checking whether cc accepts -g... yes


checking for cc option to accept ANSI C... none needed


checking for style of include used by make... GNU


checking dependency style of cc... hp


checking for /opt/aCC/bin/aCC-g++... no


checking for /opt/aCC/bin/aCC-c++... no


checking for /opt/aCC/bin/aCC-gpp... no


checking for /opt/aCC/bin/aCC-aCC... no


checking for /opt/aCC/bin/aCC-CC... no


checking for /opt/aCC/bin/aCC-cxx... no


checking for /opt/aCC/bin/aCC-cc++... no


checking for /opt/aCC/bin/aCC-cl... no


checking for /opt/aCC/bin/aCC-FCC... no


checking for /opt/aCC/bin/aCC-KCC... no


checking for /opt/aCC/bin/aCC-RCC... no


checking for /opt/aCC/bin/aCC-xlC_r... no


checking for /opt/aCC/bin/aCC-xlC... no


checking for g++... no


checking for c++... no


checking for gpp... no


checking for aCC... no


checking for CC... no


checking for cxx... no


checking for cc++... no


checking for cl... no


checking for FCC... no


checking for KCC... no


checking for RCC... no


checking for xlC_r... no


checking for xlC... no


checking whether we are using the GNU C++ compiler... no


checking whether g++ accepts -g... no


checking dependency style of g++... none


checking whether cc understands -c and -o together... yes


checking whether ln -s works... yes


checking how to run the C preprocessor... cc -E


checking for egrep... grep -E


checking for ANSI C header files... yes


checking for sys/types.h... yes


checking for sys/stat.h... yes


checking for stdlib.h... yes


checking for string.h... yes


checking for memory.h... yes


checking for strings.h... yes


checking for inttypes.h... yes


checking for stdint.h... no


checking for unistd.h... yes


checking for waspc-config...
/opt/systinet/server_cpp65/bin/waspc-config


configure: error: CXXFLAGS used during compilation of SSC do not work.


You are probably using different C++ compiler. The original
flags


were:


---------------------------------------------------------------------------­------------------------------------------------------
In spite of the location of aCC comiler for compiling >./configure CXX=
/opt/aCC/bin/aCC CXXFLAGS="-g -O "
we are still getting the errors ,
Thanks





 
Are you specifying

--build --host & --target?

configure: WARNING: you should use --build, --host, --target

Can you post the command your using to build

Mike

"Whenever I dwell for any length of time on my own shortcomings, they gradually begin to seem mild, harmless, rather engaging little things, not at all like the staring defects in other people's characters."
 
Thanks mrn, Annihilannic
I was able to compile it successfully :)
The command I gave was /export/home/amitbas/systinet/server_cpp65/share/doc/waspc/demos>./configure CXX= /opt/aCC/bin/aCC

I verified with the The log file: config.log entries are correct and configure exited with 0 status that’s success!
1381 configure: exit 0

Thank you mrn, Annihilannic for all your help and time.



 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top