# "Build Delphi" action doesn't support $(MSBuildProjectName)

**URL:** https://www.finalbuilder.com/forums/t/build-delphi-action-doesnt-support-msbuildprojectname/3467
**Category:** Bugs
**Created:** [February 27, 2013, 1:00am UTC](https://www.finalbuilder.com/forums/t/build-delphi-action-doesnt-support-msbuildprojectname/3467 "2013-02-27T01:00:02Z")
**Posts on this page:** 8
**Page:** 1

<div class="post-metadata">

### Author: ![nkawabe](https://www.finalbuilder.com/forums/letter_avatar_proxy/v4/letter/n/db5fbb/32.png) [@nkawabe](https://www.finalbuilder.com/forums/u/nkawabe)
#### Post date: [February 27, 2013, 1:00am UTC](https://www.finalbuilder.com/forums/t/build-delphi-action-doesnt-support-msbuildprojectname/3467/1 "2013-02-27T01:00:02Z")

</div>

Hi,

I noticed that “Build Delphi” action doesn’t support $(MSBuildProjectName) variable.

I’m using this variable to separate dcu output directories by building exe like below.

&ltDCC\_DcuOutput&gt\_dcu\<b\>$(MSBuildProjectName)$(Platform)$(Config)&lt/DCC\_DcuOutput&gt

I prefer above one to below one.

&ltDCC\_DcuOutput&gt\_dcu\<b\>ActualProjectName$(Platform)$(Config)&lt/DCC\_DcuOutput&gt

Both Delphi IDE & msbuild support this variable.

I understand it’s tough to support all MSBuild variables available while building delphi,

but could you support basic variable like $(MSBuildProjectName) ?

# I don’t know other “basic” variable exists

---

<div class="post-metadata">

### Author: ![Vincent](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/vincent/32/938_2.png) [@Vincent](https://www.finalbuilder.com/forums/u/Vincent)
#### Post date: [February 27, 2013, 1:10am UTC](https://www.finalbuilder.com/forums/t/build-delphi-action-doesnt-support-msbuildprojectname/3467/2 "2013-02-27T01:10:41Z")

</div>

We don’t support MSBuild variables for the Delphi action because we don’t use MSBuild for delphi.   
  
 FinalBuilder supports delphi 3 to XE3, not all versions had MSbuild support, and in any event the MSBuild support is not very stable.

---

<div class="post-metadata">

### Author: ![nkawabe](https://www.finalbuilder.com/forums/letter_avatar_proxy/v4/letter/n/db5fbb/32.png) [@nkawabe](https://www.finalbuilder.com/forums/u/nkawabe)
#### Post date: [February 27, 2013, 2:43am UTC](https://www.finalbuilder.com/forums/t/build-delphi-action-doesnt-support-msbuildprojectname/3467/3 "2013-02-27T02:43:12Z")

</div>

> Posted By Vincent Parrett on 27 Feb 2013 06:10 AM  
>    
> We don't support MSBuild variables for the Delphi action because we don't use MSBuild for delphi.

   
  
 Hmm..   
   
 "Build Delphi" doesn't use MSBuild, but the variables like $(Platform),$(Config) is supported.   
   
 These variable are also MSBuild variables.

---

<div class="post-metadata">

### Author: ![nkawabe](https://www.finalbuilder.com/forums/letter_avatar_proxy/v4/letter/n/db5fbb/32.png) [@nkawabe](https://www.finalbuilder.com/forums/u/nkawabe)
#### Post date: [March 5, 2013, 8:11am UTC](https://www.finalbuilder.com/forums/t/build-delphi-action-doesnt-support-msbuildprojectname/3467/4 "2013-03-05T08:11:50Z")

</div>

> Posted By Vincent Parrett on 27 Feb 2013 06:10 AM   
> We don't support MSBuild variables for the Delphi action because we don't use MSBuild for delphi.

   
  
 I misunderstood about variables and I confirmed you are right.   
 Build delphi action ignores all MSBuild variablesin dcu,etc's path output settings.   
   
 (It doesn't produce any warnings ! just produce dcu to the default destination (same folder as .pas exists)...)   
 

I'm not satisfied about this implementation, even I feel it's annoying I'll repost about this there.

---

<div class="post-metadata">

### Author: ![Vincent](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/vincent/32/938_2.png) [@Vincent](https://www.finalbuilder.com/forums/u/Vincent)
#### Post date: [March 5, 2013, 1:20am UTC](https://www.finalbuilder.com/forums/t/build-delphi-action-doesnt-support-msbuildprojectname/3467/5 "2013-03-05T01:20:02Z")

</div>

You can use the same settings as the delphi IDE. On the Delphi action Project tab, there are options to load the settings from the delphi project file (dproj). You can control which settings are loaded.

---

<div class="post-metadata">

### Author: ![nkawabe](https://www.finalbuilder.com/forums/letter_avatar_proxy/v4/letter/n/db5fbb/32.png) [@nkawabe](https://www.finalbuilder.com/forums/u/nkawabe)
#### Post date: [March 6, 2013, 11:14am UTC](https://www.finalbuilder.com/forums/t/build-delphi-action-doesnt-support-msbuildprojectname/3467/6 "2013-03-06T11:14:51Z")

</div>

> You can use the same settings as the delphi IDE. On the Delphi action Project tab, there are options to load the settings from the delphi project file (dproj). You can control which settings are loaded.

   
  
 Mmm, I already uses this setting.   
   
 I can't share Directories settings if I use MSBuild variables like $(Platform), $(Config) on the IDE(dproj).  
   
 I must uncheck Directories check box and I always have to override dproj's directories settings.  
   
 (Oh, I wish I had "Use Aliases from Project Settings File" ...)   
   
 

Recent delphi uses these MSBuild variables by default.  
   
 I think it's reasonable to support basic variables like Platform, Config, at least...  
   
 You already have "Platform", "Project Config" setting on Project tab.

---

<div class="post-metadata">

### Author: ![nkawabe](https://www.finalbuilder.com/forums/letter_avatar_proxy/v4/letter/n/db5fbb/32.png) [@nkawabe](https://www.finalbuilder.com/forums/u/nkawabe)
#### Post date: [March 6, 2013, 11:50am UTC](https://www.finalbuilder.com/forums/t/build-delphi-action-doesnt-support-msbuildprojectname/3467/7 "2013-03-06T11:50:19Z")

</div>

> I must uncheck Directories check box and I always have to override dproj's directories settings.

   
  
 I tried to override dcu output settings, but failed.  
   
 What settings / logs I should check ?  
   
 

Plaese see the following screen shot.  
   
 https://www.sugarsync.com/pf/D743662\_60057497\_064784

It creates .dcu on the same location as .pas exists.

---

<div class="post-metadata">

### Author: ![Vincent](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/vincent/32/938_2.png) [@Vincent](https://www.finalbuilder.com/forums/u/Vincent)
#### Post date: [March 7, 2013, 10:13am UTC](https://www.finalbuilder.com/forums/t/build-delphi-action-doesnt-support-msbuildprojectname/3467/8 "2013-03-07T10:13:00Z")

</div>

You can emulate the MSBuild variables, just declare them as FinalBuilder project variables and provide the values you want for them.
