Vasily
29d41b4ed0
Add -Wconversion to GCC and Clang
...
clang-msvc spams warnings from the moc .cpp files that include Qt
headers.
2019-02-21 18:48:53 +01:00
Vasily
cfefec59e3
Fix -Wsign-conversion warnings
2019-02-21 18:48:53 +01:00
Vasily
ec014a1e74
Add -Wdouble-promotion switch to clang/gcc compilers
...
It introduces a lot of ugly casts. Long term the floats should probably
be changed to doubles everywhere since we're only compiling for 64 bit
x86.
2019-02-21 18:48:53 +01:00
Vasily
fe3bbc2959
Remove -Weffc++ from GCC
...
The "should be initialized in the member initialization list" is
incorrectly implemented on GCC.
https://stackoverflow.com/questions/14002454/can-i-ignore-the-gcc-warning-foom-bar-should-be-initialized-in-the-member-i
2019-02-21 18:48:53 +01:00
Vasily
0caff37251
Add -Weffc++ switch to clang/gcc
2019-02-21 18:48:53 +01:00
Vasily
473e928106
Refactor common switches into file
2019-02-21 18:48:53 +01:00
Vasily
106727a5b9
Remove -Wmost from GCC
...
-Wmost is a clang only switch.
2019-02-21 18:48:53 +01:00
Vasily
fddae4278b
Add more recommended switches
...
Commented out switches still give errors.
2019-02-21 18:48:53 +01:00
Vasily
ac614c36e6
Replace -pedantic with -Wpedantic
2019-02-21 18:48:53 +01:00
Vasily
d87338d195
Add -pedantic to Linux compilers
...
clang-msvc does not support -pedantic.
2019-02-21 18:48:53 +01:00
Vasily
82ac83d649
Add -Wextra to supported compilers
2019-02-21 18:48:53 +01:00
Vasily
cc4f0d4bc8
Remove unneeded -Xclang
2019-02-21 18:48:53 +01:00
Vasily
34204d2441
Add -Wnon-virtual-dtor and resolve issues
...
The IPolicyConfig file is a third party file and since it describes a
third party API we can't make changes to it. Adding it via the system
includes disables warnings on most compilers.
2019-02-21 18:48:53 +01:00
Vasily
5c70aba098
Revert easylogging++ include and attempt changing easylogging++.cc
2019-02-21 18:48:53 +01:00
Vasily
940ad48923
Attempt -i switch in order to ignore warnings in file
2019-02-21 18:48:53 +01:00
Vasily
9019270df8
Refine compiler system includes for different platforms
...
MSVC seems to be the only platform that doesn't have a non-experimental
way to include files that don't give warnings.
2019-02-21 18:48:53 +01:00
Vasily
1b6cc47238
Add .. to linux include paths
2019-02-21 18:48:53 +01:00
Vasily
4ed6e80645
Include third party headers system headers for clang/g++
2019-02-21 18:48:53 +01:00
Vitaly
acb666a142
Remove old style casts and enable warnings for them
2019-02-21 18:48:53 +01:00
Vasily
81af2b9c72
Add -Wshadow and solve warnings
2019-02-21 18:48:53 +01:00
Vasily
fdc096bb61
Add recommended compiler switches
...
From
https://github.com/lefticus/cppbestpractices/blob/master/02-Use_the_Tools_Available.md#MSVC
The '/w14619' switch creates errors in qglobal.h and qvector.h.
2019-02-21 18:48:53 +01:00
Vasily
68a72ded1f
Add whole program optimization to MSVC
2019-02-21 18:48:53 +01:00
Vasily
ab25124d7b
Move source files and resources file into separate .pri files
2019-02-21 18:48:53 +01:00
Vitaly
4b48d051c8
Refactor Qt project file into compiler specific subfiles
...
Encapsulating compiler specific options in a separate file
makes it easier to reason about what is going to happen on
a specific qmake call.
clang-msvc and msvc are separate because they don't support
exactly the same compiler switches.
2019-02-21 18:48:53 +01:00
Vasily
2f07a987bf
Add .gitattributes file
...
.svg files were not treated as binary which means they were spamming up
the diff log.
Bash files were not being pulled with LF line endings, which means they
couldn't be run by Windows Subsystem for Linux.
Bash files were renamed .sh to easily allow them to be recognized by
both .gitattributes and humans.
Taken from https://github.com/alexkaratarakis/gitattributes .
2019-02-02 16:37:50 +01:00
Vasily
474b1a7587
Rename version strings to 2.8.0-dev
...
Since version strings are displayed in logs and on the main screen, this
will prevent situations where the master branch is confused with the
2.8.0-release branch.
The 2-8-0-release file was a one time thing because the version numbers
were already changed, it should not be created for future releases.
2019-01-16 16:30:38 +01:00
Vasily
3e05bb07f9
Change Win build script batch file from test.bat to current_build.bat
2019-01-05 20:43:41 +01:00
Vasily
4787933a52
Add exit condition checking to build, deploy, package cmd files
...
Without the line checking the exit code, the script will not fail on a
failure from a subsystem.
2019-01-05 20:31:34 +01:00
Vasily
1df8e88e3d
Change RM to DEL in build, package, deploy cmd files
...
RM is the Linux command, DEL is the Windows equivalent.
2019-01-05 19:53:34 +01:00
Vasily
b5eb548b40
Update python scripts with docs
2019-01-04 17:07:52 +01:00
Vasily
33dba6202b
Update PYTHON env var to PYTHON_LOC
2019-01-04 17:07:52 +01:00
Vasily
93bbcc618a
Correct 7zip directory, no python definition expansion
2019-01-04 17:07:52 +01:00
Vasily
d4b09c76ad
Update python scripts, build_windows.cmd
2019-01-04 17:07:52 +01:00
Vasily
bfb11a9dc8
Add package python script, replace .cmd with py variants from PS
2019-01-04 17:08:34 +01:00
Vasily
1f1d321398
Update deployment script
...
Still needs file copying and batch file output.
2019-01-04 17:07:52 +01:00
Vasily
979f542348
Rename build.py to win_build.py
...
It's also going to fit the deploy and package scripts.
2019-01-04 17:07:52 +01:00
Vasily
b806667717
Use python build script
2019-01-04 17:07:52 +01:00
Vasily
14ab02f155
Remove function calls to say all vars are found
2019-01-04 16:14:47 +01:00
Vasily
e7cb2d8c1a
Add python build.py script
...
Does not work as well as the PS script, because of having to create
subprocesses and routing stdout and stderr seems to be problematic.
2019-01-04 16:13:23 +01:00
Vasily
b0bce08c2d
Convert win formatting script to use LLVM_LOC instead of
...
CLANG_FORMAT_LOC
The path to the bin dir for LLVM can be used for both clang-cl.exe and
clang-format.exe. Changing this will reduce the amount of environment
variables in play, leading to better long term quality.
2018-12-29 01:17:51 +01:00
Robin Appelman
3f0fbeb1b0
mark linux formatting scripts as executable
2018-12-28 20:42:33 +01:00
Vasily
1e3d3b3aed
Add additional error handling to verification scripts
2018-12-28 15:53:41 +01:00
Vasily
86a0dae70b
Add verification scripts for clang-format
...
The scripts are very light on error handling and verification, mostly
intended just to debug if a CI server fails on formatting reasons.
2018-12-28 03:01:45 +01:00
Vasily
4446af2a06
Add linux script
...
Not a lot of output compared to windows. It is assumed that linux users
have clang-format in the path.
2018-12-28 00:24:40 +01:00
Vasily
c33e8f76e7
Add windows formatting script
...
Done in batch script because Powershell requires execution policy to be
changed to run scripts. Therefore batch files are considered to have a
lower barrier for entry.
2018-12-28 00:23:14 +01:00
Vasily
b338872af3
Add python clang-format wrapper
...
Original found here: https://github.com/Sarcasm/run-clang-format
Licensed under MIT.
2018-12-28 00:03:20 +01:00
Vasily
2aa32bafad
Change variable expansion in build scripts
...
Currently the variable expansion sometimes doesn't work when done over
two variables. Inlining the ~dp0 call along with \..\..\ seems to work.
Testing leads me to believe that the Windows command prompt caches
things in a weird way.
2018-12-26 21:58:03 +01:00
Vasily
de8dffe40f
Add extra checks for environment vars
2018-12-26 20:23:16 +01:00
Vasily
fc103633fe
Update package script to consider path vars
2018-12-26 20:04:55 +01:00
Vasily
eee7148c00
New build_windows.cmd
...
Change names of build scripts
2018-12-26 18:21:02 +01:00