12-13-2011 03:56 PM
How do I put a debug build of an executable into a distribution? The distribution editor doesn't seem to be able to accommodate this.
I want to to distribute a debug build since I can afford the hit in execution speed and if I encounter an exception or library error I'll get a popup that will help me debug the deployed application.
Surely there's a way to do this? It looks like the distribution error simply refuses to recognize a debug executable as a candidate file for inclusion in the distribution.
12-13-2011 04:00 PM
My bad. Wasn't in the right directory to see the debug build. I just removed the release build executable and added the debug build executable.
12-13-2011 08:14 PM
Well, you know, I kind of take it back
When I go to build the distribution kit, it insists on kicking the mode into release mode, and rebuilding the release executable, even though I don't put it into the distribution. So I have to separately ensure I have a good debug build created before I create the dist kit since it won't build a good debug executable for me.
And I've renewed my frustration with the poorly designed dist editor GUI - NI hacks long dependency names into the target files window, then you scroll all the way to the right to view them only to realize that you still can't see the entire set of file names and you have to hover the cursor for a couple of seconds to get a balloon to come up that finally shows you the file names. Kindof makes you wonder what NI was thinking.
12-14-2011 02:33 AM
Hi menchar,
I could not investigate as deeply as you did, but there might be a workaround:
You can identically name the debug and release exe's and manually replace the release with the debug (which you previously built into another folder) just before hitting the Build button.
This works only if NI only looks for the file with its path/name and does not double check (during kit build-up) whether it is a release or debug version.
Hope this helps,
12-14-2011 02:41 AM
ebalci -
Thanks for the reply.
I'm still trying to figure out if I can do this.
I decline the project rebuild when I create the distribution so as to prevent the distribution builder from changing the mode to release and forcing a release mode executable into the distribution. It looks to me as if this results in the (previously built) debug version of the executable going into the distribution.
I was surprised that there's no built-in way to do this, as I mentioned, it's convenient to deploy debug builds if you don't have any particular speed requirement.
Menchar
12-14-2011 05:21 AM
Hi,
I've asked for the same thing to NI support some weeks ago, and they told me it's impossible.
And so I wrote this new product suggestion.
Feel free to give it kudos...
12-14-2011 01:35 PM
Yup, that's what you're asking for.
I wound up just doing a brute force file insertion into the distribution by not using the default target and target dependency selections - those are the items that the editor forces into release mode, if you try to incude either of these it not only doesn't work, it will insist on rebuilding everything in release mode.
I simply placed the debug executable and corresponding debug versions of the dependencies (some DLL's) directly into the distribution and then it all made sense - built the distribution all OK, didn't force the IDE into release mode, and didn't try to force release mode items into the distribution.
So it all does actually make sense, the confusion arises when you try to have the distribution editor doing anything automatically for you in anything except the release mode. And it turns out all that really means is that you don't have the executable and dependencies automatically inserted.
12-14-2011 01:42 PM - edited 12-14-2011 01:42 PM
Looks like somebody's hacked the NI discussion forum or else it's NI's idea of a joke - I got logged in as something other than my registered user name. Seems OK from a different machine.
12-15-2011 09:46 AM
Menchar,
Is it possible that someone logged you off of your account on the machine you had been on, then created a username and logged you in, as a joke? Seems the account was made recently.
Regards,
Kyle Mozdzyn
Applications Engineering
National Instruments
12-15-2011 02:12 PM
Don't believe it happened on this end. The two machines I used are side by side.
I was having trouble getting logged in.
Wonder if it's a default username in a script for the site