Skip to content

Instantly share code, notes, and snippets.

@cristianadam
cristianadam / build_qmake.yml
Last active September 9, 2023 10:56
GitHub Actions Doxygen Qt Creator plugin QMake build matrix
name: QMake Build Matrix
on: [push]
env:
QT_VERSION: 5.14.0
QT_CREATOR_VERSION: 4.11.0
PLUGIN_PRO: doxygen.pro
PLUGIN_NAME: Doxygen
@cristianadam
cristianadam / bundle_static_library.cmake
Created January 17, 2020 00:30
CMake function which bundles multiple static libraries into one
# MIT License
#
# Copyright (c) 2019 Cristian Adam
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
@cristianadam
cristianadam / ccache-pch-mingw-gcc.log
Created February 12, 2020 17:14
ccache PCH MinGW GCC log file
[.226923 1212 ] === CCACHE 3.7.7 STARTED =========================================
[.226923 1212 ] can't rename file C:/Projects/github/ccache-test/.ccache/stats to C:/Projects/github/ccache-test/.ccache/stats.rm.unknown.1212.XXXXXX OS returned error: C:/Projects/github/ccache/repo/src/legacy_util.cpp failed with error 2: The system cannot find the file specified.
[.226923 1212 ] Unlink C:/Projects/github/ccache-test/.ccache/stats via C:/Projects/github/ccache-test/.ccache/stats.rm.unknown.1212.XXXXXX
[.226923 1212 ] x_unlink failed: Invalid argument
[.295924 3580 ] === CCACHE 3.7.7 STARTED =========================================
[.295924 3580 ] Config: (default) base_dir =
[.295924 3580 ] Config: (environment) cache_dir = C:/Projects/github/ccache-test/.ccache
[.295924 3580 ] Config: (default) cache_dir_levels = 2
@cristianadam
cristianadam / ccache-pch-mingw-clang.log
Created February 12, 2020 17:16
ccahe PCH LLVM-MinGW log file
[.273393 9428 ] === CCACHE 3.7.7 STARTED =========================================
[.273393 9428 ] can't rename file C:/Projects/github/ccache-test/.ccache/stats to C:/Projects/github/ccache-test/.ccache/stats.rm.unknown.9428.XXXXXX OS returned error: C:/Projects/github/ccache/repo/src/legacy_util.cpp failed with error 2: The system cannot find the file specified.
[.273393 9428 ] Unlink C:/Projects/github/ccache-test/.ccache/stats via C:/Projects/github/ccache-test/.ccache/stats.rm.unknown.9428.XXXXXX
[.273393 9428 ] x_unlink failed: Invalid argument
[.335912 5976 ] === CCACHE 3.7.7 STARTED =========================================
[.335912 5976 ] Config: (default) base_dir =
[.335912 5976 ] Config: (environment) cache_dir = C:/Projects/github/ccache-test/.ccache
[.335912 5976 ] Config: (default) cache_dir_levels = 2
@cristianadam
cristianadam / ccache-pch-mingw-clang-multiple-files.log
Created February 13, 2020 08:38
ccache PCH Clang Multiple input files
[.286665 9104 ] === CCACHE 3.7.7 STARTED =========================================
[.286665 9104 ] can't rename file C:/Projects/github/ccache-test/.ccache/stats to C:/Projects/github/ccache-test/.ccache/stats.rm.unknown.9104.XXXXXX OS returned error: C:/Projects/github/ccache/repo/src/legacy_util.cpp failed with error 2: The system cannot find the file specified.
[.286665 9104 ] Unlink C:/Projects/github/ccache-test/.ccache/stats via C:/Projects/github/ccache-test/.ccache/stats.rm.unknown.9104.XXXXXX
[.286665 9104 ] x_unlink failed: Invalid argument
[.349169 524 ] === CCACHE 3.7.7 STARTED =========================================
[.349169 524 ] Config: (default) base_dir =
[.349169 524 ] Config: (environment) cache_dir = C:/Projects/github/ccache-test/.ccache
[.349169 524 ] Config: (default) cache_dir_levels = 2
@cristianadam
cristianadam / ccache-mingw-gcc-include_file_mtime.log
Last active March 11, 2020 12:42
ccache log mingw gcc include_file_mtime
[.471848 9116 ] === CCACHE 3.7.7 STARTED =========================================
[.506132 2136 ] === CCACHE 3.7.7 STARTED =========================================
[.507112 2136 ] can't rename file C:/Projects/HelloWorld/.ccache/stats to C:/Projects/HelloWorld/.ccache/stats.rm.unknown.2136.XXXXXX OS returned error: ../src/util.c failed with error 2: The system cannot find the file specified.
[.507112 2136 ] Unlink C:/Projects/HelloWorld/.ccache/stats via C:/Projects/HelloWorld/.ccache/stats.rm.unknown.2136.XXXXXX
[.508099 2136 ] x_unlink failed: Invalid argument
[.568825 5248 ] === CCACHE 3.7.7 STARTED =========================================
[.568825 5248 ] Config: (default) base_dir =
[.568825 5248 ] Config: (environment) cache_dir = C:/Projects/HelloWorld/.ccache
@cristianadam
cristianadam / setup_android.cmake
Last active July 21, 2022 12:55
CMake script to download OpenJDK and Android Command Line Tools. Execute with: cmake -P setup_android.cmake
# CMake script to download OpenJDK and Android Command Line Tools.
# Execute with: cmake -P setup_android.cmake
# Tested with Qt 6.3.1 and Qt Creator 8.0
set(JDK_VERSION "11.0.9.1+1")
set(ANDROID_CMDTOOLS_VERSION "8092744")
set(ANDROID_PLATFORM "android-31")
set(BUILD_TOOLS "31.0.0")
@cristianadam
cristianadam / build-source-directory.cmake
Last active August 2, 2024 02:16
CMake Script which builds all source files into one executable. Directory name is set as the name of the project.
cmake_minimum_required(VERSION 3.15)
get_filename_component(name ${CMAKE_CURRENT_LIST_DIR} NAME)
project(${name})
set(CMAKE_INCLUDE_CURRENT_DIR ON)
# Get all source files, CONFIGURE_DEPENDS makes sure that if you add
# new files and build, they will be picked up. Tested with Ninja
@cristianadam
cristianadam / ccache-master-clang9.log
Created July 26, 2020 17:46
ccache master running with a CMake project having precompiled headers and Clang-Mingw 9
[.942520 16720] === CCACHE master.1cbaa89d STARTED =========================================
[.943504 16720] failed to rename C:/Projects/github/ccache-test/.ccache/stats to C:/Projects/github/ccache-test/.ccache/stats.ccache.rm.tmp: The system cannot find the file specified.
(2)
[.943504 16720] Unlink C:/Projects/github/ccache-test/.ccache/stats via C:/Projects/github/ccache-test/.ccache/stats.ccache.rm.tmp
[.943504 16720] Unlink failed: Invalid argument
[.011564 6596 ] === CCACHE master.1cbaa89d STARTED =========================================
[.011564 6596 ] Config: (environment) base_dir = C:/Projects/github/ccache-test
[.011564 6596 ] Config: (environment) cache_dir = C:/Projects/github/ccache-test/.ccache
[.011564 6596 ] Config: (default) cache_dir_levels = 2
@cristianadam
cristianadam / ccache-master-clang9-include_mtime.log
Created July 26, 2020 17:48
ccache master running with a CMake project having precompiled headers and Clang-Mingw 9 (include_mtime)
[.696641 8612 ] === CCACHE master.1cbaa89d STARTED =========================================
[.696641 8612 ] failed to rename C:/Projects/github/ccache-test/.ccache/stats to C:/Projects/github/ccache-test/.ccache/stats.ccache.rm.tmp: The system cannot find the file specified.
(2)
[.697640 8612 ] Unlink C:/Projects/github/ccache-test/.ccache/stats via C:/Projects/github/ccache-test/.ccache/stats.ccache.rm.tmp
[.697640 8612 ] Unlink failed: Invalid argument
[.765881 19292] === CCACHE master.1cbaa89d STARTED =========================================
[.765881 19292] Config: (environment) base_dir = C:/Projects/github/ccache-test
[.765881 19292] Config: (environment) cache_dir = C:/Projects/github/ccache-test/.ccache
[.765881 19292] Config: (default) cache_dir_levels = 2