$(LD) -x -Bshareable to $(CC) -shared on OpenBSD (I suspect this
should be carried over to the other two as well, but will refrain
pending suggestions from people who actually use those platforms).
Per Stefan Kaltenbrunner.
endif
DLSUFFIX = .so
+
+ifeq ($(findstring sparc,$(host_cpu)), sparc)
+CFLAGS_SL = -fPIC -DPIC
+else
CFLAGS_SL = -fpic -DPIC
+endif
+
%.so: %.o
ifdef ELF_SYSTEM
endif
DLSUFFIX = .so
+
+ifeq ($(findstring sparc,$(host_cpu)), sparc)
+CFLAGS_SL = -fPIC -DPIC
+else
CFLAGS_SL = -fpic -DPIC
+endif
+
%.so: %.o
ifdef ELF_SYSTEM
@${AR} cq $@.pic `lorder $<.obj | tsort`
${RANLIB} $@.pic
@rm -f $@
- $(LD) -x -Bshareable -Bforcearchive \
- -o $@ $@.pic
+ $(LD) -x -Bshareable -Bforcearchive -o $@ $@.pic
endif
sqlmansect = 7
endif
DLSUFFIX = .so
+
+ifeq ($(findstring sparc,$(host_cpu)), sparc)
+CFLAGS_SL = -fPIC -DPIC
+else
CFLAGS_SL = -fpic -DPIC
+endif
+
%.so: %.o
ifdef ELF_SYSTEM
- $(LD) -x -Bshareable -o $@ $<
+ $(CC) -shared -o $@ $<
else
$(LD) $(LDREL) $(LDOUT) $<.obj -x $<
@echo building shared object $@
@${AR} cq $@.pic `lorder $<.obj | tsort`
${RANLIB} $@.pic
@rm -f $@
- $(LD) -x -Bshareable -Bforcearchive \
- -o $@ $@.pic
+ $(LD) -x -Bshareable -Bforcearchive -o $@ $@.pic
endif
sqlmansect = 7