Featured post

c# - Usage of Server Side Controls in MVC Frame work -

i using asp.net 4.0 , mvc 2.0 web application. project requiremrnt have use server side control in application not possibl in noraml case. ideally want use adrotator control , datalist control. i saw few samples , references in codepleax mvc controllib howwver found less useful. can tell how utilize theese controls in asp.net application along mvc. note: please provide functionalities related adrotator , datalist controls not equivalent functionalities thanks in advace. mvc pages not use normal .net solution makes use of normal .net components impossible. a normal .net page use event driven solution call different methods service side mvc use actions , view completly different way handle things. also, mvc not use viewstate normal .net controlls require. found article discussing mixing of normal .net , mvc.

c - Problems Compiling OCILIB OCI Wrapper Library -


i'm trying compile demo in ocilib3.8.1/demo. after installing ocilib library, compile demo source conn.c below :

#include "ocilib.h"  int main(void) {     oci_connection *cn;      if (!oci_initialize(null, null, oci_env_default))         return exit_failure;      cn = oci_connectioncreate("db", "usr", "pwd", oci_session_default);      printf("server major    version : %i\n",   oci_getservermajorversion(cn));     printf("server minor    version : %i\n",   oci_getserverminorversion(cn));     printf("server revision version : %i\n\n", oci_getserverrevisionversion(cn));     printf("connection      version : %i\n\n", oci_getversionconnection(cn));      oci_cleanup();      return exit_success; } 

compile using gcc :

$gcc -wall conn.c -o conn.o -i/usr/local/include \     -doci_import_linkage -doci_charset_ansi 

error :

$ gcc -wall conn.c -o conn.o -i/usr/local/include \     -doci_import_linkage -doci_charset_ansi /tmp/ccmgfqri.o: in function `main': conn.c:(.text+0x26): undefined reference `oci_initialize' conn.c:(.text+0x4f): undefined reference `oci_connectioncreate' conn.c:(.text+0x63): undefined reference `oci_getservermajorversion' conn.c:(.text+0x82): undefined reference `oci_getserverminorversion' conn.c:(.text+0xa1): undefined reference `oci_getserverrevisionversion' conn.c:(.text+0xc0): undefined reference `oci_getversionconnection' conn.c:(.text+0xd6): undefined reference `oci_cleanup' collect2: ld returned 1 exit status 

i'm using redhat el5, gcc version 3.4.6 20060404 (red hat 3.4.6-4), instant client release 10.2.0.5.0.

thanks help. i'm newbies in linux programming ..

you have link against ocilib !

add "-locilib" command line :)


Comments

Popular posts from this blog

c# - Usage of Server Side Controls in MVC Frame work -

cocoa - Nesting arrays into NSDictionary object (Objective-C) -

ios - Very simple iPhone App crashes on UILabel settext -