Reco.yml not parsed correctly


#1

I’ve run into a problem on Windows where the new SMI protocol YAML file (reco.yml) is not being parsed correctly. The error looks like this:

cd /opt/sdaccel-builder/eTeak && PATH=/opt/sdaccel-builder/eTeak/bin:/opt/sdaccel-builder/smi/bin:/opt/sdaccel-builder/go-root/bin:/opt/Xilinx/SDx/2017.1.op/bin:/opt/sdaccel-builder:/opt/Xilinx/SDx/2017.1.op/Vivado/bin:/opt/Xilinx/SDx/2017.1.op/bin:/opt/Xilinx/SDx/2017.1.op/Vivado/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin GOPATH="/mnt/.reco-work/vendor" /usr/bin/time -ao /mnt/times.out -f "verilog,%e,%M" ./go-te /mnt/main.go -o "/mnt/.reco-work/sdaccel/verilog"/main.v
'ption --ports: cannot parse value `2
Usage: go-teak-smi build [-v|--verbose] [--dump-trees] [--no-inline-calls]
                         [--debug-optimizations] [--test-protocol] [-O]
                         [-p|--passes INT] [-o ARG] [--full-imports]
                         [--ports INT] FILE
  Compile go to verilog
make: *** ["/mnt/.reco-work/sdaccel/verilog"/main.v] Error 1
/opt/sdaccel-builder/sdaccel-builder.mk:118: recipe for target '"/mnt/.reco-work/sdaccel/verilog"/main.v' failed
b662be8d-f40d-4a63-8d37-66069dcc8859

I think I’ve tracked this down to being caused by the Github CRLF “thing” …when the ReconfigureIO/examples repo is cloned from Github to a Windows platform, the reco.yml file has 0d0a at the end of lines (i.e CRLF). The same repo cloned to a linux machine maintains the 0a (LF) character and works ok.

I suspect that the reco tools are not able to parse reco.yml files with CRLF line endings…or maybe the repo needs to have a .gitattributes file to explicitly maintain the LF line ending?


#2

If the .gitattributes file looks like this:

# reco.yml line endings need to be forced to be LF (0x0A)
reco.yml text eol=lf

…then the 0x0a line ending is maintained when cloning to windows.


#3

Hey there,

We’re testing an improvement to the robustness of reco.yml parsing currently, if all goes well it’ll be released soon. Among other things this should put an end to line endings from different platforms causing build failures.