Author Topic: DLL compile error: no resources  (Read 8423 times)

Sebastian Roll

  • Guest
DLL compile error: no resources
« on: January 31, 2006, 02:06:38 pm »
Hi all!

I try to produce a DLL from raknet sourcecode (raknet is a free multiplayer lib).
The only error I get is:

Windres.exe: no resources

I attached the resource .h/.res files in any place in C::B project-config I could found.
I get same error on compiling after using the Import-Wizard for Visula Studio 6.0 and .Net projects, which are provided by raknet.
Any ideas what to do?

cu, Sebastian Roll


sethjackson

  • Guest
Re: DLL compile error: no resources
« Reply #1 on: January 31, 2006, 02:11:44 pm »
Doesn't Windres.exe only work with .rc files????? NOT .res????

Offline tiwag

  • Developer
  • Lives here!
  • *****
  • Posts: 1196
  • sailing away ...
    • tiwag.cb
Re: DLL compile error: no resources
« Reply #2 on: January 31, 2006, 02:12:40 pm »
you need to add the proper directory in
Project->Build options->Directories->Resource compiler

Sebastian Roll

  • Guest
Re: DLL compile error: no resources
« Reply #3 on: January 31, 2006, 02:24:08 pm »
Thx for response.

Yes, You are right. It's a .rc file.

I have added the directory to Project->Build options->Directories->Resource compiler
Same error, though.

Sebastian Roll

  • Guest
Re: DLL compile error: no resources
« Reply #4 on: January 31, 2006, 02:27:52 pm »
here are the file contents:

DLL.rc:

Code
// Microsoft Visual C++ generated resource script.
//
#include "resource.h"

#define APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 2 resource.
//
#include "afxres.h"

/////////////////////////////////////////////////////////////////////////////
#undef APSTUDIO_READONLY_SYMBOLS

/////////////////////////////////////////////////////////////////////////////
// English (U.S.) resources

#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
LANGUAGE 9, 1
#pragma code_page(1252)

#ifdef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// TEXTINCLUDE
//

1 TEXTINCLUDE 
BEGIN
    "resource.h\0"
END

2 TEXTINCLUDE 
BEGIN
    "#include ""afxres.h""\r\n"
    "\0"
END

3 TEXTINCLUDE 
BEGIN
    "\r\n"
    "\0"
END

#endif    // APSTUDIO_INVOKED

#endif    // English (U.S.) resources
/////////////////////////////////////////////////////////////////////////////



#ifndef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 3 resource.
//


/////////////////////////////////////////////////////////////////////////////
#endif    // not APSTUDIO_INVOKED


resource.h:

Code
//{{NO_DEPENDENCIES}}
// Microsoft Visual C++ generated include file.
// Used by DLL.rc

// Next default values for new objects
//
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE        101
#define _APS_NEXT_COMMAND_VALUE         40001
#define _APS_NEXT_CONTROL_VALUE         1001
#define _APS_NEXT_SYMED_VALUE           101
#endif
#endif

Offline tiwag

  • Developer
  • Lives here!
  • *****
  • Posts: 1196
  • sailing away ...
    • tiwag.cb
Re: DLL compile error: no resources
« Reply #5 on: January 31, 2006, 02:32:32 pm »
I have added the directory to Project->Build options->Directories->Resource compiler

you may need to edit your resource file in order to get out all the VS crap

post your project (only sorce code and project files) as zip-file here

Sebastian Roll

  • Guest
Re: DLL compile error: no resources
« Reply #6 on: January 31, 2006, 02:40:46 pm »
You are very kind, tiwag. I will do that in aprox. 5 hours (my boss gets around).

Offline Michael

  • Lives here!
  • ****
  • Posts: 1608
Re: DLL compile error: no resources
« Reply #7 on: January 31, 2006, 08:50:34 pm »
I get same error on compiling after using the Import-Wizard for Visula Studio 6.0 and .Net projects, which are provided by raknet.

I have imported in C::B the .NET solution and with some small modifications of some projects got it to work. You can search for my posts (two I think), by using advanced search with "Import solution" and my name "Michael".

Best wishes,
Michael
 

Sebastian Roll

  • Guest
Re: DLL compile error: no resources
« Reply #8 on: February 01, 2006, 08:56:57 am »
Ok, I managed to compile the raknet DLL.
Like tiwag said, You have to throw some Visual Studio generated crap in file "resource.rc" away.

Here is the new file content:

Code

#include "resource.h"

1 TEXTINCLUDE 
BEGIN
    "resource.h\0"
END

2 TEXTINCLUDE 
BEGIN
    "#include ""afxres.h""\r\n"
    "\0"
END

3 TEXTINCLUDE 
BEGIN
    "\r\n"
    "\0"
END


Problem is solved.
Error message "Windres.exe: no resources" no longer exists.
Thank You all.