8 rm -rf YosysVS-Tpl-v2.
zip YosysVS
9 wget http
://www.clifford.at
/yosys
/nogit
/YosysVS-Tpl-v2.
zip
11 unzip YosysVS-Tpl-v2.
zip
12 rm -f YosysVS-Tpl-v2.
zip
16 n
=$
(grep -B999 '<ItemGroup>' "$vcxsrc"/YosysVS
/YosysVS.vcxproj |
wc -l)
17 head -n$n "$vcxsrc"/YosysVS
/YosysVS.vcxproj
18 egrep '\.(h|hh|hpp|inc)$' srcfiles.txt |
sed 's,.*,<ClInclude Include="../yosys/&" />,'
19 egrep -v '\.(h|hh|hpp|inc)$' srcfiles.txt |
sed 's,.*,<ClCompile Include="../yosys/&" />,'
20 echo '<ClCompile Include="../yosys/kernel/version.cc" />'
21 tail -n +$
((n
+1)) "$vcxsrc"/YosysVS
/YosysVS.vcxproj
22 } > "$vcxsrc"/YosysVS
/YosysVS.vcxproj.new
24 mv "$vcxsrc"/YosysVS
/YosysVS.vcxproj.new
"$vcxsrc"/YosysVS
/YosysVS.vcxproj
26 mkdir
-p "$vcxsrc"/yosys
27 tar -cf - -T srcfiles.txt |
tar -xf - -C "$vcxsrc"/yosys
28 cp -r share
"$vcxsrc"/
30 echo "namespace Yosys { extern const char *yosys_version_str; const char *yosys_version_str=\"Yosys" \
31 "$yosysver (git sha1 $gitsha, Visual Studio)\"; }" > "$vcxsrc"/yosys
/kernel
/version.cc
33 cat > "$vcxsrc"/readme-git.txt
<< EOT
34 Want to use a git working copy for the yosys source code?
35 Open "Git Bash" in this directory and run:
38 git clone https://github.com/cliffordwolf/yosys.git yosys
40 git checkout -B master $(git rev-parse HEAD | cut -c1-10)
44 cat > "$vcxsrc"/readme-abc.txt
<< EOT
45 Yosys is using "ABC" for gate-level optimizations and technology
46 mapping. Download yosys-win32-mxebin-$yosysver.zip and copy the
47 following files from it into this directory:
53 sed -i 's/$/\r/; s/\r\r*/\r/g;' "$vcxsrc"/YosysVS
/YosysVS.vcxproj
"$vcxsrc"/readme-git.txt
"$vcxsrc"/readme-abc.txt