Alexandre Julliard : makedep: Added support for dlldata.c dependencies.
Alexandre Julliard
julliard at winehq.org
Mon Dec 10 08:54:28 CST 2007
Module: wine
Branch: master
Commit: b9966054cf9dccd030acf84ff2e79a492a8b5a85
URL: http://source.winehq.org/git/wine.git/?a=commit;h=b9966054cf9dccd030acf84ff2e79a492a8b5a85
Author: Alexandre Julliard <julliard at winehq.org>
Date: Mon Dec 10 14:26:25 2007 +0100
makedep: Added support for dlldata.c dependencies.
---
tools/makedep.c | 48 ++++++++++++++++++++++++++++--------------------
1 files changed, 28 insertions(+), 20 deletions(-)
diff --git a/tools/makedep.c b/tools/makedep.c
index e96cdf6..2a8c14d 100644
--- a/tools/makedep.c
+++ b/tools/makedep.c
@@ -242,24 +242,6 @@ static INCL_FILE *find_src_file( const char *name )
}
/*******************************************************************
- * add_src_file
- *
- * Add a source file to the list.
- */
-static INCL_FILE *add_src_file( const char *name )
-{
- INCL_FILE *file;
-
- if (find_src_file( name )) return NULL; /* we already have it */
- file = xmalloc( sizeof(*file) );
- memset( file, 0, sizeof(*file) );
- file->name = xstrdup(name);
- list_add_tail( &sources, &file->entry );
- return file;
-}
-
-
-/*******************************************************************
* add_include
*
* Add an include file if it doesn't already exists.
@@ -717,6 +699,11 @@ static void parse_generated_idl( INCL_FILE *source )
{
add_include( source, header, 0, 0 );
}
+ else if (!strcmp( source->name, "dlldata.c" ))
+ {
+ add_include( source, "objbase.h", 0, 1 );
+ add_include( source, "rpcproxy.h", 0, 1 );
+ }
free( header );
free( basename );
@@ -733,7 +720,8 @@ static void parse_file( INCL_FILE *pFile, int src )
if (strendswith( pFile->name, "_c.c" ) ||
strendswith( pFile->name, "_i.c" ) ||
strendswith( pFile->name, "_p.c" ) ||
- strendswith( pFile->name, "_s.c" ))
+ strendswith( pFile->name, "_s.c" ) ||
+ !strcmp( pFile->name, "dlldata.c" ))
{
parse_generated_idl( pFile );
return;
@@ -758,6 +746,25 @@ static void parse_file( INCL_FILE *pFile, int src )
/*******************************************************************
+ * add_src_file
+ *
+ * Add a source file to the list.
+ */
+static INCL_FILE *add_src_file( const char *name )
+{
+ INCL_FILE *file;
+
+ if (find_src_file( name )) return NULL; /* we already have it */
+ file = xmalloc( sizeof(*file) );
+ memset( file, 0, sizeof(*file) );
+ file->name = xstrdup(name);
+ list_add_tail( &sources, &file->entry );
+ parse_file( file, 1 );
+ return file;
+}
+
+
+/*******************************************************************
* output_include
*/
static void output_include( FILE *file, INCL_FILE *pFile,
@@ -954,7 +961,8 @@ int main( int argc, char *argv[] )
for (i = 1; i < argc; i++)
{
- if ((pFile = add_src_file( argv[i] ))) parse_file( pFile, 1 );
+ add_src_file( argv[i] );
+ if (strendswith( argv[i], "_p.c" )) add_src_file( "dlldata.c" );
}
LIST_FOR_EACH_ENTRY( pFile, &includes, INCL_FILE, entry ) parse_file( pFile, 0 );
output_dependencies();
More information about the wine-cvs
mailing list