Flare inserts a BOM or byte order mark in post build event

This forum is for all Flare issues not related to any of the other categories.
Post Reply
0Qq5Ew538tV
Propeller Head
Posts: 19
Joined: Wed Jun 06, 2018 11:51 am

Flare inserts a BOM or byte order mark in post build event

Post by 0Qq5Ew538tV »

We have several users that use Flare in our organization. Some of the users are experiencing an issue with the pre and post-build event commands. The issue only occurs when targets are built from the command line with madbuild.exe, not from the GUI.

We have a post-build event command that echoes some variables to a file:

Code: Select all

echo "$(TargetName)|$(ProjectDirectory)|$(OutputDirectory)" > %appdata%\mcoutput.fldat
It works on most of our machines, but it's failing on three people's machines.

Code: Select all

Run Command Error: '<0xfeff>echo' is not recognized as an internal or external command,
Run Command Error: operable program or batch file.
The reason it's failing is because Flare is inserting a UTF-16 BOM (byte order mark) before the command. The BOM is the <0xfeff>. This causes the post-build event script to fail.

This works on most users machines. It only fails on three user's machines, and we're at a loss as to why Flare is doing this.
Chicago_HPT
Sr. Propeller Head
Posts: 133
Joined: Sun Feb 03, 2013 6:01 pm

Re: Flare inserts a BOM or byte order mark in post build eve

Post by Chicago_HPT »

I've never used the command line to build (or run post-build events) myself so, out of curiosity, can you run a batch file from there? One of those error messages seems to indicate that you cannot. But, if you can, can you put your post build instructions (such as "echo") in the batch file?

-jeff
Post Reply