-
Notifications
You must be signed in to change notification settings - Fork 46
/
Makefile
67 lines (64 loc) · 5.18 KB
/
Makefile
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
ROOT = .
!include "$(ROOT)\system.mak"
all:
@if exist "$(MAKEDIR)\src\3rdparty\sqlite3\Makefile" cd "$(MAKEDIR)\src\3rdparty\sqlite3" && $(MAKE) /NOLOGO /$(MAKEFLAGS)
@if exist "$(MAKEDIR)\src\3rdparty\pcre\Makefile" cd "$(MAKEDIR)\src\3rdparty\pcre" && $(MAKE) /NOLOGO /$(MAKEFLAGS)
@if exist "$(MAKEDIR)\src\3rdparty\libiconv\Makefile" cd "$(MAKEDIR)\src\3rdparty\libiconv" && $(MAKE) /NOLOGO /$(MAKEFLAGS)
@if exist "$(MAKEDIR)\src\3rdparty\luajit\Makefile" cd "$(MAKEDIR)\src\3rdparty\luajit" && $(MAKE) /NOLOGO /$(MAKEFLAGS)
@if exist "$(MAKEDIR)\src\3rdparty\chardet\Makefile" cd "$(MAKEDIR)\src\3rdparty\chardet" && $(MAKE) /NOLOGO /$(MAKEFLAGS)
@if exist "$(MAKEDIR)\src\3rdparty\qrencode\Makefile" cd "$(MAKEDIR)\src\3rdparty\qrencode" && $(MAKE) /NOLOGO /$(MAKEFLAGS)
@if exist "$(MAKEDIR)\src\3rdparty\tinyexpr\Makefile" cd "$(MAKEDIR)\src\3rdparty\tinyexpr" && $(MAKE) /NOLOGO /$(MAKEFLAGS)
@if exist "$(MAKEDIR)\src\3rdparty\expat\Makefile" cd "$(MAKEDIR)\src\3rdparty\expat" && $(MAKE) /NOLOGO /$(MAKEFLAGS)
@if exist "$(MAKEDIR)\src\3rdparty\scintilla\Makefile" cd "$(MAKEDIR)\src\3rdparty\scintilla" && $(MAKE) /NOLOGO /$(MAKEFLAGS)
cd "$(MAKEDIR)\src"
@$(MAKE) /NOLOGO /$(MAKEFLAGS)
@if exist "$(MAKEDIR)\plugins\pdfview\Makefile" cd "$(MAKEDIR)\plugins\pdfview" && $(MAKE) /NOLOGO /$(MAKEFLAGS)
cd "$(MAKEDIR)\locales"
@$(MAKE) /NOLOGO /$(MAKEFLAGS)
cd "$(MAKEDIR)"
package: all
!IF "$(BITS)" == "64"
@if exist "$(MAKEDIR)\skylark_x64" rd /s/q "$(MAKEDIR)\skylark_x64"
@if exist "$(MAKEDIR)\skylark_x64.7z" del /s/q "$(MAKEDIR)\skylark_x64.7z"
@if not exist "$(MAKEDIR)\skylark_x64" mkdir "$(MAKEDIR)\skylark_x64"
@if exist "$(MAKEDIR)\skylark_x64" xcopy /y /e /d "$(BIND)" "$(MAKEDIR)\skylark_x64"&del /s/q/a/f "$(MAKEDIR)\skylark_x64\*.pdb" 2>&1>NUL
-@del /s/q/a/f "$(MAKEDIR)\skylark_x64\*.exp" 2>nul 1>nul
-@del /s/q/a/f "$(MAKEDIR)\skylark_x64\*.lib" 2>nul 1>nul
-@del /s/q/a/f "$(MAKEDIR)\skylark_x64\conf\*.sqlite3" 2>nul 1>nul
@if exist "%WindowsSdkDir%Redist\%WindowsSDKVersion%ucrt\DLLs\x64" copy /y "%WindowsSdkDir%Redist\%WindowsSDKVersion%ucrt\DLLs\x64\*" "$(MAKEDIR)\skylark_x64" 2>&1>NUL
@if exist "%VCToolsRedistDir%x64\Microsoft.VC142.CRT\msvcp140.dll" copy /y "%VCToolsRedistDir%x64\Microsoft.VC142.CRT\msvcp140.dll" "$(MAKEDIR)\skylark_x64" 2>&1>NUL
@if exist "%VCToolsRedistDir%x64\Microsoft.VC142.CRT\vcruntime140.dll" copy /y "%VCToolsRedistDir%x64\Microsoft.VC142.CRT\vcruntime140*.dll" "$(MAKEDIR)\skylark_x64" 2>&1>NUL
@7z a -t7z "$(MAKEDIR)\skylark_x64$(RELEASE_VERSION).7z" "$(MAKEDIR)\skylark_x64" -mx9 -r -y
!ELSE
@if exist "$(MAKEDIR)\skylark_x86" rd /s/q "$(MAKEDIR)\skylark_x86"
@if exist "$(MAKEDIR)\skylark_x86.7z" del /s/q "$(MAKEDIR)\skylark_x86.7z"
@if not exist "$(MAKEDIR)\skylark_x86" mkdir "$(MAKEDIR)\skylark_x86"
@if exist "$(MAKEDIR)\skylark_x86" xcopy /y /e /d "$(BIND)" "$(MAKEDIR)\skylark_x86"&del /s/q/a/f "$(MAKEDIR)\skylark_x86\*.pdb" 2>&1>NUL
-@del /s/q/a/f "$(MAKEDIR)\skylark_x86\*.exp" 2>nul 1>nul
-@del /s/q/a/f "$(MAKEDIR)\skylark_x86\*.lib" 2>nul 1>nul
-@del /s/q/a/f "$(MAKEDIR)\skylark_x86\conf\*.sqlite3" 2>nul 1>nul
@if exist "%WindowsSdkDir%Redist\%WindowsSDKVersion%ucrt\DLLs\x86" copy /y "%WindowsSdkDir%Redist\%WindowsSDKVersion%ucrt\DLLs\x86\*" "$(MAKEDIR)\skylark_x86" 2>&1>NUL
@if exist "%VCToolsRedistDir%x86\Microsoft.VC142.CRT\msvcp140.dll" copy /y "%VCToolsRedistDir%x86\Microsoft.VC142.CRT\msvcp140.dll" "$(MAKEDIR)\skylark_x86" 2>&1>NUL
@if exist "%VCToolsRedistDir%x86\Microsoft.VC142.CRT\vcruntime140.dll" copy /y "%VCToolsRedistDir%x86\Microsoft.VC142.CRT\vcruntime140*.dll" "$(MAKEDIR)\skylark_x86" 2>&1>NUL
@7z a -t7z "$(MAKEDIR)\skylark_x86$(RELEASE_VERSION).7z" "$(MAKEDIR)\skylark_x86" -mx9 -r -y
!ENDIF
clean:
@if exist "$(MAKEDIR)\src\3rdparty\sqlite3\Makefile" cd "$(MAKEDIR)\src\3rdparty\sqlite3" && $(MAKE) /NOLOGO /$(MAKEFLAGS) clean
@if exist "$(MAKEDIR)\src\3rdparty\pcre\Makefile" cd "$(MAKEDIR)\src\3rdparty\pcre" && $(MAKE) /NOLOGO /$(MAKEFLAGS) clean
@if exist "$(MAKEDIR)\src\3rdparty\libiconv\Makefile" cd "$(MAKEDIR)\src\3rdparty\libiconv" && $(MAKE) /NOLOGO /$(MAKEFLAGS) clean
@if exist "$(MAKEDIR)\src\3rdparty\luajit\Makefile" cd "$(MAKEDIR)\src\3rdparty\luajit" && $(MAKE) /NOLOGO /$(MAKEFLAGS) clean
@if exist "$(MAKEDIR)\src\3rdparty\chardet\Makefile" cd "$(MAKEDIR)\src\3rdparty\chardet" && $(MAKE) /NOLOGO /$(MAKEFLAGS) clean
@if exist "$(MAKEDIR)\src\3rdparty\qrencode\Makefile" cd "$(MAKEDIR)\src\3rdparty\qrencode" && $(MAKE) /NOLOGO /$(MAKEFLAGS) clean
@if exist "$(MAKEDIR)\src\3rdparty\tinyexpr\Makefile" cd "$(MAKEDIR)\src\3rdparty\tinyexpr" && $(MAKE) /NOLOGO /$(MAKEFLAGS) clean
@if exist "$(MAKEDIR)\src\3rdparty\expat\Makefile" cd "$(MAKEDIR)\src\3rdparty\expat" && $(MAKE) /NOLOGO /$(MAKEFLAGS) clean
@if exist "$(MAKEDIR)\src\3rdparty\scintilla\Makefile" cd "$(MAKEDIR)\src\3rdparty\scintilla" && $(MAKE) /NOLOGO /$(MAKEFLAGS) clean
@if exist "$(MAKEDIR)\plugins\pdfview\Makefile" cd "$(MAKEDIR)\plugins\pdfview" && $(MAKE) /NOLOGO /$(MAKEFLAGS) clean
cd "$(MAKEDIR)\src"
@$(MAKE) /NOLOGO /$(MAKEFLAGS) clean
cd "$(MAKEDIR)\locales"
@$(MAKE) /NOLOGO /$(MAKEFLAGS) clean
cd "$(MAKEDIR)"
-del /q /f /s *~ 2>nul
-rmdir /q /s Release .dep 2>nul
-rd /s/q skylark_x64 2>nul
-rd /s/q skylark_x86 2>nul