| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
misc/format-files now executes misc/clang-format, which works like this:
1. If environment variable CLANG_FORMAT is set, execute $CLANG_FORMAT.
2. Otherwise, if <ccache-top-dir>/misc/.clang-format-exe exists, execute
that program.
3. Otherwise, download a statically linked clang-format executable,
verify its integrity, place it in
<ccache-top-dir>/misc/.clang-format-exe and execute it.
This makes it possible for us to lock Clang-Format to version 10 and
remove most “// clang-format off/on” comments.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
With these changes, the project builds with Visual Studio 2019, unit
tests pass and it works correctly with mingw gcc.
NOTE: The very latest version of Visual Studio 2019 is required, because
there was just a necessary fix for template arguments.
Tested building and running unit tests on Windows+MSVC, Windows+MinGW,
Linux and macOS.
- Enable `ZSTD_FROM_INTERNET` by default for MSVC when not using vcpkg
or conan.
- Add include tests for some standard UNIX headers not available on
MSVC.
- Add necessary MSVC compiler flags.
- In `Args::from_gcc_atfile()` iterate over the string via `c_str()`
instead of `cbegin()`, the MSVC string character iterator does not
include the ending null byte.
- Misc. minor cmake fix-ups.
- Add some headers that are not implicitly included from other headers
like `<algorithm>`, `<ios>`, `<cstdint>` and `<cstdarg>` in some
places, gcc does this but MSVC does not.
- Add `std::filesystem` version of `Util::traverse()` when dirent.h is
not available, which is preferred for performance reasons.
- Add implementations of the following functions that are not available
in MSVC in Win32Util.cpp: `gettimeofday()`, `localtime_r()`,
`asprintf()`.
- Add Windows implementation of `getopt_long()` from
https://www.codeproject.com/Articles/157001/Full-getopt-Port-for-Unicode-and-Multibyte-Microso
to third_party/win32.
- Add some compatibility typedefs, constants and macros to the `_WIN32`
section of system.hpp, as well as the prototypes for the functions
added to Win32Util.cpp.
- Fix up unit tests expecting '/' separated paths to expect paths
delimited by `DIR_DELIM_CH`.
- Invoke test/run with bash from cmake, necessary on msys2+mingw64, many
fail, there is more work to do here.
- Set the warning level to `/W4` and silence all the uninteresting
warning types. Compiles with no warnings now.
- Switch to using standard C++ attributes `[[nodiscard]]` and
`[[maybe_unused]]` and define macros for gcc for their equivalents.
- `#define DOCTEST_CONFIG_USE_STD_HEADERS` for MSVC only, because it
requires explicitly including `<ostream>`.
- Add vim files to .gitignore.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
|
| |
|
|
|
|
|
|
| |
The convention is to use capitalized filenames for source files that
implement classes and namespaces and lowercase filenames for source
files that do not.
|
| |
|
|
|
|
| |
Co-authored-by: Cristian Adam <cristian.adam@gmail.com>
Co-authored-by: Joel Rosdahl <joel@rosdahl.net>
|
|
|
|
|
|
|
|
|
|
|
| |
* Prepare gitignore for builds in subdirectory
* Ignore to be generated Version.cpp
* Move travis to buildenv as it's just another image
* Move install_cuda out of .travis as it's not travis specific
* Prepare docker images for C++ and CMake
* Update authors + add script to do so
* Fix required C compiler
* Fix some formatting issues with clang-format 10
|
| |
|
|
|
|
|
|
| |
As suggested in PR #469.
Co-authored-by: Enrico Sorichetti <enricosorichetti@mac.com>
|
| |
|
|
|
|
|
| |
These are not required to be tracked under VCS.
Signed-off-by: Harsh Shandilya <msfjarvis@gmail.com>
|
|
|
|
|
|
|
|
| |
- Instead of using code generated by gperf, use ordinary unordered maps
for the mapping from config keys (and environment variables) to config
items.
- Renamed “struct conf* conf” to “class Config g_config”.
- C++-ified conf.cpp and confitems.cpp into Config.cpp.
|
|
|
|
|
| |
The suites will slowly be converted to the Catch2 framework, so no need
to make it easy to add new legacy suites.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The ccache source code will be converted to C++, targeting C++11. This
commit only arranges the existing C-style code to be built as C++ code.
This makes it possible to call new C++ code from old C-style code.
Gradual conversion to C++ functionality and idioms will follow in a slow
and controlled fashion – no big bang rewrites.
The alternative would be to convert code in a top-down fashion, i.e.
only calling legacy C code from new C++ code, not the other way around.
That approach is however not a good idea since the code that will
benefit most from being written in proper C++ is code deep down in the
call chains.
Except for renaming source code files to .cpp and .hpp, this commit
makes minimal changes to make the code base buildable again, for
example:
- Instructs configure.ac to look for a mandatory C++11-compliant
compiler.
- Adds Makefile rules for building C++ code.
- Sets up Travis-CI to pass C++ compiler flags and similar to the build.
- Adds new casts where needed.
- Adds const keywords where needed.
- Renames variables to something else than C++ keywords (e.g.
“template”).
- Rearranges some code to avoid complaints about goto jumps that cross
variable lifetimes.
|
| |
|
|
|
|
|
|
| |
We have had a requirement on gperf for the build-from-repo case for a
while now, so there is no real point in keeping generated gperf lookup
table code in the repository.
|
| |
|
|
|
|
|
|
|
| |
* Use AsciiDoc’s a2x tool instead of running xsltproc explicitly.
* Stow away ccache.1 in doc.
* Make AsciiDoc literals stand out as bold in the man page. We can now
use properly literals instead of emphasis in the manual.
|
| |
|
|
|
|
| |
Closes #225.
|
|
|
|
|
|
|
| |
* The unit tests formerly located in the test directory have been moved
to the unittest directory.
* The integration test suite test.sh has been made a bash script and
renamed to test/run. Its test suites are located in test/suites.
|
| |
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* maint:
Prepare for v3.1.10
Update NEWS
ignore config.cache files
Conflicts:
NEWS.txt
|
| |
| |
| |
| | |
This is created when you run `./configure -C`.
|
|/ |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
The part of Makefile.in that requires GNU make has been split into dev.mk.in,
and the configure script has learned a new --enable-dev option that makes
Makefile include dev.mk. The configure script doesn't check for GNU make
anymore. There is also a new configure-dev convenience script that runs
configure with --enable-dev.
|
|
|