From 09ab02f6dafcef2d9e51abd00734d017f98d4bc1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Herv=C3=A9=20Poussineau?= Date: Wed, 3 Oct 2007 14:09:45 +0000 Subject: [PATCH] Remove usewrc attribute in rbuild files ; wrc should be able to compile all resources svn path=/trunk/; revision=29377 --- reactos/Makefile | 1 - .../rbuild/backend/mingw/modulehandler.cpp | 80 ++++++++----------- reactos/tools/rbuild/module.cpp | 6 -- reactos/tools/rbuild/project.dtd | 1 - reactos/tools/rbuild/rbuild.h | 1 - 5 files changed, 32 insertions(+), 57 deletions(-) diff --git a/reactos/Makefile b/reactos/Makefile index 89ac3ddbb9d..0447fc53d07 100644 --- a/reactos/Makefile +++ b/reactos/Makefile @@ -298,7 +298,6 @@ ar = $(Q)$(PREFIX_)ar objcopy = $(Q)$(PREFIX_)objcopy dlltool = $(Q)$(PREFIX_)dlltool strip = $(Q)$(PREFIX_)strip -windres = $(Q)$(PREFIX_)windres # Set utilities ifeq ($(OSTYPE),msys) diff --git a/reactos/tools/rbuild/backend/mingw/modulehandler.cpp b/reactos/tools/rbuild/backend/mingw/modulehandler.cpp index 4227ee2847a..1fa82bb3015 100644 --- a/reactos/tools/rbuild/backend/mingw/modulehandler.cpp +++ b/reactos/tools/rbuild/backend/mingw/modulehandler.cpp @@ -1095,55 +1095,39 @@ MingwModuleHandler::GenerateWindresCommand ( const FileLocation *objectFilename = GetObjectFilename ( sourceFile, &clean_files ); - if ( module.useWRC ) - { - string sourceFilenamePart = module.name + "." + ReplaceExtension ( sourceFile->name, "" ); - FileLocation rciFilename ( TemporaryDirectory, - "", - sourceFilenamePart + ".rci.tmp" ); - FileLocation resFilename ( TemporaryDirectory, - "", - sourceFilenamePart + ".res.tmp" ); + string sourceFilenamePart = module.name + "." + ReplaceExtension ( sourceFile->name, "" ); + FileLocation rciFilename ( TemporaryDirectory, + "", + sourceFilenamePart + ".rci.tmp" ); + FileLocation resFilename ( TemporaryDirectory, + "", + sourceFilenamePart + ".res.tmp" ); - fprintf ( fMakefile, - "%s: %s $(WRC_TARGET) | %s\n", - backend->GetFullName ( *objectFilename ).c_str (), - dependencies.c_str (), - backend->GetFullPath ( *objectFilename ).c_str () ); - fprintf ( fMakefile, "\t$(ECHO_WRC)\n" ); - fprintf ( fMakefile, - "\t${gcc} -xc -E -DRC_INVOKED ${%s} %s > %s\n", - windresflagsMacro.c_str (), - backend->GetFullName ( *sourceFile ).c_str (), - backend->GetFullName ( rciFilename ).c_str () ); - fprintf ( fMakefile, - "\t$(Q)$(WRC_TARGET) ${%s} %s %s\n", - windresflagsMacro.c_str (), - backend->GetFullName ( rciFilename ).c_str (), - backend->GetFullName ( resFilename ).c_str () ); - fprintf ( fMakefile, - "\t-@${rm} %s 2>$(NUL)\n", - backend->GetFullName ( rciFilename ).c_str () ); - fprintf ( fMakefile, - "\t${windres} %s -o $@\n", - backend->GetFullName ( resFilename ).c_str () ); - fprintf ( fMakefile, - "\t-@${rm} %s 2>$(NUL)\n", - backend->GetFullName ( resFilename ).c_str () ); - } - else - { - fprintf ( fMakefile, - "%s: %s $(WRC_TARGET) | %s\n", - backend->GetFullName ( *objectFilename ).c_str (), - dependencies.c_str (), - backend->GetFullPath ( *objectFilename ).c_str () ); - fprintf ( fMakefile, "\t$(ECHO_WRC)\n" ); - fprintf ( fMakefile, - "\t${windres} $(%s) %s -o $@\n", - windresflagsMacro.c_str (), - backend->GetFullName ( *sourceFile ).c_str () ); - } + fprintf ( fMakefile, + "%s: %s $(WRC_TARGET) | %s\n", + backend->GetFullName ( *objectFilename ).c_str (), + dependencies.c_str (), + backend->GetFullPath ( *objectFilename ).c_str () ); + fprintf ( fMakefile, "\t$(ECHO_WRC)\n" ); + fprintf ( fMakefile, + "\t${gcc} -xc -E -DRC_INVOKED ${%s} %s > %s\n", + windresflagsMacro.c_str (), + backend->GetFullName ( *sourceFile ).c_str (), + backend->GetFullName ( rciFilename ).c_str () ); + fprintf ( fMakefile, + "\t$(Q)$(WRC_TARGET) ${%s} %s %s\n", + windresflagsMacro.c_str (), + backend->GetFullName ( rciFilename ).c_str (), + backend->GetFullName ( resFilename ).c_str () ); + fprintf ( fMakefile, + "\t-@${rm} %s 2>$(NUL)\n", + backend->GetFullName ( rciFilename ).c_str () ); + fprintf ( fMakefile, + "\t${windres} %s -o $@\n", + backend->GetFullName ( resFilename ).c_str () ); + fprintf ( fMakefile, + "\t-@${rm} %s 2>$(NUL)\n", + backend->GetFullName ( resFilename ).c_str () ); } void diff --git a/reactos/tools/rbuild/module.cpp b/reactos/tools/rbuild/module.cpp index a4cc2eb7e3a..ae80bb93c7e 100644 --- a/reactos/tools/rbuild/module.cpp +++ b/reactos/tools/rbuild/module.cpp @@ -415,12 +415,6 @@ Module::Module ( const Project& project, else install = NULL; - att = moduleNode.GetAttribute ( "usewrc", false ); - if ( att != NULL ) - useWRC = att->value == "true"; - else - useWRC = true; - att = moduleNode.GetAttribute ( "allowwarnings", false ); if ( att == NULL ) { diff --git a/reactos/tools/rbuild/project.dtd b/reactos/tools/rbuild/project.dtd index dc2f887e0cf..9905a606610 100644 --- a/reactos/tools/rbuild/project.dtd +++ b/reactos/tools/rbuild/project.dtd @@ -123,7 +123,6 @@ underscoresymbols (true|yes|false|no) "no" installbase %Text; #IMPLIED installname %Text; #IMPLIED - usewrc %Text; #IMPLIED allowwarnings (true|false) "false" aliasof %Text; #IMPLIED unicode (true|yes|false|no) "no" diff --git a/reactos/tools/rbuild/rbuild.h b/reactos/tools/rbuild/rbuild.h index b29c1099175..ba4785cc5da 100644 --- a/reactos/tools/rbuild/rbuild.h +++ b/reactos/tools/rbuild/rbuild.h @@ -355,7 +355,6 @@ public: std::string prefix; HostType host; std::string aliasedModuleName; - bool useWRC; bool allowWarnings; bool enabled; bool isStartupLib;