Table of Contents
This appendix lists the following troubleshooting tips.
The process for compiling a shared library varies with
the platform used, so the Traffic Server API includes makefile
templates you can use to create shared libraries on all supported
Traffic Server platforms.
Assuming the sample program is stored in the file hello-world.c
,
you could use the following commands to building a shared library on
Solaris using the GNU C compiler.
gcc -g -Wall -fPIC -o hello-world.o -c hello-world.c gcc -g -Wall -shared -o hello-world.so hello-world.o
The first command compiles hello-world.c
as Position Independent
Code (PIC); the second command links the single hello-world.o
object file into the hello-world.so
shared library.
![]() |
Caution |
---|---|
Make sure that your plugin is not statically linked with system libraries. |
Assuming the sample program is stored in the file hello_world.c
,
you could use the following commands to build a shared library on
HPUX:
cc +z -o hello_world.o -c hello_world.c ld -b -o hello_world.so hello_world.o