Skip to content

Commit 70371c4

Browse files
committed
Initial commit
0 parents  commit 70371c4

30 files changed

+2650
-0
lines changed

.gitignore

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
cmake-build-*/
2+
*build*/
3+
.idea/
4+
squashfs-root/
5+
*.AppImage

.gitmodules

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
[submodule "lib/googletest"]
2+
path = lib/googletest
3+
url = https://github.com/google/googletest.git

.travis.yml

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
language: cpp
2+
sudo: required
3+
4+
matrix:
5+
include:
6+
- env: ARCH=x86_64 BUILD_TYPE=coverage
7+
addons:
8+
apt:
9+
update: true
10+
packages:
11+
- libmagic-dev
12+
- libjpeg-dev
13+
- libpng-dev
14+
- cimg-dev
15+
before_script:
16+
- sudo pip install gcovr
17+
script: travis/test-coverage.sh
18+
after_success: true # also, we don't intend to upload release binaries
19+
- env: ARCH=i386 BUILD_TYPE=coverage
20+
addons:
21+
apt:
22+
update: true
23+
packages:
24+
- libmagic-dev:i386
25+
- libjpeg-dev:i386
26+
- libpng-dev:i386
27+
- gcc-multilib
28+
- g++-multilib
29+
- libfuse2:i386
30+
- libcairo2:i386
31+
before_script:
32+
- sudo pip install gcovr
33+
script: travis/test-coverage.sh
34+
after_success: true # also, we don't intend to upload release binaries
35+
36+
branches:
37+
except:
38+
- # Do not build tags that we create when we upload to GitHub Releases
39+
- /^(?i:continuous)$/

CMakeLists.txt

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
cmake_minimum_required(VERSION 3.2)
2+
3+
project(linuxdeploy-desktopfile CXX)
4+
5+
set(CMAKE_CXX_STANDARD 11)
6+
set(CMAKE_CXX_STANDARD_REQUIRED ON)
7+
8+
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${PROJECT_SOURCE_DIR}/cmake/Modules/")
9+
10+
# support for ccache
11+
# call CMake with -DUSE_CCACHE=ON to make use of it
12+
set(USE_CCACHE ON CACHE BOOL "")
13+
if(USE_CCACHE)
14+
find_program(CCACHE ccache)
15+
if(CCACHE)
16+
message(STATUS "Using ccache")
17+
set_property(GLOBAL PROPERTY RULE_LAUNCH_COMPILE ${CCACHE})
18+
set_property(GLOBAL PROPERTY RULE_LAUNCH_LINK ${CCACHE})
19+
else()
20+
message(WARNING "USE_CCACHE set, but could not find ccache")
21+
endif()
22+
endif()
23+
24+
set(ENABLE_COVERAGE OFF CACHE BOOL "Enable coverage measurements")
25+
if(ENABLE_COVERAGE)
26+
include(CodeCoverage)
27+
message(WARNING "Enabling code coverage measurements -> disables optimizations and embeds debug information!")
28+
29+
append_coverage_compiler_flags()
30+
31+
set(COVERAGE_GCOVR_EXCLUDES ${PROJECT_SOURCE_DIR}/lib ${PROJECT_BINARY_DIR})
32+
33+
include(ProcessorCount)
34+
ProcessorCount(processor_count)
35+
36+
set(command cmake --build . --target all -- -j ${processor_count} && ctest -V)
37+
38+
setup_target_for_coverage_gcovr_html(NAME coverage EXECUTABLE "${command}")
39+
setup_target_for_coverage_gcovr_xml(NAME coverage_xml EXECUTABLE "${command}")
40+
setup_target_for_coverage_gcovr_text(NAME coverage_text EXECUTABLE "${command}")
41+
endif()
42+
43+
add_subdirectory(lib)
44+
45+
add_subdirectory(src)
46+
47+
include(CTest)
48+
if(BUILD_TESTING)
49+
add_subdirectory(tests)
50+
endif()

LICENSE.txt

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
Copyright 2018 TheAssassin
2+
3+
Permission is hereby granted, free of charge, to any person obtaining a copy
4+
of this software and associated documentation files (the "Software"), to deal
5+
in the Software without restriction, including without limitation the rights
6+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7+
copies of the Software, and to permit persons to whom the Software is
8+
furnished to do so, subject to the following conditions:
9+
10+
The above copyright notice and this permission notice shall be included in all
11+
copies or substantial portions of the Software.
12+
13+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
19+
SOFTWARE.

0 commit comments

Comments
 (0)