Aircraft DLL loading problem

For topics related to the creation of simulation objects (SimObjects). This includes development of aircraft, ground, and maritime vehicles.
TheIronDuke
Posts: 18
Joined: Wed Oct 22, 2014 9:43 pm

Aircraft DLL loading problem

Postby TheIronDuke » Sun Sep 30, 2018 4:51 am

I have developed an aircraft that uses a DLL to drive many gauge display elements. I have added it on my system using the add-on.xml method. It is a DLL compiled in Visual Studio 2015. It works fine on my computer.

I have sent it to several other people for testing, but the driver will not load on their systems. The add-on.xml file is formatted correctly, with the correct path to the driver. P3D auto-detect did pick it up, and the users have accepted it the first time the simulator ran. It is listed as enabled on the simulator's addon menu. But the dll is simply not loading on their computers.

What would make it work on my system, but not on others? Any ideas would be appreciated.

User avatar
WarpD
Posts: 1453
Joined: Mon Feb 14, 2011 5:29 am

Re: Aircraft DLL loading problem

Postby WarpD » Sun Sep 30, 2018 7:22 am

One or more dependencies are missing on their system.
Ed Wilson
Senior Developer
Mindstar Aviation

TheIronDuke
Posts: 18
Joined: Wed Oct 22, 2014 9:43 pm

Re: Aircraft DLL loading problem

Postby TheIronDuke » Sun Sep 30, 2018 1:50 pm

I had them check to make sure they have the Microsoft Visual C++ 2015 Redistributable package installed. What other dependencies would effect this?

TheIronDuke
Posts: 18
Joined: Wed Oct 22, 2014 9:43 pm

Re: Aircraft DLL loading problem

Postby TheIronDuke » Sun Sep 30, 2018 2:33 pm

You are referring to the C++ Optimization and Code Generation settings?

User avatar
WarpD
Posts: 1453
Joined: Mon Feb 14, 2011 5:29 am

Re: Aircraft DLL loading problem

Postby WarpD » Sun Sep 30, 2018 3:23 pm

That would be impossible for anyone here to say.

You need to use a dependency checker on their systems to see what it needs that is missing.

Understand, you've actually given no information regarding your code other than it's a DLL. That is, in short, saying pretty much nothing. With nothing to actually consider, I'm offering the most generic of information.
Ed Wilson
Senior Developer
Mindstar Aviation

dsdawson
Posts: 36
Joined: Sat Jan 14, 2012 5:46 pm

Re: Aircraft DLL loading problem

Postby dsdawson » Sun Sep 30, 2018 3:34 pm

The debug versions of the runtime libary files are not included with the redistributable package.
If your dll is still compiled as a debug build, it will only load on a system that has the appropriate version of Visual Studio installed.

TheIronDuke
Posts: 18
Joined: Wed Oct 22, 2014 9:43 pm

Re: Aircraft DLL loading problem

Postby TheIronDuke » Sun Sep 30, 2018 10:26 pm

The dll is compiled in release version. I have set the Runtime Library setting to Multi-threaded (/MT) and sent it to my testers again. Waiting for some response.

I have the driver installing into the Program Files directory structure. Could an access/permissions issue be a problem?

User avatar
WarpD
Posts: 1453
Joined: Mon Feb 14, 2011 5:29 am

Re: Aircraft DLL loading problem

Postby WarpD » Mon Oct 01, 2018 2:28 pm

Only if you're attempting to modify files within that protected zone. Having the sim load a DLL in that zone, on it's own, wouldn't be a security issue.

You keep calling this DLL a driver... I am hoping that's a misnomer as drivers aren't normally loaded at application levels. Like I said, you're not giving us much to go on to assist.
Ed Wilson
Senior Developer
Mindstar Aviation

TheIronDuke
Posts: 18
Joined: Wed Oct 22, 2014 9:43 pm

Re: Aircraft DLL loading problem

Postby TheIronDuke » Mon Oct 01, 2018 5:16 pm

Yes, the term "Driver" is being used loosely here. It is a DLL file that is intended to load when the simulator starts, to process data used by the aircraft displays. The add-on.xml file uses category <Category>DLL</Category>.

I have compiled the DLL using the Multi-threaded (/MT) runtime library option in Visual Studio 2015. Could there be some other dependency that would make it work on my computer, but not others?

User avatar
WarpD
Posts: 1453
Joined: Mon Feb 14, 2011 5:29 am

Re: Aircraft DLL loading problem

Postby WarpD » Tue Oct 02, 2018 11:20 pm

Yes.
Ed Wilson
Senior Developer
Mindstar Aviation

TheIronDuke
Posts: 18
Joined: Wed Oct 22, 2014 9:43 pm

Re: Aircraft DLL loading problem

Postby TheIronDuke » Wed Oct 03, 2018 8:54 pm

What sort of thing should I be looking for?

User avatar
WarpD
Posts: 1453
Joined: Mon Feb 14, 2011 5:29 am

Re: Aircraft DLL loading problem

Postby WarpD » Wed Oct 03, 2018 9:23 pm

Without having the code in front of me, I honestly wouldn't know. Dependency Walker may be of value.
Ed Wilson
Senior Developer
Mindstar Aviation


Return to “Simulation Object Development Questions”

Who is online

Users browsing this forum: No registered users and 9 guests