diff options
Diffstat (limited to 'auto/modules/perl')
-rw-r--r-- | auto/modules/perl | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/auto/modules/perl b/auto/modules/perl index 3c88ef0e..86232adc 100644 --- a/auto/modules/perl +++ b/auto/modules/perl @@ -67,6 +67,12 @@ if /bin/sh -c "$NXT_PERL -MConfig -e 'print \"Perl version: \", | sed -e 's/-arch i386//' -e 's/-arch x86_64//'` fi + if [ "$NXT_CC_NAME" = "clang" ]; then + # Perl's CFLAGS has -fwrapv which under clang discards our + # -fno-strict-overflow resulting in an unused argument error + NXT_PERL_CFLAGS="$NXT_PERL_CFLAGS -Qunused-arguments" + fi + nxt_feature="Perl" nxt_feature_name="" nxt_feature_run=no @@ -165,8 +171,9 @@ for nxt_src in $NXT_PERL_MODULE_SRCS; do cat << END >> $NXT_MAKEFILE $NXT_BUILD_DIR/$nxt_obj: $nxt_src $NXT_VERSION_H - mkdir -p $NXT_BUILD_DIR/src/perl - \$(CC) -c \$(CFLAGS) $NXT_PERL_CFLAGS \$(NXT_INCS) $NXT_PERL_INCLUDE \\ + \$(v)mkdir -p $NXT_BUILD_DIR/src/perl + \$(PP_CC) \$@ + \$(v)\$(CC) -c \$(CFLAGS) $NXT_PERL_CFLAGS \$(NXT_INCS) $NXT_PERL_INCLUDE \\ $nxt_dep_flags \\ -o $NXT_BUILD_DIR/$nxt_obj $nxt_src $nxt_dep_post @@ -188,7 +195,8 @@ all: ${NXT_PERL_MODULE} ${NXT_PERL_MODULE}: $NXT_BUILD_DIR/lib/unit/modules/${NXT_PERL_MODULE}.unit.so $NXT_BUILD_DIR/lib/unit/modules/${NXT_PERL_MODULE}.unit.so: $nxt_objs - \$(NXT_MODULE_LINK) -o \$@ $nxt_objs $NXT_PERL_LDOPTS $NXT_LD_OPT + \$(PP_LD) \$@ + \$(v)\$(NXT_MODULE_LINK) -o \$@ $nxt_objs $NXT_PERL_LDOPTS $NXT_LD_OPT install: ${NXT_PERL_MODULE}-install |