Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: How do I compile an OCI program using make?
Senator Palpatine wrote:
> I know this topic must have been beaten to death but I am new to OCI
> and Oracle.
> I am converting programs using Sybase DBLIB to Oracle and need to know
> how to
> compile and link. I looked at all the makefiles and they are confusing
> as hell!
> Is there anyone that has a makefile that does a strainght compile and
> link without
> referencing all the other makefiles scattered all over the server?
>
> I have tried to use Pro*Sql to. Here is an example of a makefile I am
> using
> that uses the pre-compiler.
>
> empjob.o: empjob.pc
> $(PROC) $(CSCFLAGS) iname=empjob.pc
> $(CC) $(LDFLAGS) -c empjob.c -I. -I $(INCLUDE) -I $(PCCI)
> $(EXE)
>
> any help would be greatly appreciated.
>
> Thanks!
>
> DS
>
Use the demo_rdbms.mk found in the rdbms/demo directory.
A sample OCI file can be compiled and linked this way: make -f demo_rdbms.mk build EXE=yourexe OBJS=yourapp.o
Rgds.
Amogh
Received on Thu Apr 20 2006 - 23:58:30 CDT