-
Reimp-Dev C++
My computer wont allow me to use the reimp tool to convert the directX SDK libs to mingw compatible ones. For some reason cmd wont recognise reimp. Could anybody post a downloaded to the converted libs or surgest a way to get it working. Thanks in advance
-
-
Yeah, I tried searching before and found that. Followed it all and it still doesn't work. It says stuff like %%f not expected.
-
What exactly is 'it'? Help us to help you by providing clear details about exactly what the problem is and in exactly which context you have encountered this problem.
-
Start>Run>cmd. When I type the first lines from
'rem filename: convert.cmd
set path=path_to_your_mingw/bin_directory;%path%
for %%f in (*.lib) do reimp %%f
rem the following are optional; omit if you want all of reimp's unmodified output
del *.def
del *.obj
move libd3dx9_30.a libd3dx9.a
move libd3dx9d_30.a libd3dx9d.a'
it appears to recognise these commands. Then when I try type the line 'for %%f in (*.lib) do reimp %%f ' and cmd comes back saying '%%f is not recognised as an internal or external command, operable program or batch file'
-
Okay, I'll go back and edit that a bit more to make it clearer what I meant.
The part you are referring to is meant to be run as a batch file - paste the contents into a text file and call that file something like 'convert.cmd' or 'convert.bat' then run it from the command prompt by just typing the file name. Please remember to replace the part that reads 'path_to_your_mingw/bin_directory' with your actual path to your mingw bin directory.
The previous section(i-vi) to the one you are referring to can be entered explicitly in sequence from the command prompt, ie.
Code:
set path=path_to_your_mingw/bin_directory;%path%
for %f in (*.lib) do reimp %f
del *.obj
del *.def
move libd3dx9_30.a libd3dx9.a
move libd3dx9d_30.a libd3dx9d.a
-
Ok, I got the .a libs but I dont get the bit about the linking.
-
Project menu --> Project options, parameters tab. Add the library names to the 'Linker' field using the -l (lowercase 'L') prefix and the name of the library, without the 'lib' prefix or file extension. For example, libd3d9.a would be entered into the 'Linker' field as -ld3d9. If you've put the directx libraries in a separate directory to your dev-cpp/mingw 'lib' directory, then you'll need to provide the path to that, too - in this situation it would probably be simplest just to use the 'Add library or object' button to add the necessary libraries to the 'Linker' field.