Alexandre Julliard : winetest: Build exe resources as separate .res files.
Alexandre Julliard
julliard at winehq.org
Mon Jul 6 09:33:53 CDT 2009
Module: wine
Branch: master
Commit: 0dc951694bfeceebeacbb4148e66bb663ba87d1c
URL: http://source.winehq.org/git/wine.git/?a=commit;h=0dc951694bfeceebeacbb4148e66bb663ba87d1c
Author: Alexandre Julliard <julliard at winehq.org>
Date: Sat Jul 4 11:20:09 2009 +0200
winetest: Build exe resources as separate .res files.
---
.gitignore | 2 +-
configure | 10 +++++++---
configure.ac | 10 +++++++---
programs/winetest/Makefile.in | 21 ++++++---------------
programs/winetest/winetest.rc | 2 --
tools/make_makefiles | 2 +-
6 files changed, 22 insertions(+), 25 deletions(-)
diff --git a/.gitignore b/.gitignore
index f096f4a..5303e1c 100644
--- a/.gitignore
+++ b/.gitignore
@@ -197,7 +197,7 @@ programs/winedbg/dbg.tab.h
programs/winedbg/debug.yy.c
programs/winedbg/winedbg.man
programs/winetest/*_test.exe
-programs/winetest/tests.rc
+programs/winetest/*_test.rc
programs/winhlp32/macro.lex.yy.c
server/wineserver
server/wineserver-installed
diff --git a/configure b/configure
index 97bb65a..9e59d11 100755
--- a/configure
+++ b/configure
@@ -28762,10 +28762,14 @@ for dir in $ALL_TEST_DIRS
do
if test "$dir" != "\\"
then
- testname=`expr $dir : '\(.*\)/tests'`_test.exe
+ testname=`expr $dir : '\(.*\)/tests'`_test
ALL_WINETEST_DEPENDS="$ALL_WINETEST_DEPENDS
-$testname: \$(DLLDIR)/$dir/$testname\$(DLLEXT)
- cp \$(DLLDIR)/$dir/$testname\$(DLLEXT) \$@ && \$(STRIP) \$@"
+
+$testname.exe: \$(DLLDIR)/$dir/$testname.exe\$(DLLEXT)
+ cp \$(DLLDIR)/$dir/$testname.exe\$(DLLEXT) \$@ && \$(STRIP) \$@
+$testname.rc:
+ echo \"$testname.exe TESTRES \\\"$testname.exe\\\"\" >\$@ || (\$(RM) \$@ && false)
+$testname.res: $testname.rc $testname.exe"
fi
done
diff --git a/configure.ac b/configure.ac
index c6843d9..23cf7fe 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2527,10 +2527,14 @@ for dir in $ALL_TEST_DIRS
do
if test "$dir" != "\\"
then
- testname=`expr $dir : '\(.*\)/tests'`_test.exe
+ testname=`expr $dir : '\(.*\)/tests'`_test
ALL_WINETEST_DEPENDS="$ALL_WINETEST_DEPENDS
-$testname: \$(DLLDIR)/$dir/$testname\$(DLLEXT)
- cp \$(DLLDIR)/$dir/$testname\$(DLLEXT) \$@ && \$(STRIP) \$@"
+
+$testname.exe: \$(DLLDIR)/$dir/$testname.exe\$(DLLEXT)
+ cp \$(DLLDIR)/$dir/$testname.exe\$(DLLEXT) \$@ && \$(STRIP) \$@
+$testname.rc:
+ echo \"$testname.exe TESTRES \\\"$testname.exe\\\"\" >\$@ || (\$(RM) \$@ && false)
+$testname.res: $testname.rc $testname.exe"
fi
done
diff --git a/programs/winetest/Makefile.in b/programs/winetest/Makefile.in
index bd1251f..90cd983 100644
--- a/programs/winetest/Makefile.in
+++ b/programs/winetest/Makefile.in
@@ -20,25 +20,18 @@ RC_SRCS = \
SVG_SRCS = winetest.svg
- at MAKE_PROG_RULES@
-
ALL_TEST_DIRS = @ALL_TEST_DIRS@
-TESTBINS = $(ALL_TEST_DIRS:%/tests=%_test.exe)
-
- at ALL_WINETEST_DEPENDS@
-
-# Special rules
+TESTBINS = $(ALL_TEST_DIRS:%/tests=%_test.exe)
+TESTRCS = $(TESTBINS:.exe=.rc)
+EXTRA_OBJS = $(TESTRCS:.rc=.res)
-winetest.res: $(TESTBINS)
+ at MAKE_PROG_RULES@
-tests.rc: Makefile.in $(TOPOBJDIR)/config.status
- (for i in $(TESTBINS); do echo "$$i TESTRES \"$$i\""; done) >$@ || ($(RM) $@ && false)
+ at ALL_WINETEST_DEPENDS@
clean::
- $(RM) tests.rc dist.res winetest-dist.exe $(TESTBINS)
-
-depend: tests.rc
+ $(RM) winetest-dist.exe $(TESTBINS) $(TESTRCS)
# Rules for building distributable executable
@@ -53,5 +46,3 @@ winetest-dist.exe winetest-dist.exe.so: $(OBJS) dist.res Makefile.in
dist.res: build.nfo
@DEPENDENCIES@ # everything below this line is overwritten by make depend
-
-winetest.res: tests.rc
diff --git a/programs/winetest/winetest.rc b/programs/winetest/winetest.rc
index 4d406f2..8056a25 100644
--- a/programs/winetest/winetest.rc
+++ b/programs/winetest/winetest.rc
@@ -82,5 +82,3 @@ END
/* @makedep: winetest.ico */
IDI_WINE ICON "winetest.ico"
-
-#include "tests.rc"
diff --git a/tools/make_makefiles b/tools/make_makefiles
index 99a120c..b1766a7 100755
--- a/tools/make_makefiles
+++ b/tools/make_makefiles
@@ -74,8 +74,8 @@ my @ignores = (
"dlls/*/tests/testlist.c",
"include/config.h",
"include/stamp-h",
- "programs/winetest/tests.rc",
"programs/winetest/*_test.exe",
+ "programs/winetest/*_test.rc",
);
# Source files and their resulting target to ignore
More information about the wine-cvs
mailing list