views:

91

answers:

1

A bit of an odd question here, but AutoCAD uses extension DLL's with the .ARX extension, which are really exactly like regular DLL's, besides their extension.

Now we have built three .ARX files, where the two latter ones have dependencies to the first. Upon loading these two, AutoCAD complains that it can't find a required file, and when using the Dependency Walker tool, it becomes apparent that the Visual C++ 2008 linker has generated references to the first file, but by using the .DLL extension. I think this is our problem. It goes looking for A.DLL for some exported functions, but this file is in reality named A.ARX.

Can Visual Studio projects be configured so that it'll link to files with an ARX extension, instead of generating this seemingly faulty code?

Update: This is about C++ DLL's.

+1  A: 

Not sure why you need to statically link to another ACAD adobe extension. The shared function probably should be refactored into another DLL. Alternatively you can change the output file name generated in the export lib file.

Sheng Jiang 蒋晟
You mean dynamically link? Yes, I could probably duplicate my code in the other two extensions, it's just that I thought this could be way easier to solve than I first assumed. I have already changed the output filename with an /OUT: directive, but the problem is that at link time, the linker seem to assume I'm intending to link to a DLL with a DLL extension, and only later, when writing the respective final outputs, are they named .ARX.I have now solved this by binary editing the output files, but since that's a kludge, I'll keep this question open for now.
Jonas
strange, I created a C++ DLL in VC2005, changed the output file name in settings, liked the generated lib and my exe loads the file without the dll extension.
Sheng Jiang 蒋晟