All pastes #795152 Raw Edit

Something

public text v1 · immutable
#795152 ·published 2007-11-23 21:25 UTC
rendered paste body
##################################3
# the makefile 
CC = gcc
LD = gcc
CFLAGS = -g -Wall -fPIC -Isdk
LDFLAGS = -ldl -shared -fPIC $(DETOURLIBS)

RM = /bin/rm -f

DETOURLIBS = libghf.a
OBJS = init.o hook.o
PROG = fusion.so

# Main rule
all: $(PROG)

# Link
$(PROG): $(OBJS)
        $(LD) $(LDFLAGS) $(OBJS) -o $(PROG)

init.o: init.c
        $(CC) $(CFLAGS) -c init.c -o init.o
hook.o: hook.c
        $(CC) $(CFLAGS) -c hook.c -o hook.o
clean:
        $(RM) $(PROG) $(OBJS)
superclean: clean
        $(RM) *.c~ *.h~ Makefile~

install:
        cp $(PROG) tremulous/$(PROG)
##################################
# when compiling...
gcc -g -Wall -fPIC -Isdk  -c init.c -o init.o
init.c:14: warning: initialization makes integer from pointer without a cast
gcc -g -Wall -fPIC -Isdk  -c hook.c -o hook.o
hook.c: In function 'inithooks':
hook.c:21: warning: cast to pointer from integer of different size
gcc -ldl -shared -fPIC libghf.a init.o hook.o -o fusion.so

#####################
[FUSION] Starting up...
[FUSION] "Icarus" initalization started. 
[FUSION] Current process match!
./tremulous.x86: symbol lookup error: ./fusion.so: undefined symbol: getSymbol