These are the general forms of the commands for compiling and linking non-threaded Client-Library applications on Apple Mac OS X 10.5 or later running on Intel:
Using debug libraries:
cc -g -I$SYBASE/$SYBASE_OCS/include -L$SYBASE/$SYBASE_OCS/devlib program.c -lsybct -lsybtcl -lsybcs -lsybcomn -lsybintl -lsybunic -lSystem -o program
Using shareable libraries with dynamic drivers:
cc -I$SYBASE/$SYBASE_OCS/include -L$SYBASE/$SYBASE_OCS/lib program.c -lsybct -lsybtcl -lsybcs -lsybcomn -lsybintl -lsybunic -lSystem -o program
Using static libraries:
WARNING! Use the static libraries compile-and-link commands with caution. Apple Mac OS X does not support static linking because of possible future compatibility issues. For more information, search for “Static Linking” on the Apple Developer Connection Web site.
cc -I$SYBASE/$SYBASE_OCS/include -L$SYBASE/$SYBASE_OCS/lib program.c -static -lsybct -lsybtcl -lsybcs -lsybcomn -lsybintl -lsybunic -lSystem -o program
See the makefile and sybopts.sh file in $SYBASE/$SYBASE_OCS/sample/ctlibrary for more compile and link information.