Setting link priority for traditional Synergy in Visual Studio

You can control the link order for referenced items for a traditional Synergy program by setting priority levels for these items. The higher the setting, the closer the library will be to the end of the link command generated behind the scenes for a build—i.e., the higher the priority. (The default is 0.) If a project has a reference to two libraries that have definitions for entities with the same name, the definition in the library with the higher priority setting will be used.

For example, you can use this feature to patch or replace an ELB by including an ELB that contains only stub routines in your build, giving this ELB the highest priority level, and then later distributing an ELB with the same name, but with implemented routines.

To set the priority for a referenced item, open the .synproj file for your project and add the following (where n is a negative or positive number) to the <reference> tag for the item:

<priority>"n"</priority>

For example, the following gives higher priority to MYDBO.DBO, so if both have a definition with the same name, the definition in MYDBO.DBO will be used:

<reference include="C:\mydir\MYDBO.DBO">
<priority>5</priority>
</reference>
<projectreference include="..\somedir\someproj.synproj">
<name>someproj</name>
<project>{5c8de8c8-10d7-4f87-8d62-34f1fba4dcd0}</project>
<private<True</private>
<priority>-2</priority>
</projectreference>