Building for release, but EHR code generating errors

This forum is for programmers who have questions about the source code.
Post Reply
User avatar
wjstarck
Posts: 949
Joined: Tue Jul 31, 2007 7:18 am
Location: Keller, TX
Contact:

Building for release, but EHR code generating errors

Post by wjstarck »

I can't build the current head for release (x86) unless I comment out all the EHR code, which is in contained in an #if DEBUG.

The problem code follows the '#else'

How do I fix this?
Cheers,

Bill Starck, DDS
Big Idea Software, LLC
Developer, EASy(Electronic Anesthesia System) for Open Dental
817-807-1709
TX, USA
User avatar
jordansparks
Site Admin
Posts: 5776
Joined: Sun Jun 17, 2007 3:59 pm
Location: Salem, Oregon
Contact:

Re: Building for release, but EHR code generating errors

Post by jordansparks »

Fix committed. Can you tell we don't compile the head in release mode very often?
Jordan Sparks, DMD
http://www.opendental.com
okojava88
Posts: 2
Joined: Tue Jan 28, 2025 3:53 am

Re: Building for release, but EHR code generating errors

Post by okojava88 »

The issue you're facing seems to be related to conditional compilation directives, specifically the

Code: Select all

#if DEBUG
block. When building for release, the code following #else is included, and this section likely contains functionality or references that cause errors in a non-debug context.

To fix this, start by reviewing the code in the

Code: Select all

#else
block and ensure it is suitable for a release build. It might depend on variables, methods, or libraries that are not properly configured for the release configuration. Addressing any missing dependencies or incomplete implementations in this block should resolve the issue.

If the EHR code is exclusively for debugging purposes, consider refactoring it or ensuring that it doesn’t run in a release build. You can also implement fallback or alternative logic for the release build if needed. After making these changes, test both the debug and release builds to verify that everything works as intended.

For healthcare projects like this, structuring the code efficiently is crucial. If you’re working on something related to EHR systems, you might find inspiration in (spam url removed by Jordan) to apply best practices.
User avatar
wjstarck
Posts: 949
Joined: Tue Jul 31, 2007 7:18 am
Location: Keller, TX
Contact:

Re: Building for release, but EHR code generating errors

Post by wjstarck »

Not sure if you noticed or not, but this post is literally 14 years old :lol:
Cheers,

Bill Starck, DDS
Big Idea Software, LLC
Developer, EASy(Electronic Anesthesia System) for Open Dental
817-807-1709
TX, USA
User avatar
jordansparks
Site Admin
Posts: 5776
Joined: Sun Jun 17, 2007 3:59 pm
Location: Salem, Oregon
Contact:

Re: Building for release, but EHR code generating errors

Post by jordansparks »

Yeah, pretty sure it's spam. Removing links until I can be sure.
Jordan Sparks, DMD
http://www.opendental.com
Post Reply