$NetBSD: patch-configure,v 1.3 2018/01/16 14:53:28 jperkin Exp $ * Adding Interix support. * Ignore doxygen. * Ignore VCS. * Handle SSP in pkgsrc. --- configure.orig 2017-12-14 14:36:11.000000000 +0000 +++ configure @@ -5727,7 +5727,7 @@ esac else if test x"$target_alias" = x; then case "$target_os" in #( - darwin*) : + notdarwin*) : { $as_echo "$as_me:${as_lineno-$LINENO}: checking for real target cpu" >&5 $as_echo_n "checking for real target cpu... " >&6; } @@ -8112,6 +8112,7 @@ esac stack_protector=no ;; #( *) : + stack_protector=no ;; esac if test -z "${stack_protector+set}"; then @@ -9325,7 +9326,7 @@ rm -f core conftest.err conftest.$ac_obj # is often also needed in CPPFLAGS, because some feature # definitions vary depending on such standards options. case "${ansi_options}" in #( - *-std=iso9899:1999*) : + *-std=iso9899:1999*|*-std=gnu99*) : # RUBY_APPEND_OPTIONS(CPPFLAGS) for rb_opt in ${ansi_options}; do @@ -9555,6 +9556,10 @@ esac LIBS="-lm $LIBS" ac_cv_func_round=no ;; #( + interix*) : + LIBS="-lm $LIBS" + ac_cv_func_getpgrp_void=yes + ;; #( nacl) : LIBS="-lm $LIBS" @@ -19808,6 +19813,8 @@ else # ifdef _MSC_VER # include # define alloca _alloca +# elif defined(__NetBSD__) || defined(__FreeBSD__) || defined(__DragonFly__) || defined(__OpenBSD__) +# include # else # ifdef HAVE_ALLOCA_H # include @@ -24490,7 +24497,9 @@ esac ;; #( interix*) : : ${LDSHARED='$(CC) -shared'} XLDFLAGS="$XLDFLAGS -Wl,-E" + DLDFLAGS="$DLDFLAGS "'-Wl,-h,$(.TARGET) -Wl,--image-base,$$(($$RANDOM %4096/2*262144+1342177280))' LIBPATHFLAG=" -L%1\$-s" + RPATHFLAG=' -Wl,-R%1$-s' rb_cv_dlopen=yes ;; #( freebsd*|dragonfly*) : @@ -25617,7 +25626,7 @@ esac freebsd*|dragonfly*) : SOLIBS='$(LIBS)' - LIBRUBY_SO='lib$(RUBY_SO_NAME).so.$(MAJOR)$(MINOR)' + LIBRUBY_SO='lib$(RUBY_SO_NAME).so.$(MAJOR)$(MINOR)$(TEENY)' if test "$rb_cv_binary_elf" != "yes" ; then LIBRUBY_SO="$LIBRUBY_SO.\$(TEENY)" LIBRUBY_ALIASES='' @@ -25706,7 +25715,12 @@ esac ;; #( interix*) : - LIBRUBYARG_SHARED='-L. -L${libdir} -l$(RUBY_SO_NAME)' + SOLIBS='$(LIBS)' + LIBRUBY_SO='lib$(RUBY_SO_NAME).so.$(MAJOR)$(MINOR).$(TEENY)' + # link explicitly to 0x48000000 + LIBRUBY_DLDFLAGS='-Wl,-h,lib$(RUBY_SO_NAME).so.$(MAJOR)$(MINOR) -Wl,--image-base,1207959552' + LIBRUBYARG_SHARED='-Wl,-R -Wl,${PREFIX}/lib} -L${libdir} -L. -l$(RUBY_SO_NAME)' + LIBRUBY_ALIASES='lib$(RUBY_SO_NAME).so.$(MAJOR)$(MINOR) lib$(RUBY_SO_NAME).so' ;; #( mingw*|cygwin*|mswin*) : @@ -25874,7 +25888,7 @@ if test "$enable_rpath" = yes; then esac rpathflag=`IFS="$PATH_SEPARATOR" echo x "$rpathflag" | - sed "s/^x *//;s${IFS}"'%1\\$-s'"${IFS}${libprefix}${IFS}g;s${IFS}%s${IFS}${libprefix}${IFS}g" + sed "s/^x *//;s${IFS}"'%1\\$-s'"${IFS}${libprefix}${IFS}g;s${IFS}%s${IFS}${PREFIX}/lib${IFS}g" ` LIBRUBY_RPATHFLAGS="$LIBRUBY_RPATHFLAGS${rpathflag}" LIBRUBYARG_SHARED="$LIBRUBY_RPATHFLAGS $LIBRUBYARG_SHARED" @@ -26370,11 +26384,7 @@ if test "$install_doc" != no; then else RDOCTARGET="nodoc" fi - if test "$install_capi" != no -a -n "$DOXYGEN"; then - CAPITARGET="capi" - else - CAPITARGET="nodoc" - fi + CAPITARGET="nodoc" else RDOCTARGET="nodoc" CAPITARGET="nodoc" @@ -28404,19 +28414,7 @@ which seems to be undefined. Please mak "Makefile":F) tmpmk=confmk$$.tmp { - if test ${VCS+set}; then - : - elif svn info "$srcdir" > /dev/null 2>&1; then - VCS='svn' - elif git_dir=`git --work-tree="$srcdir" --git-dir="$srcdir/.git" rev-parse --git-dir 2>/dev/null`; then - if test -d "$git_dir/svn"; then - VCS='git svn' - else - VCS='git' - fi - else - VCS='echo cannot' - fi + VCS='echo cannot' case "$VCS" in #( svn) : VCSUP='$(VCS) up $(SVNUPOPTIONS)' ;; #(