makefiles: Use winebuild to create the Windows import libraries.
This commit is contained in:
parent
054406f78c
commit
c861c3e42e
|
@ -664,7 +664,6 @@ LDEXECFLAGS
|
|||
IOKITLIB
|
||||
COREFOUNDATIONLIB
|
||||
SECURITYLIB
|
||||
MINGWAR
|
||||
DLLWRAP
|
||||
DLLTOOL
|
||||
LDD
|
||||
|
@ -6391,98 +6390,6 @@ else
|
|||
DLLWRAP="$ac_cv_prog_DLLWRAP"
|
||||
fi
|
||||
|
||||
if test -n "$ac_tool_prefix"; then
|
||||
# Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
|
||||
set dummy ${ac_tool_prefix}ar; ac_word=$2
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
|
||||
$as_echo_n "checking for $ac_word... " >&6; }
|
||||
if test "${ac_cv_prog_MINGWAR+set}" = set; then :
|
||||
$as_echo_n "(cached) " >&6
|
||||
else
|
||||
if test -n "$MINGWAR"; then
|
||||
ac_cv_prog_MINGWAR="$MINGWAR" # Let the user override the test.
|
||||
else
|
||||
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
|
||||
for as_dir in $PATH
|
||||
do
|
||||
IFS=$as_save_IFS
|
||||
test -z "$as_dir" && as_dir=.
|
||||
for ac_exec_ext in '' $ac_executable_extensions; do
|
||||
if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
|
||||
ac_cv_prog_MINGWAR="${ac_tool_prefix}ar"
|
||||
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
|
||||
break 2
|
||||
fi
|
||||
done
|
||||
done
|
||||
IFS=$as_save_IFS
|
||||
|
||||
fi
|
||||
fi
|
||||
MINGWAR=$ac_cv_prog_MINGWAR
|
||||
if test -n "$MINGWAR"; then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MINGWAR" >&5
|
||||
$as_echo "$MINGWAR" >&6; }
|
||||
else
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
||||
$as_echo "no" >&6; }
|
||||
fi
|
||||
|
||||
|
||||
fi
|
||||
if test -z "$ac_cv_prog_MINGWAR"; then
|
||||
ac_ct_MINGWAR=$MINGWAR
|
||||
# Extract the first word of "ar", so it can be a program name with args.
|
||||
set dummy ar; ac_word=$2
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
|
||||
$as_echo_n "checking for $ac_word... " >&6; }
|
||||
if test "${ac_cv_prog_ac_ct_MINGWAR+set}" = set; then :
|
||||
$as_echo_n "(cached) " >&6
|
||||
else
|
||||
if test -n "$ac_ct_MINGWAR"; then
|
||||
ac_cv_prog_ac_ct_MINGWAR="$ac_ct_MINGWAR" # Let the user override the test.
|
||||
else
|
||||
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
|
||||
for as_dir in $PATH
|
||||
do
|
||||
IFS=$as_save_IFS
|
||||
test -z "$as_dir" && as_dir=.
|
||||
for ac_exec_ext in '' $ac_executable_extensions; do
|
||||
if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
|
||||
ac_cv_prog_ac_ct_MINGWAR="ar"
|
||||
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
|
||||
break 2
|
||||
fi
|
||||
done
|
||||
done
|
||||
IFS=$as_save_IFS
|
||||
|
||||
fi
|
||||
fi
|
||||
ac_ct_MINGWAR=$ac_cv_prog_ac_ct_MINGWAR
|
||||
if test -n "$ac_ct_MINGWAR"; then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MINGWAR" >&5
|
||||
$as_echo "$ac_ct_MINGWAR" >&6; }
|
||||
else
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
||||
$as_echo "no" >&6; }
|
||||
fi
|
||||
|
||||
if test "x$ac_ct_MINGWAR" = x; then
|
||||
MINGWAR="false"
|
||||
else
|
||||
case $cross_compiling:$ac_tool_warned in
|
||||
yes:)
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
|
||||
$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
|
||||
ac_tool_warned=yes ;;
|
||||
esac
|
||||
MINGWAR=$ac_ct_MINGWAR
|
||||
fi
|
||||
else
|
||||
MINGWAR="$ac_cv_prog_MINGWAR"
|
||||
fi
|
||||
|
||||
if test "$DLLWRAP" = "false"; then
|
||||
LIBEXT="a"
|
||||
else
|
||||
|
@ -7026,108 +6933,6 @@ fi
|
|||
done
|
||||
test -n "$CROSSCC" || CROSSCC="false"
|
||||
|
||||
case "$host_cpu" in
|
||||
i[3456789]86*)
|
||||
ac_prefix_list="i686-pc-mingw32-dlltool i586-pc-mingw32-dlltool i486-pc-mingw32-dlltool i386-pc-mingw32-dlltool i686-mingw32msvc-dlltool i586-mingw32msvc-dlltool i486-mingw32msvc-dlltool i386-mingw32msvc-dlltool i686-mingw32-dlltool i586-mingw32-dlltool i486-mingw32-dlltool i386-mingw32-dlltool " ;;
|
||||
x86_64)
|
||||
ac_prefix_list="x86_64-pc-mingw32-dlltool x86_64-w64-mingw32-dlltool " ;;
|
||||
*)
|
||||
ac_prefix_list="" ;;
|
||||
esac
|
||||
for ac_prog in $ac_prefix_list
|
||||
do
|
||||
# Extract the first word of "$ac_prog", so it can be a program name with args.
|
||||
set dummy $ac_prog; ac_word=$2
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
|
||||
$as_echo_n "checking for $ac_word... " >&6; }
|
||||
if test "${ac_cv_prog_DLLTOOL+set}" = set; then :
|
||||
$as_echo_n "(cached) " >&6
|
||||
else
|
||||
if test -n "$DLLTOOL"; then
|
||||
ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
|
||||
else
|
||||
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
|
||||
for as_dir in $PATH
|
||||
do
|
||||
IFS=$as_save_IFS
|
||||
test -z "$as_dir" && as_dir=.
|
||||
for ac_exec_ext in '' $ac_executable_extensions; do
|
||||
if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
|
||||
ac_cv_prog_DLLTOOL="$ac_prog"
|
||||
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
|
||||
break 2
|
||||
fi
|
||||
done
|
||||
done
|
||||
IFS=$as_save_IFS
|
||||
|
||||
fi
|
||||
fi
|
||||
DLLTOOL=$ac_cv_prog_DLLTOOL
|
||||
if test -n "$DLLTOOL"; then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
|
||||
$as_echo "$DLLTOOL" >&6; }
|
||||
else
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
||||
$as_echo "no" >&6; }
|
||||
fi
|
||||
|
||||
|
||||
test -n "$DLLTOOL" && break
|
||||
done
|
||||
test -n "$DLLTOOL" || DLLTOOL="false"
|
||||
|
||||
case "$host_cpu" in
|
||||
i[3456789]86*)
|
||||
ac_prefix_list="i686-pc-mingw32-ar i586-pc-mingw32-ar i486-pc-mingw32-ar i386-pc-mingw32-ar i686-mingw32msvc-ar i586-mingw32msvc-ar i486-mingw32msvc-ar i386-mingw32msvc-ar i686-mingw32-ar i586-mingw32-ar i486-mingw32-ar i386-mingw32-ar " ;;
|
||||
x86_64)
|
||||
ac_prefix_list="x86_64-pc-mingw32-ar x86_64-w64-mingw32-ar " ;;
|
||||
*)
|
||||
ac_prefix_list="" ;;
|
||||
esac
|
||||
for ac_prog in $ac_prefix_list
|
||||
do
|
||||
# Extract the first word of "$ac_prog", so it can be a program name with args.
|
||||
set dummy $ac_prog; ac_word=$2
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
|
||||
$as_echo_n "checking for $ac_word... " >&6; }
|
||||
if test "${ac_cv_prog_MINGWAR+set}" = set; then :
|
||||
$as_echo_n "(cached) " >&6
|
||||
else
|
||||
if test -n "$MINGWAR"; then
|
||||
ac_cv_prog_MINGWAR="$MINGWAR" # Let the user override the test.
|
||||
else
|
||||
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
|
||||
for as_dir in $PATH
|
||||
do
|
||||
IFS=$as_save_IFS
|
||||
test -z "$as_dir" && as_dir=.
|
||||
for ac_exec_ext in '' $ac_executable_extensions; do
|
||||
if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
|
||||
ac_cv_prog_MINGWAR="$ac_prog"
|
||||
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
|
||||
break 2
|
||||
fi
|
||||
done
|
||||
done
|
||||
IFS=$as_save_IFS
|
||||
|
||||
fi
|
||||
fi
|
||||
MINGWAR=$ac_cv_prog_MINGWAR
|
||||
if test -n "$MINGWAR"; then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MINGWAR" >&5
|
||||
$as_echo "$MINGWAR" >&6; }
|
||||
else
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
||||
$as_echo "no" >&6; }
|
||||
fi
|
||||
|
||||
|
||||
test -n "$MINGWAR" && break
|
||||
done
|
||||
test -n "$MINGWAR" || MINGWAR="false"
|
||||
|
||||
if test "$CROSSCC" != "false"
|
||||
then
|
||||
CROSSTEST="\$(CROSSTEST)"
|
||||
|
|
|
@ -587,7 +587,6 @@ case $host_os in
|
|||
cygwin*|mingw32*)
|
||||
AC_CHECK_TOOL(DLLTOOL,dlltool,false)
|
||||
AC_CHECK_TOOL(DLLWRAP,dllwrap,false)
|
||||
AC_CHECK_TOOL(MINGWAR,ar,false)
|
||||
if test "$DLLWRAP" = "false"; then
|
||||
LIBEXT="a"
|
||||
else
|
||||
|
@ -756,8 +755,6 @@ dnl Check for cross compiler to build test programs
|
|||
if test "$cross_compiling" = "no" -a "$LIBEXT" != "dll"
|
||||
then
|
||||
WINE_CHECK_MINGW_PROG(CROSSCC,gcc,false)
|
||||
WINE_CHECK_MINGW_PROG(DLLTOOL,dlltool,false)
|
||||
WINE_CHECK_MINGW_PROG(MINGWAR,ar,false)
|
||||
if test "$CROSSCC" != "false"
|
||||
then
|
||||
AC_SUBST(CROSSTEST,"\$(CROSSTEST)")
|
||||
|
|
|
@ -9,15 +9,14 @@
|
|||
#
|
||||
|
||||
DLLFLAGS = @DLLFLAGS@
|
||||
MINGWAR = @MINGWAR@
|
||||
DEFS = -D__WINESRC__ $(EXTRADEFS)
|
||||
BASEMODULE = $(MODULE:%.dll=%)
|
||||
MAINSPEC = $(BASEMODULE).spec
|
||||
SPEC_DEF = $(BASEMODULE).def
|
||||
WIN16_FILES = $(SPEC_SRCS16:.spec=.spec.o) $(C_SRCS16:.c=.o) $(EXTRA_OBJS16)
|
||||
ALL_OBJS = @WIN16_FILES@ $(OBJS)
|
||||
ALL_LIBS = $(LIBPORT) $(EXTRALIBS) $(LDFLAGS) $(LIBS)
|
||||
IMPLIB_OBJS = $(IMPLIB_SRCS:.c=.o)
|
||||
IMPLIBFLAGS = $(TARGETFLAGS) $(EXTRAIMPLIBFLAGS)
|
||||
IMPORTLIBFILE = $(IMPORTLIB:%=lib%.@IMPLIBEXT@)
|
||||
STATICIMPLIB = $(IMPORTLIBFILE:.def=.def.a)
|
||||
DLL_LDPATH = -L$(DLLDIR) $(DELAYIMPORTS:%=-L$(DLLDIR)/%) $(IMPORTS:%=-L$(DLLDIR)/%)
|
||||
|
@ -38,17 +37,16 @@ all implib: $(IMPORTLIBFILE) $(IMPLIB_SRCS:%=__static_implib__%)
|
|||
|
||||
$(IMPLIB_SRCS:%=__static_implib__%): $(STATICIMPLIB)
|
||||
|
||||
$(SPEC_DEF) $(IMPORTLIB:%=lib%.def): $(MAINSPEC)
|
||||
$(WINEBUILD) $(TARGETFLAGS) -w --def -o $@ --export $(SRCDIR)/$(MAINSPEC)
|
||||
$(IMPORTLIB:%=lib%.def): $(MAINSPEC)
|
||||
$(WINEBUILD) $(IMPLIBFLAGS) -w --def -o $@ --export $(SRCDIR)/$(MAINSPEC)
|
||||
|
||||
$(IMPORTLIB:%=lib%.def.a): $(IMPLIB_OBJS)
|
||||
$(RM) $@
|
||||
$(AR) $(ARFLAGS) $@ $(IMPLIB_OBJS)
|
||||
$(RANLIB) $@
|
||||
|
||||
$(IMPORTLIB:%=lib%.a): $(SPEC_DEF) $(IMPLIB_OBJS)
|
||||
$(DLLTOOL) -k -l $@ -d $(SPEC_DEF)
|
||||
$(MINGWAR) rs $@ $(IMPLIB_OBJS)
|
||||
$(IMPORTLIB:%=lib%.a): $(MAINSPEC) $(IMPLIB_OBJS)
|
||||
$(WINEBUILD) $(IMPLIBFLAGS) @CROSSTARGETFLAGS@ -w --implib -o $@ --export $(SRCDIR)/$(MAINSPEC) $(IMPLIB_OBJS)
|
||||
|
||||
$(SUBDIRS): implib
|
||||
|
||||
|
@ -111,7 +109,7 @@ uninstall::
|
|||
# Misc. rules
|
||||
|
||||
clean::
|
||||
$(RM) $(SPEC_DEF) $(IMPORTLIBFILE)
|
||||
$(RM) $(IMPORTLIBFILE)
|
||||
|
||||
$(SPEC_DEF) $(SPEC_SRCS16:.spec=.spec.o): $(WINEBUILD)
|
||||
|
||||
|
|
Loading…
Reference in New Issue