0

I've used @jeff_t's solution as presented here however i encountered several issues.

I have a lib that holds a resource file and set as an external file, file name is

Other Files\myfile.exe

A quick look onto the rc file reveals the following line:

IDR_RES RES                     "Other Files\\myfile.exe"

Now, i set a DLL project which lays at the same directory level as the LIB and includes both resource.h(Read only symbol directives #include "../LIBProj/resource.h") and LIB.rc(Compile time directives #include "../LibProj/LibProj.rc")

Compiling the LIB goes smoothly, however, when i try to compile the DLL, which links against LIB, results the following error:

../LibProj/LibProj.rc(52): error RC2135: file not found: Other Files\myfile.exe

I do understand that once the linker tries to access additional includes from the DLL projects, it goes out off scope, how to i fix it?

Edit: if i give an absolute path as follows: IDR_GNRC_RES_AGENT_DATA RES "C:\\Develop\\Code\\LibProb\\Other Files\\myfile.exe"

it works well

Community
  • 1
  • 1
igal k
  • 1,883
  • 2
  • 28
  • 57

1 Answers1

0

After many hours of desperate tries, i realized the solution was quite simple. I had to use the following path:

IDR_FILE RES   "..\LIBProj\Other_Files\\MyFile.exe"

So for both projects that would work. LibProj wont be affected, because we go to the parent directory, and then return back. and for the DllProj we go to parent directory which holds both Lib & Dll projects, and then enter Lib's directory.

igal k
  • 1,883
  • 2
  • 28
  • 57