-
Notifications
You must be signed in to change notification settings - Fork 40
/
combine.bat
72 lines (55 loc) · 1.19 KB
/
combine.bat
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
@echo off
echo ...
echo ...
echo ...
echo ...
echo ...
echo ...
echo cleaning files
cd %1
del /q .\compiled\*.*
del /q .\temp\*.*
:: -----------------------------------
echo copying files to source
:: -----------------------------------
xcopy /s /y /i .\src\cpp .\temp
xcopy /y /i .\lzz.exe .\temp
cd temp
:: -----------------------------------
echo running lzz
:: -----------------------------------
set /a totalhpp=0;
for %%f in (*.hpp) do (
echo %%f
lzz -hx e -sx h %%f
set /a totalhpp+=1
)
:: -----------------------------------
echo copying headers to one file
:: -----------------------------------
copy /b .\*.e .\f00270_headers.h
set /a totale=0;
for %%f in (*.e) do (
set /a totale+=1
echo. > %%f
)
:: -----------------------------------
echo tothpp
echo %totalhpp%
echo tote
echo %totale%
:: -----------------------------------
if %totale% == %totalhpp% (
echo .
) else (
start "" cmd /c "echo. Error with LZZ check console output.&echo(&pause"
)
for %%f in (*.h) do (
echo. >> %%f
)
cd ..
:: -----------------------------------
echo copying files to compiled
:: -----------------------------------
xcopy /s /y /i .\temp\*.e .\compiled
copy /b .\temp\*.h .\compiled\main.cpp