Commit 4a0f3fbc authored by Alexandre Julliard's avatar Alexandre Julliard

winegcc: Stop using the deprecated prelink tool.

parent 5c98858a
......@@ -737,7 +737,6 @@ FAUDIO_PE_LIBS
FAUDIO_PE_CFLAGS
MINGW_PKG_CONFIG
PE_ARCHS
PRELINK
WINELOADER_DEPENDS
ac_ct_OBJC
OBJCFLAGS
......@@ -10266,56 +10265,6 @@ then :
*) WINELOADER_LDFLAGS="$WINELOADER_LDFLAGS -Wl,--section-start,.interp=0x7d000400" ;;
esac
fi
# Extract the first word of "prelink", so it can be a program name with args.
set dummy prelink; ac_word=$2
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
printf %s "checking for $ac_word... " >&6; }
if test ${ac_cv_path_PRELINK+y}
then :
printf %s "(cached) " >&6
else $as_nop
case $PRELINK in
[\\/]* | ?:[\\/]*)
ac_cv_path_PRELINK="$PRELINK" # Let the user override the test with a path.
;;
*)
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in /sbin /usr/sbin $PATH
do
IFS=$as_save_IFS
case $as_dir in #(((
'') as_dir=./ ;;
*/) ;;
*) as_dir=$as_dir/ ;;
esac
for ac_exec_ext in '' $ac_executable_extensions; do
if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_path_PRELINK="$as_dir$ac_word$ac_exec_ext"
printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
IFS=$as_save_IFS
test -z "$ac_cv_path_PRELINK" && ac_cv_path_PRELINK="false"
;;
esac
fi
PRELINK=$ac_cv_path_PRELINK
if test -n "$PRELINK"; then
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PRELINK" >&5
printf "%s\n" "$PRELINK" >&6; }
else
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
fi
if test "x$PRELINK" = xfalse
then
as_fn_append wine_warnings "|prelink not found and linker does not support relocation, base address of core dlls won't be set correctly."
fi
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports -Wl,-z,max-page-size=0x1000" >&5
printf %s "checking whether the compiler supports -Wl,-z,max-page-size=0x1000... " >&6; }
......@@ -23065,7 +23014,6 @@ OBJC = $OBJC
OBJCFLAGS = $OBJCFLAGS
ac_ct_OBJC = $ac_ct_OBJC
WINELOADER_DEPENDS = $WINELOADER_DEPENDS
PRELINK = $PRELINK
PE_ARCHS = $PE_ARCHS
MINGW_PKG_CONFIG = $MINGW_PKG_CONFIG
FAUDIO_PE_CFLAGS = $FAUDIO_PE_CFLAGS
......
......@@ -779,12 +779,7 @@ case $host_os in
[case $host_os in
freebsd* | kfreebsd*-gnu) WINELOADER_LDFLAGS="$WINELOADER_LDFLAGS -Wl,--section-start,.interp=0x60000400" ;;
*) WINELOADER_LDFLAGS="$WINELOADER_LDFLAGS -Wl,--section-start,.interp=0x7d000400" ;;
esac])
AC_PATH_PROG(PRELINK, prelink, false, [/sbin /usr/sbin $PATH])
if test "x$PRELINK" = xfalse
then
WINE_WARNING([prelink not found and linker does not support relocation, base address of core dlls won't be set correctly.])
fi])
esac])])
WINE_TRY_CFLAGS([-Wl,-z,max-page-size=0x1000],
[WINELOADER_LDFLAGS="$WINELOADER_LDFLAGS -Wl,-z,max-page-size=0x1000"])
;;
......
......@@ -16,7 +16,6 @@ winegcc_EXTRADEFS = \
-DCC="\"$(CC)\"" \
-DCPP="\"$(CPPBIN)\"" \
-DCXX="\"$(CXX)\"" \
-DLD="\"$(LD)\"" \
-DPRELINK="\"$(PRELINK)\""
-DLD="\"$(LD)\""
INSTALL_DEV = $(PROGRAMS) $(winegcc_SYMLINKS)
......@@ -188,7 +188,6 @@ struct options
const char* lib_suffix;
const char* subsystem;
const char* entry_point;
const char* prelink;
const char* debug_file;
const char* out_implib;
struct strarray prefix;
......@@ -480,8 +479,6 @@ static struct strarray get_link_args( struct options *opts, const char *output_n
{
if (!try_link( opts->prefix, link_args, strmake("-Wl,-Ttext-segment=%s", opts->image_base)) )
strarray_add( &flags, strmake("-Wl,-Ttext-segment=%s", opts->image_base) );
else
opts->prelink = PRELINK;
}
if (!try_link( opts->prefix, link_args, "-Wl,-z,max-page-size=0x1000"))
strarray_add( &flags, "-Wl,-z,max-page-size=0x1000");
......@@ -1385,20 +1382,6 @@ static void build(struct options* opts)
spawn(opts->prefix, implib_args, 0);
}
/* set the base address with prelink if linker support is not present */
if (opts->prelink && !opts->target_alias)
{
if (opts->prelink[0] && strcmp(opts->prelink,"false"))
{
struct strarray prelink_args = empty_strarray;
strarray_add(&prelink_args, opts->prelink);
strarray_add(&prelink_args, "--reloc-only");
strarray_add(&prelink_args, opts->image_base);
strarray_add(&prelink_args, output_path);
spawn(opts->prefix, prelink_args, 1);
}
}
if (!is_pe) fixup_constructors( opts, output_path );
else if (opts->wine_builtin) make_wine_builtin( opts, output_path );
......
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