compatibility fix for mingw32
authorLuigi Rizzo <rizzo@icir.org>
Sat, 17 Nov 2007 02:50:52 +0000 (02:50 +0000)
committerLuigi Rizzo <rizzo@icir.org>
Sat, 17 Nov 2007 02:50:52 +0000 (02:50 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@89352 65c4cc65-6c06-0410-ace0-fbb531ad65f3

Makefile.moddir_rules

index 2bd809d..be44ddc 100644 (file)
@@ -44,7 +44,10 @@ $(addsuffix .oo,$(CC_MODS)) $(addsuffix .o,$(C_MODS)):       \
        ASTCFLAGS+= -DAST_MODULE=\"$*\" $(MENUSELECT_OPTS_$*:%=-D%) $(foreach dep,$(MENUSELECT_DEPENDS_$*),$(value $(dep)_INCLUDE))
 
 # For loadable modules, pass _LIB and _LDFLAGS from menuselect.
+ifneq ($(OSARCH),mingw32)       # -fPIC is default on mingw32 and cygwin
 $(LOADABLE_MODS:%=%.so): ASTCFLAGS+=-fPIC
+endif
+
 $(LOADABLE_MODS:%=%.so): LIBS+=$(foreach dep,$(MENUSELECT_DEPENDS_$*),$(value $(dep)_LIB))
 $(LOADABLE_MODS:%=%.so): ASTLDFLAGS+=$(foreach dep,$(MENUSELECT_DEPENDS_$*),$(value $(dep)_LDFLAGS))