We value your input!
Please participate in Archicad 28 Home Screen and Tooltips/Quick Tutorials survey

Archicad C++ API
About Archicad add-on development using the C++ API.

Dev builds vs. Production builds

MudratDetector
Enthusiast

Greetings to all,


ArchiCAD 27.4001 + WIN10 + VS 2019

I am having trouble  with my users loading my add-ons.  In short, an add-on will load for me, but not anyone else.

 

The details:
I keep an area for development code [G:\dev\v22, and similar] separate from an area for production code [G:\bin_22. and similar]:

MudratDetector_0-1701976622960.png

 

I set my pointer in the Add-On Manager to the dev area:

MudratDetector_1-1701976746099.png

and the pointer of the production staff to the production area:

MudratDetector_2-1701976835102.png

When my development effort reaches a bug free milestone, I copy the .apx file, and only the .apx file, from deep in the dev area to the production area associated with the appropriate ArchiCAD version, making it available to all of the users on the production staff.  This strategy has worked well for me since AC22.

However, in AC27, when I copy a successful build for an add-on that works for me and my dev environment

MudratDetector_3-1701977478696.png

to the production environment, the same exact .apx file will not load for any of the users in my test group.

MudratDetector_0-1701984063927.png

I have verified that network connection is active.

I have verified that we all are running the same build.

I have verified the setting of the Add-On Manager pointer.

 

Another oddity is that when I switch to the production environment, these add-ons load fine.  When I switch a user to my dev environment, the add-on will not load.

Any ideas?


Thanks for checking this out with me,

Chris

Chris Gilmer
Intel i9-12950HX CPU @ 2.30GHz, 16 cores
NVIDIA GeForce RTX 3080
48.0 GB RAM
Windows 10 Pro 64-bit
4 REPLIES 4
kovacsv
Booster

My best guess is that something is not available on the users' computer that is needed for the Add-On to load. It may be a C++ redistributable or something like this. I would check the apx with dependency walker on the users' computer: https://www.dependencywalker.com/.

MudratDetector
Enthusiast

I am glad to hear this as it was what I am thinking.  However, I was hesitant to chase this as an answer since it has never been an issue in the past and I don't think all the users would have new laptops, that would be missing these dependencies.  I tend to confirm with the braintrust of the forum before I take off down a path of resolution.  Since, in my mind, there can be so many of these roads to wander down...

Thanks so much for the suggestion and the link.  I will let you know how it works.

 

All the best - chris

Chris Gilmer
Intel i9-12950HX CPU @ 2.30GHz, 16 cores
NVIDIA GeForce RTX 3080
48.0 GB RAM
Windows 10 Pro 64-bit
MudratDetector
Enthusiast

 

Update:  back from 10 day vacation...

I have looked into the installed differences between my computer and others in the studio with [Control Panel > Programs > Programs and Features].


The noticable differences that have been missing on other computers:
-- Microsoft .NET Runtime - 6.0.25 (x64)

-- Microsoft Visual C++ 2013 Redistributable 9x86) - 12.0.30501

Superceeded by 12.0.40664 in all cases.  Install of 12.0.30501 does not help.
Includes C++ 2010 thru C++ 2015-2022 Redistributables with both x86 and x64 versions.

-- sevaral assorted SDK packages

Should not be necessary for end users.

Includes API Dev Kit 23.3006 thru 27.3001 and .NET 5.0.416

-- several assorted and unrelated apps

Using the dependency walker utility, I am receiving over 200 "Error opening file.  The system cannot find the file specified (2)." messages on both my machine and the studio machines.

DdependencyWalker.JPG 


Will continue to investigate with the other two IT giuys to detect differences between environments.  Any ideas to point us in the right direction are appreciated.

 

Chris

Chris Gilmer
Intel i9-12950HX CPU @ 2.30GHz, 16 cores
NVIDIA GeForce RTX 3080
48.0 GB RAM
Windows 10 Pro 64-bit
MudratDetector
Enthusiast

Solution for my situation:

In CMakeLists.txt file, I made this edit:

 

# set (CMAKE_CONFIGURATION_TYPES Debug;Release;RelWithDebInfo)
set (CMAKE_CONFIGURATION_TYPES Debug)

 

 

Using the dependency walker, I discovered my dev machine was using the .dll files marked here:

MudratDetector_0-1703785735480.png

I also discovered the production machines were missing these .dll files.

A bit of research into these files uncovered

MudratDetector_1-1703785937664.png

Reconfiguring CMake from 'Debug' to 'Release' mode solved the problem since the versions of these .dll files [without the 'D' suffix in the file name] were used by the Add-On and available on end user machines.

And one more key step [apparently] is to press the link in the .json file editor to 'Save and generate CMake cache to load variables'.  It is not enough [apparently] to Project > CMake Cache > Delete Cache and then Generate.

MudratDetector_0-1703875662853.png

 

 

Thanks @kovacsv for pointing me in the right direction and revealing a new tool for the toolbox.

 

All the best - Chris

Chris Gilmer
Intel i9-12950HX CPU @ 2.30GHz, 16 cores
NVIDIA GeForce RTX 3080
48.0 GB RAM
Windows 10 Pro 64-bit