Avoid some non-portable makefile constructs.

This commit is contained in:
Alexandre Julliard 2004-08-11 20:59:09 +00:00
parent ab13698998
commit 06233cfb47
7 changed files with 205 additions and 211 deletions

View File

@ -957,138 +957,135 @@ libuuid.a: uuid/libuuid.a
# Import libraries
IMPORT_LIBS = \
libadvapi32 \
libamstream \
libatl \
libavicap32 \
libavifil32 \
libcabinet \
libcapi2032 \
libcards \
libcfgmgr32 \
libcomcat \
libcomctl32 \
libcomdlg32 \
libcrtdll \
libcrypt32 \
libctl3d32 \
libd3d8 \
libd3d9 \
libd3dim \
libd3drm \
libd3dx8 \
libd3dxof \
libdbghelp \
libdciman32 \
libddraw \
libdevenum \
libdinput \
libdinput8 \
libdmband \
libdmcompos \
libdmime \
libdmloader \
libdmscript \
libdmstyle \
libdmsynth \
libdmusic \
libdmusic32 \
libdplay \
libdplayx \
libdpnet \
libdpnhpast \
libdsound \
libdswave \
libdxdiagn \
libgdi32 \
libglu32 \
libglut32 \
libiccvid \
libicmp \
libimagehlp \
libimm32 \
libiphlpapi \
libkernel32 \
liblz32 \
libmapi32 \
libmlang \
libmpr \
libmsacm32 \
libmsdmo \
libmshtml \
libmsi \
libmsimg32 \
libmsnet32 \
libmsrle32 \
libmsvcrt \
libmsvcrt20 \
libmsvcrt40 \
libmsvcrtd \
libmsvfw32 \
libmsvidc32 \
libmswsock \
libnetapi32 \
libnewdev \
libntdll \
libodbc32 \
libole32 \
liboleacc \
liboleaut32 \
libolecli32 \
liboledlg \
libolepro32 \
libolesvr32 \
libopengl32 \
libpsapi \
libqcap \
libquartz \
librasapi32 \
libriched32 \
librpcrt4 \
librsabase \
libsecur32 \
libserialui \
libsetupapi \
libshdocvw \
libshell32 \
libshfolder \
libshlwapi \
libsnmpapi \
libsti \
libtapi32 \
libttydrv \
libtwain_32 \
libunicows \
liburl \
liburlmon \
libuser32 \
libuxtheme \
libvdmdbg \
libversion \
libw32skrnl \
libwined3d \
libwinedos \
libwineps \
libwininet \
libwinmm \
libwinnls32 \
libwinspool \
libwintab32 \
libwintrust \
libwnaspi32 \
libwow32 \
libws2_32 \
libwsock32 \
libx11drv
ALL_IMPORT_LIBS = \
$(IMPORT_LIBS:%=%.$(IMPLIBEXT)) \
libadvapi32.$(IMPLIBEXT) \
libamstream.$(IMPLIBEXT) \
libatl.$(IMPLIBEXT) \
libavicap32.$(IMPLIBEXT) \
libavifil32.$(IMPLIBEXT) \
libcabinet.$(IMPLIBEXT) \
libcapi2032.$(IMPLIBEXT) \
libcards.$(IMPLIBEXT) \
libcfgmgr32.$(IMPLIBEXT) \
libcomcat.$(IMPLIBEXT) \
libcomctl32.$(IMPLIBEXT) \
libcomdlg32.$(IMPLIBEXT) \
libcrtdll.$(IMPLIBEXT) \
libcrypt32.$(IMPLIBEXT) \
libctl3d32.$(IMPLIBEXT) \
libd3d8.$(IMPLIBEXT) \
libd3d9.$(IMPLIBEXT) \
libd3dim.$(IMPLIBEXT) \
libd3drm.$(IMPLIBEXT) \
libd3dx8.$(IMPLIBEXT) \
libd3dxof.$(IMPLIBEXT) \
libdbghelp.$(IMPLIBEXT) \
libdciman32.$(IMPLIBEXT) \
libddraw.$(IMPLIBEXT) \
libdevenum.$(IMPLIBEXT) \
libdinput.$(IMPLIBEXT) \
libdinput8.$(IMPLIBEXT) \
libdmband.$(IMPLIBEXT) \
libdmcompos.$(IMPLIBEXT) \
libdmime.$(IMPLIBEXT) \
libdmloader.$(IMPLIBEXT) \
libdmscript.$(IMPLIBEXT) \
libdmstyle.$(IMPLIBEXT) \
libdmsynth.$(IMPLIBEXT) \
libdmusic.$(IMPLIBEXT) \
libdmusic32.$(IMPLIBEXT) \
libdplay.$(IMPLIBEXT) \
libdplayx.$(IMPLIBEXT) \
libdpnet.$(IMPLIBEXT) \
libdpnhpast.$(IMPLIBEXT) \
libdsound.$(IMPLIBEXT) \
libdswave.$(IMPLIBEXT) \
libdxdiagn.$(IMPLIBEXT) \
libgdi32.$(IMPLIBEXT) \
libglu32.$(IMPLIBEXT) \
libglut32.$(IMPLIBEXT) \
libiccvid.$(IMPLIBEXT) \
libicmp.$(IMPLIBEXT) \
libimagehlp.$(IMPLIBEXT) \
libimm32.$(IMPLIBEXT) \
libiphlpapi.$(IMPLIBEXT) \
libkernel32.$(IMPLIBEXT) \
liblz32.$(IMPLIBEXT) \
libmapi32.$(IMPLIBEXT) \
libmlang.$(IMPLIBEXT) \
libmpr.$(IMPLIBEXT) \
libmsacm32.$(IMPLIBEXT) \
libmsdmo.$(IMPLIBEXT) \
libmshtml.$(IMPLIBEXT) \
libmsi.$(IMPLIBEXT) \
libmsimg32.$(IMPLIBEXT) \
libmsnet32.$(IMPLIBEXT) \
libmsrle32.$(IMPLIBEXT) \
libmsvcrt.$(IMPLIBEXT) \
libmsvcrt20.$(IMPLIBEXT) \
libmsvcrt40.$(IMPLIBEXT) \
libmsvcrtd.$(IMPLIBEXT) \
libmsvfw32.$(IMPLIBEXT) \
libmsvidc32.$(IMPLIBEXT) \
libmswsock.$(IMPLIBEXT) \
libnetapi32.$(IMPLIBEXT) \
libnewdev.$(IMPLIBEXT) \
libntdll.$(IMPLIBEXT) \
libodbc32.$(IMPLIBEXT) \
libole32.$(IMPLIBEXT) \
liboleacc.$(IMPLIBEXT) \
liboleaut32.$(IMPLIBEXT) \
libolecli32.$(IMPLIBEXT) \
liboledlg.$(IMPLIBEXT) \
libolepro32.$(IMPLIBEXT) \
libolesvr32.$(IMPLIBEXT) \
libopengl32.$(IMPLIBEXT) \
libpsapi.$(IMPLIBEXT) \
libqcap.$(IMPLIBEXT) \
libquartz.$(IMPLIBEXT) \
librasapi32.$(IMPLIBEXT) \
libriched32.$(IMPLIBEXT) \
librpcrt4.$(IMPLIBEXT) \
librsabase.$(IMPLIBEXT) \
libsecur32.$(IMPLIBEXT) \
libserialui.$(IMPLIBEXT) \
libsetupapi.$(IMPLIBEXT) \
libshdocvw.$(IMPLIBEXT) \
libshell32.$(IMPLIBEXT) \
libshfolder.$(IMPLIBEXT) \
libshlwapi.$(IMPLIBEXT) \
libsnmpapi.$(IMPLIBEXT) \
libsti.$(IMPLIBEXT) \
libtapi32.$(IMPLIBEXT) \
libttydrv.$(IMPLIBEXT) \
libtwain_32.$(IMPLIBEXT) \
libunicows.$(IMPLIBEXT) \
liburl.$(IMPLIBEXT) \
liburlmon.$(IMPLIBEXT) \
libuser32.$(IMPLIBEXT) \
libuxtheme.$(IMPLIBEXT) \
libvdmdbg.$(IMPLIBEXT) \
libversion.$(IMPLIBEXT) \
libw32skrnl.$(IMPLIBEXT) \
libwined3d.$(IMPLIBEXT) \
libwinedos.$(IMPLIBEXT) \
libwineps.$(IMPLIBEXT) \
libwininet.$(IMPLIBEXT) \
libwinmm.$(IMPLIBEXT) \
libwinnls32.$(IMPLIBEXT) \
libwinspool.$(IMPLIBEXT) \
libwintab32.$(IMPLIBEXT) \
libwintrust.$(IMPLIBEXT) \
libwnaspi32.$(IMPLIBEXT) \
libwow32.$(IMPLIBEXT) \
libws2_32.$(IMPLIBEXT) \
libwsock32.$(IMPLIBEXT) \
libx11drv.$(IMPLIBEXT) \
libdxerr8.a \
libdxerr9.a \
libdxguid.a \
libuuid.a
implib: $(ALL_IMPORT_LIBS)
implib: $(IMPORT_LIBS)
libadvapi32.def: advapi32/advapi32.spec.def
$(RM) $@ && $(LN_S) advapi32/advapi32.spec.def $@
@ -1829,8 +1826,8 @@ winsock/ws2_32.spec.def: $(WINEBUILD)
wsock32/wsock32.spec.def: $(WINEBUILD)
x11drv/x11drv.spec.def: $(WINEBUILD)
$(BUILDSUBDIRS): $(ALL_IMPORT_LIBS)
$(INSTALLSUBDIRS:%=%/__install__): $(ALL_IMPORT_LIBS)
$(BUILDSUBDIRS): $(IMPORT_LIBS)
$(INSTALLSUBDIRS:%=%/__install__): $(IMPORT_LIBS)
# Map library name to the corresponding directory
@ -2012,18 +2009,18 @@ doc-sgml: $(SUBDIRS:%=%/__doc_sgml__)
# Misc rules
install install-dev:: $(ALL_IMPORT_LIBS)
install install-dev:: $(IMPORT_LIBS)
$(MKINSTALLDIRS) $(dlldir)
for f in $(ALL_IMPORT_LIBS); do $(INSTALL_DATA) $$f $(dlldir)/$$f; done
for f in $(IMPORT_LIBS); do $(INSTALL_DATA) $$f $(dlldir)/$$f; done
install install-lib:: $(INSTALLSUBDIRS:%=%/__install__)
uninstall::
$(RM) $(ALL_IMPORT_LIBS:%=$(dlldir)/%)
-cd $(dlldir) && $(RM) $(IMPORT_LIBS)
-rmdir $(dlldir)
clean::
$(RM) $(ALL_IMPORT_LIBS) $(SYMLINKS)
$(RM) $(IMPORT_LIBS) $(SYMLINKS)
check test:: $(BUILDSUBDIRS:%=%/__test__)

View File

@ -229,15 +229,14 @@ foreach my $mod (sort @implibs)
{
my $def = $mod;
$def =~ s/\.(dll|drv)$//;
printf NEWMAKE " \\\n\tlib%s", $def;
printf NEWMAKE " \\\n\tlib%s.\$(IMPLIBEXT)", $def;
}
print NEWMAKE "\n\nALL_IMPORT_LIBS = \\\n\t\$(IMPORT_LIBS:%=%.\$(IMPLIBEXT))";
foreach my $mod (sort keys %implib_dirs)
{
printf NEWMAKE " \\\n\t%s", $mod;
}
print NEWMAKE "\n\n";
print NEWMAKE "implib: \$(ALL_IMPORT_LIBS)\n\n";
print NEWMAKE "implib: \$(IMPORT_LIBS)\n\n";
foreach my $mod (sort @implibs)
{
@ -262,8 +261,8 @@ foreach my $mod (sort @implibs)
print NEWMAKE <<EOF;
\$(BUILDSUBDIRS): \$(ALL_IMPORT_LIBS)
\$(INSTALLSUBDIRS:%=%/__install__): \$(ALL_IMPORT_LIBS)
\$(BUILDSUBDIRS): \$(IMPORT_LIBS)
\$(INSTALLSUBDIRS:%=%/__install__): \$(IMPORT_LIBS)
EOF
@ -307,18 +306,18 @@ doc-sgml: \$(SUBDIRS:%=%/__doc_sgml__)
# Misc rules
install install-dev:: \$(ALL_IMPORT_LIBS)
install install-dev:: \$(IMPORT_LIBS)
\$(MKINSTALLDIRS) \$(dlldir)
for f in \$(ALL_IMPORT_LIBS); do \$(INSTALL_DATA) \$\$f \$(dlldir)/\$\$f; done
for f in \$(IMPORT_LIBS); do \$(INSTALL_DATA) \$\$f \$(dlldir)/\$\$f; done
install install-lib:: \$(INSTALLSUBDIRS:%=%/__install__)
uninstall::
\$(RM) \$(ALL_IMPORT_LIBS:%=\$(dlldir)/%)
-cd \$(dlldir) && \$(RM) \$(IMPORT_LIBS)
-rmdir \$(dlldir)
clean::
\$(RM) \$(ALL_IMPORT_LIBS) \$(SYMLINKS)
\$(RM) \$(IMPORT_LIBS) \$(SYMLINKS)
check test:: \$(BUILDSUBDIRS:%=%/__test__)

View File

@ -49,7 +49,7 @@ install:: $(WINE_BINARIES)
done
uninstall::
$(RM) $(WINE_BINARIES:%=$(bindir)/%) $(bindir)/$(MODULE)
-cd $(bindir) && $(RM) $(WINE_BINARIES) $(MODULE)
clean::
$(RM) $(WINE_BINARIES) $(MODULE)

View File

@ -88,42 +88,42 @@ INSTALLPROGS = \
# Symlinks to apps that we want to run from inside the source tree
SYMLINKS = \
aviinfo.exe \
aviplay.exe \
clock.exe \
cmdlgtst.exe \
control.exe \
expand.exe \
icinfo.exe \
msiexec.exe \
notepad.exe \
progman.exe \
regedit.exe \
regsvr32.exe \
rpcss.exe \
rundll32.exe \
start.exe \
taskmgr.exe \
uninstaller.exe \
view.exe \
wcmd.exe \
wineboot.exe \
winebrowser.exe \
winecfg.exe \
wineconsole.exe \
winedbg.exe \
winefile.exe \
winemenubuilder.exe \
winemine.exe \
winepath.exe \
winetest.exe \
winevdm.exe \
winhelp.exe \
winver.exe
aviinfo.exe$(DLLEXT) \
aviplay.exe$(DLLEXT) \
clock.exe$(DLLEXT) \
cmdlgtst.exe$(DLLEXT) \
control.exe$(DLLEXT) \
expand.exe$(DLLEXT) \
icinfo.exe$(DLLEXT) \
msiexec.exe$(DLLEXT) \
notepad.exe$(DLLEXT) \
progman.exe$(DLLEXT) \
regedit.exe$(DLLEXT) \
regsvr32.exe$(DLLEXT) \
rpcss.exe$(DLLEXT) \
rundll32.exe$(DLLEXT) \
start.exe$(DLLEXT) \
taskmgr.exe$(DLLEXT) \
uninstaller.exe$(DLLEXT) \
view.exe$(DLLEXT) \
wcmd.exe$(DLLEXT) \
wineboot.exe$(DLLEXT) \
winebrowser.exe$(DLLEXT) \
winecfg.exe$(DLLEXT) \
wineconsole.exe$(DLLEXT) \
winedbg.exe$(DLLEXT) \
winefile.exe$(DLLEXT) \
winemenubuilder.exe$(DLLEXT) \
winemine.exe$(DLLEXT) \
winepath.exe$(DLLEXT) \
winetest.exe$(DLLEXT) \
winevdm.exe$(DLLEXT) \
winhelp.exe$(DLLEXT) \
winver.exe$(DLLEXT)
@MAKE_RULES@
all: wineapploader winelauncher $(SUBDIRS) $(SYMLINKS:%=%$(DLLEXT))
all: wineapploader winelauncher $(SUBDIRS) $(SYMLINKS)
wineapploader: wineapploader.in
sed -e 's,@bindir\@,$(bindir),g' $(SRCDIR)/wineapploader.in >$@ || ($(RM) $@ && false)
@ -152,7 +152,7 @@ install:: winelauncher install-progs$(DLLEXT)
$(INSTALL_SCRIPT) winelauncher $(bindir)/winelauncher
uninstall::
$(RM) $(bindir)/wineapploader $(bindir)/winelauncher $(INSTALLPROGS:%=$(bindir)/%)
-cd $(bindir) && $(RM) wineapploader winelauncher $(INSTALLPROGS)
-rmdir $(dlldir)
clean::

View File

@ -15,7 +15,7 @@ C_SRCS = \
@MAKE_RULES@
all: $(PROGRAMS:%=%$(DLLEXT)) $(PROGRAMS:.exe=$(EXEEXT))
all: aviinfo.exe$(DLLEXT) aviplay.exe$(DLLEXT) icinfo.exe$(DLLEXT) aviinfo$(EXEEXT) aviplay$(EXEEXT) icinfo$(EXEEXT)
aviinfo.exe.so: aviinfo.o
$(WINEGCC) -B$(TOOLSDIR)/tools/winebuild -mwindows -o $@ aviinfo.o -L$(DLLDIR) -lavifil32 -lkernel32 $(ALL_LIBS)
@ -55,10 +55,10 @@ install_prog: $(PROGRAMS)
$(INSTALL_PROGRAM) icinfo.exe $(bindir)/icinfo.exe
uninstall_prog.so:
$(RM) $(PROGRAMS:%=$(dlldir)/%.so)
$(RM) $(dlldir)/aviinfo.exe.so $(dlldir)/aviplay.exe.so $(dlldir)/icinfo.exe.so
uninstall_prog:
$(RM) $(PROGRAMS:%=$(bindir)/%)
$(RM) $(bindir)/aviinfo.exe $(bindir)/aviplay.exe $(bindir)/icinfo.exe
install:: install_prog$(DLLEXT)

View File

@ -134,7 +134,7 @@ foreach my $dir (sort keys %alldirs)
print NEWMAKE "\n\n# Symlinks to apps that we want to run from inside the source tree\nSYMLINKS =";
foreach my $mod (sort keys %directories)
{
printf NEWMAKE " \\\n\t%s", $mod;
printf NEWMAKE " \\\n\t%s\$(DLLEXT)", $mod;
}
################################################################
@ -145,7 +145,7 @@ print NEWMAKE <<EOF;
\@MAKE_RULES\@
all: wineapploader winelauncher \$(SUBDIRS) \$(SYMLINKS:%=%\$(DLLEXT))
all: wineapploader winelauncher \$(SUBDIRS) \$(SYMLINKS)
wineapploader: wineapploader.in
sed -e 's,\@bindir\\\@,\$(bindir),g' \$(SRCDIR)/wineapploader.in >\$\@ || (\$(RM) \$\@ && false)
@ -174,7 +174,7 @@ install:: winelauncher install-progs\$(DLLEXT)
\$(INSTALL_SCRIPT) winelauncher \$(bindir)/winelauncher
uninstall::
\$(RM) \$(bindir)/wineapploader \$(bindir)/winelauncher \$(INSTALLPROGS:%=\$(bindir)/%)
-cd \$(bindir) && \$(RM) wineapploader winelauncher \$(INSTALLPROGS)
-rmdir \$(dlldir)
clean::

View File

@ -18,39 +18,37 @@ RC_SRCS = \
RC_BINSRC = winetest.rc
RC_BINARIES = wine.ico
TESTS = \
advapi32 \
comctl32 \
dsound \
gdi32 \
iphlpapi \
kernel32 \
mapi32 \
mlang \
msacm32 \
msvcrt \
msvcrtd \
netapi32 \
ntdll \
oleaut32 \
psapi \
rpcrt4 \
shell32 \
shlwapi \
urlmon \
user32 \
version \
wininet \
winmm \
winspool.drv \
ws2_32
TESTBINS = \
advapi32_test.exe$(DLLEXT) \
comctl32_test.exe$(DLLEXT) \
dsound_test.exe$(DLLEXT) \
gdi32_test.exe$(DLLEXT) \
iphlpapi_test.exe$(DLLEXT) \
kernel32_test.exe$(DLLEXT) \
mapi32_test.exe$(DLLEXT) \
mlang_test.exe$(DLLEXT) \
msacm32_test.exe$(DLLEXT) \
msvcrt_test.exe$(DLLEXT) \
msvcrtd_test.exe$(DLLEXT) \
netapi32_test.exe$(DLLEXT) \
ntdll_test.exe$(DLLEXT) \
oleaut32_test.exe$(DLLEXT) \
psapi_test.exe$(DLLEXT) \
rpcrt4_test.exe$(DLLEXT) \
shell32_test.exe$(DLLEXT) \
shlwapi_test.exe$(DLLEXT) \
urlmon_test.exe$(DLLEXT) \
user32_test.exe$(DLLEXT) \
version_test.exe$(DLLEXT) \
wininet_test.exe$(DLLEXT) \
winmm_test.exe$(DLLEXT) \
winspool.drv_test.exe$(DLLEXT) \
ws2_32_test.exe$(DLLEXT)
@MAKE_PROG_RULES@
# Special rules
TESTBINS = $(TESTS:%=%_test.exe$(DLLEXT))
tests.rc: maketest Makefile.in
$(SRCDIR)/maketest $(TOPSRCDIR) $(TESTBINS) > $@ || ( $(RM) $@ && exit 1 )