2

We have two automated build job that run whenever someone attempts to checkin a change to the source control. One for i386 and one for amd64. I've always took it for granted, but one of our new employees asked why do we need them both and I couldn't give an honest answer. So the question is can a C# code compile for i386 but fail for amd64 (or vice versa) ?

Shmoopy
  • 5,334
  • 4
  • 36
  • 72

1 Answers1

3

C# should compile fine in one go when set to "Any CPU"

However, when the code is dependent on externals that have been complied for either 32 or 64 bit then you might need to create two build processes.

An alternative could be to make a dynamic loader of the platform specific libraries that decides what library to load at run-time. The might be tricky but might enable you to merge the two build processes.

Community
  • 1
  • 1
Emond
  • 50,210
  • 11
  • 84
  • 115