Commit b08f3c5c authored by Jeremy Soller's avatar Jeremy Soller

Always compile with fPIC

parent 40b2b829
SRC=$(wildcard *.c)
OBJ=$(patsubst %.c,%.o,$(SRC))
LOBJ=$(patsubst %.c,%.lo,$(SRC))
all: libpthread.a
libpthread.a: $(OBJ)
$(AR) -rcs $@ $(OBJ)
libpthread.so: $(LOBJ)
$(CC) $(CFLAGS) -nostdlib -shared -o $@ $(LOBJ)
libpthread.so: $(OBJ)
$(CC) $(CFLAGS) -nostdlib -shared -o $@ $(OBJ)
%.o: %.c
$(CC) $(CFLAGS) -I . -c $< -o $@
%.lo: %.c
$(CC) $(CFLAGS) -fPIC -I . -c $< -o $@
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment