I am unable to compile the programs, I am able to compile .pc to .c but later part of the compilation from .c to executalbe i am unable to do.
Here is the way i am doing
make -f $LIB_LIB/makefile.templ sample
Code:
I am getting the following errors, which environment and where to set to point compiler to sqlca.h? please help.
ucbcc -O -DNULL=0 -v -o sample -L/opt/oracle/product/10.2.0/precomp/lib/ -L/opt/oracle/product/10.2.0/lib/ -o sample sample.c `cat /opt/oracle/product/10.2.0/lib/sysliblist` -R/opt/oracle/product/10.2.0/lib -laio -lposix4 -lm
### command line files and options (expanded):
### -xO3 -DNULL=0 -v -L/opt/oracle/product/10.2.0/precomp/lib/ -L/opt/oracle/product/10.2.0/lib/ -o sample sample.c -lkstat -lnsl -lsocket -lgen -ldl -lsched -R/opt/oracle/product/10.2.0/lib -laio -lposix4 -lm
### ucbcc: Note: NLSPATH = /opt/SUNWspro/prod/bin/../lib/locale/%L/LC_MESSAGES/%N.cat:/opt/SUNWspro/prod/bin/../../lib/locale/%L/LC_MESSAGES/%N.cat
/opt/SUNWspro/prod/bin/acomp -Qy -N /tmp/acomp.12653.2.ir -g "/opt/SUNWspro/prod/bin/acc -O -DNULL=0 -v -L/opt/oracle/product/10.2.0/precomp/lib/ -L/opt/oracle/product/10.2.0/lib/ -R/opt/oracle/product/10.2.0/lib -c" -b -Xa -D__SunOS_5_10 -D__SUNPRO_C=0x570 -Dunix -Dsun -Dsparc -D__unix -D__sun -D__sparc -D__BUILTIN_VA_ARG_INCR -D__SVR4 -D__RESTRICT -D__PRAGMA_REDEFINE_EXTNAME -I/opt/SUNWspro/prod/include/cc -O3 -DNULL=0 -destination_ir=iropt -i sample.c -o /tmp/acomp.12653.1.s -r /tmp/acomp.12653.0.ir
"sample.c", line 117: warning: no explicit type given
"sample.c", line 119: warning: no explicit type given
"sample.c", line 121: warning: no explicit type given
"sample.c", line 122: warning: no explicit type given
"sample.c", line 123: warning: no explicit type given
"sample.c", line 143: cannot find include file: <sqlca.h>
"sample.c", line 170: undefined symbol: sqlca
"sample.c", line 196: undefined struct/union member: sqlcode
"sample.c", line 196: warning: left operand of "." must be struct/union object
"sample.c", line 219: undefined symbol: sqlca
"sample.c", line 248: undefined struct/union member: sqlcode
"sample.c", line 248: warning: left operand of "." must be struct/union object
"sample.c", line 249: undefined struct/union member: sqlcode
"sample.c", line 249: warning: left operand of "." must be struct/union object
"sample.c", line 264: undefined symbol: sqlca
"sample.c", line 264: undefined struct/union member: sqlcode
"sample.c", line 264: warning: left operand of "." must be struct/union object
rm /tmp/acomp.12653.1.s
rm /tmp/acomp.12653.0.ir
*** Error code 2
make: Fatal error: Command failed for target `sample'
how do i go about compiling a simple hello world script in mandrake linux? this is something i have had no luck in finding on the main site, please help?
thank you (2 Replies)
Hi all,
Yeasterday I try to compile c program by using cygwin. I just find an errors the fist one is concerinig about the end of the line.
To summit my Assignment which is the day after tommorow I have to compile my c program by using just gcc.
If any one know what do I have to... (5 Replies)
Hi,
How to precompile the c program which has proc statements within it.
If it is only c, I will use the following cmd
cc filename.c -o output
so please tell me what command I have to use for precompilation.
I beleave that this is not an oracle or proc forum, but still I hope will... (1 Reply)
how can i do static compilation in cc and -lldap
i have system defined and user defined header file.
Can any one suggest any site where from i can get some information about static and dynamic compilation.
Thankx (1 Reply)
Hi,
My name is vreddy and I am learning c language now and written one programme on vi editor.
how do I compile the programme please give me some advice and that would be helpfull for me.
thanks
vre (10 Replies)
Hi ,
I have freeBSD installed. I need to compile a c program which has embedded informix sql statement in it.
Can you please help me to to do the same. I need to know what I should I do to make BSD compatable to compile the c program ?
Thanks in advance
Jisha (3 Replies)
I am trying to compile a c program on AIX 5.3L 64-bit unix.
I have used this program in the past and it works.
Does anybody know what this error means?
/usr/local/bin> gcc get_epoch_secs.c get_epoch_secs
gcc: get_epoch_secs: No such file or directory
get_epoch_secs.c: In function... (8 Replies)
Hello,
I use Omniworks build environment for compiling pro*c++(filename.pcc) files which would result in .filename.cc. I am not able get these files due some misplacement in environment... Could anyone explain the environment variable linked to it .. I know few like LIB_PATH,LD_LIBRARY_PATH and... (0 Replies)
Hi there,
I have written the shell script to illustrate arithmetic operations using case command as shown below:
#!/bin/bash
echo -n "Enter any two numbers :"
read a
read b
MENU="
Select any one option
1) Addition
2) Substraction
3) Multiplication
4) Division
5) Quit"
clear
$x=0;... (5 Replies)
Hi,
I having an issue while compiling a C program in USS (z/OS) machine.
I was able to create objest files (.o) from source (.c) files but when I try to create a binary file from the object files I am getting the below error.
$ cc util.o sock.o app.o -lnsl -o ptf
FSUM3067 The archive... (7 Replies)
Discussion started by: madhu84
7 Replies
LEARN ABOUT NETBSD
__builtin_constant_p
__BUILTIN_CONSTANT_P(3) BSD Library Functions Manual __BUILTIN_CONSTANT_P(3)NAME
__builtin_constant_p -- GNU extension to determine compile time constants
SYNOPSIS
int
__builtin_constant_p(value);
DESCRIPTION
The __builtin_constant_p() is a GNU extension for determining whether a value is known to be constant at compile time. The function is
closely related to the concept of ``constant folding'' used by modern optimizing compilers.
If the value is known to be a compile-time constant, a value 1 is returned. If __builtin_constant_p() returns 0, the value is not a compile-
time constant in the sense that gcc(1) was unable to determine whether the value is constant or not.
EXAMPLES
A typical example of the use of __builtin_constant_p() involves a situation where it may be desirable to fold the computation if it involves
a constant, but a function call is needed otherwise. For instance, bswap16(3) is defined in NetBSD as:
#define bswap16(x)
(__builtin_constant_p((x)) ?
__byte_swap_u16_constant(x) : __BYTE_SWAP_U16_VARIABLE(x))
SEE ALSO gcc(1), __builtin_object_size(3), __builtin_return_address(3)CAVEATS
This is a non-standard, compiler-specific extension.
BSD December 19, 2010 BSD