3. compiling (+ figuring out the configuration of perl)
| # perl -e 'use Config; print $Config{ccflags};'
-D_REENTRANT -D_GNU_SOURCE -DTHREADS_HAVE_PIDS -DDEBIAN -fno-strict-aliasing -I/
usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 |
|
|
| gcc -D_REENTRANT -D_GNU_SOURCE -DTHREADS_HAVE_PIDS -DDEBIAN -fno-strict-aliasing
-I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -c sample.c sa
mple_wrap.c -I /usr/lib/perl/5.8.4/CORE |
|
|
creates:
sample.o sample_wrap.o
4. linking
| ld -G sample.o sample_wrap.o -o sample.so |
|
|
5. installation
| cp sample.so /usr/local/lib/perl/5.8.4
cp sample.pm /usr/local/lib/perl/5.8.4 |
|
|
|