Add support for mov video dan always use faststart to video format

This commit is contained in:
2026-06-12 14:15:29 +07:00
parent bbb0fe0d34
commit 2e45dfafbb
424 changed files with 80949 additions and 3403 deletions
Binary file not shown.
+18 -18
View File
@@ -1,20 +1,20 @@
# ninja log v5
0 92 8029396993585839 build.ninja 2f5a2ae5718e4ec9
14 762 8029185021516776 CMakeFiles/kcompressor.dir/native_compressor.cpp.o f1cdbf4574e80c54
1140 1359 8029185026652331 D:/MyProject/kcompressor/app/build/intermediates/cxx/Debug/j1t3m4l4/obj/arm64-v8a/libkcompressor.so 2ed2a8e4fb32e2f1
4 812 8029480314360756 CMakeFiles/kcompressor.dir/native_compressor.cpp.o f1cdbf4574e80c54
0 97 8029506585127615 build.ninja 2f5a2ae5718e4ec9
1141 1378 8029480319061115 D:/MyProject/kcompressor/app/build/intermediates/cxx/Debug/j1t3m4l4/obj/arm64-v8a/libkcompressor.so 106ffbe4417f09dd
0 8 0 clean 267b28daf0e986
8 740 8029480313668964 CMakeFiles/kcompressor.dir/compressor_common.cpp.o 51cecdb4bb34bbf4
13 1140 8029480317633298 CMakeFiles/kcompressor.dir/image_compressor.cpp.o 9626d49d842157ab
11 1096 8029480317229392 CMakeFiles/kcompressor.dir/video_compressor.cpp.o a7433b92b28b1b44
8 920 8029506594888005 CMakeFiles/kcompressor.dir/compressor_common.cpp.o 51cecdb4bb34bbf4
4 981 8029506595545332 CMakeFiles/kcompressor.dir/native_compressor.cpp.o f1cdbf4574e80c54
10 1256 8029506598268452 CMakeFiles/kcompressor.dir/video_compressor.cpp.o a7433b92b28b1b44
13 1310 8029506598761157 CMakeFiles/kcompressor.dir/image_compressor.cpp.o 9626d49d842157ab
1310 1559 8029506600257667 D:/MyProject/kcompressor/app/build/intermediates/cxx/Debug/j1t3m4l4/obj/arm64-v8a/libkcompressor.so 106ffbe4417f09dd
0 10 0 clean 267b28daf0e986
9 824 8029513444895799 CMakeFiles/kcompressor.dir/compressor_common.cpp.o 51cecdb4bb34bbf4
6 898 8029513445625201 CMakeFiles/kcompressor.dir/native_compressor.cpp.o f1cdbf4574e80c54
17 1202 8029513448628426 CMakeFiles/kcompressor.dir/video_compressor.cpp.o a7433b92b28b1b44
13 1241 8029513448985205 CMakeFiles/kcompressor.dir/image_compressor.cpp.o 9626d49d842157ab
1241 1465 8029513450464697 D:/MyProject/kcompressor/app/build/intermediates/cxx/Debug/j1t3m4l4/obj/arm64-v8a/libkcompressor.so 106ffbe4417f09dd
0 11 0 clean 267b28daf0e986
5 739 8029185021291292 CMakeFiles/kcompressor.dir/compressor_common.cpp.o 51cecdb4bb34bbf4
8 1086 8029185024740912 CMakeFiles/kcompressor.dir/video_compressor.cpp.o a7433b92b28b1b44
11 1140 8029185025251562 CMakeFiles/kcompressor.dir/image_compressor.cpp.o 9626d49d842157ab
8 1153 8029397006271551 CMakeFiles/kcompressor.dir/compressor_common.cpp.o 51cecdb4bb34bbf4
5 1168 8029397006428182 CMakeFiles/kcompressor.dir/native_compressor.cpp.o f1cdbf4574e80c54
10 1483 8029397009545197 CMakeFiles/kcompressor.dir/video_compressor.cpp.o a7433b92b28b1b44
13 1543 8029397010132834 CMakeFiles/kcompressor.dir/image_compressor.cpp.o 9626d49d842157ab
1543 2447 8029397018248978 D:/MyProject/kcompressor/app/build/intermediates/cxx/Debug/j1t3m4l4/obj/arm64-v8a/libkcompressor.so 106ffbe4417f09dd
0 10 0 clean 267b28daf0e986
13 1134 8029402129560801 CMakeFiles/kcompressor.dir/compressor_common.cpp.o 51cecdb4bb34bbf4
8 1157 8029402129804881 CMakeFiles/kcompressor.dir/native_compressor.cpp.o f1cdbf4574e80c54
21 1514 8029402133356799 CMakeFiles/kcompressor.dir/video_compressor.cpp.o a7433b92b28b1b44
17 1561 8029402133742631 CMakeFiles/kcompressor.dir/image_compressor.cpp.o 9626d49d842157ab
1561 1792 8029402135289547 D:/MyProject/kcompressor/app/build/intermediates/cxx/Debug/j1t3m4l4/obj/arm64-v8a/libkcompressor.so 106ffbe4417f09dd
0 10 0 clean 267b28daf0e986
@@ -2,27 +2,27 @@ C/C++ Structured Log[
Y
WD:\MyProject\kcompressor\app\.cxx\Debug\j1t3m4l4\arm64-v8a\additional_project_files.txtC
A
?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  ÷‡àÏë3  Ú‡àÏë3X
?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  ýùüÔë3  ëùüÔë3X
V
TD:\MyProject\kcompressor\app\.cxx\Debug\j1t3m4l4\arm64-v8a\android_gradle_build.json  ÷‡àÏë3º ܇àÏë3]
TD:\MyProject\kcompressor\app\.cxx\Debug\j1t3m4l4\arm64-v8a\android_gradle_build.json  ýùüÔë3º ìùüÔë3]
[
YD:\MyProject\kcompressor\app\.cxx\Debug\j1t3m4l4\arm64-v8a\android_gradle_build_mini.json  ÷‡àÏë3¤ î‡àÏë3J
YD:\MyProject\kcompressor\app\.cxx\Debug\j1t3m4l4\arm64-v8a\android_gradle_build_mini.json  ýùüÔë3¤ úùüÔë3J
H
FD:\MyProject\kcompressor\app\.cxx\Debug\j1t3m4l4\arm64-v8a\build.ninja  ÷‡àÏë3«’ ž‡àÏë3N
FD:\MyProject\kcompressor\app\.cxx\Debug\j1t3m4l4\arm64-v8a\build.ninja  ýùüÔë3«’ ÐùüÔë3N
L
JD:\MyProject\kcompressor\app\.cxx\Debug\j1t3m4l4\arm64-v8a\build.ninja.txt  ÷‡àÏë3S
JD:\MyProject\kcompressor\app\.cxx\Debug\j1t3m4l4\arm64-v8a\build.ninja.txt  ýùüÔë3S
Q
OD:\MyProject\kcompressor\app\.cxx\Debug\j1t3m4l4\arm64-v8a\build_file_index.txt  ÷‡àÏë3
OD:\MyProject\kcompressor\app\.cxx\Debug\j1t3m4l4\arm64-v8a\build_file_index.txt  ýùüÔë3
8 ³Šµë3T
R
R
PD:\MyProject\kcompressor\app\.cxx\Debug\j1t3m4l4\arm64-v8a\compile_commands.json  ýùüÔë3é' ÏùüÔë3X
V
V
TD:\MyProject\kcompressor\app\.cxx\Debug\j1t3m4l4\arm64-v8a\compile_commands.json.bin  ýùüÔë3 ª ÏùüÔë3^
\
\
ZD:\MyProject\kcompressor\app\.cxx\Debug\j1t3m4l4\arm64-v8a\metadata_generation_command.txt  ýùüÔë3
Ô ²Šµë3Q
O
O
MD:\MyProject\kcompressor\app\.cxx\Debug\j1t3m4l4\arm64-v8a\prefab_config.json  ýùüÔë3
 ( ³Šµë3V
 ( ³Šµë3V
T
RD:\MyProject\kcompressor\app\.cxx\Debug\j1t3m4l4\arm64-v8a\symbol_folder_index.txt  ÷‡àÏë3
RD:\MyProject\kcompressor\app\.cxx\Debug\j1t3m4l4\arm64-v8a\symbol_folder_index.txt  ýùüÔë3
@@ -0,0 +1,188 @@
{
"inputs" :
[
{
"path" : "CMakeLists.txt"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/Debug/j1t3m4l4/x86/CMakeFiles/3.22.1-g37088a8-dirty/CMakeSystem.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/android.toolchain.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/android-legacy.toolchain.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/abis.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/platforms.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeSystemSpecificInitialize.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Initialize.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android-Initialize.cmake"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/Debug/j1t3m4l4/x86/CMakeFiles/3.22.1-g37088a8-dirty/CMakeCCompiler.cmake"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/Debug/j1t3m4l4/x86/CMakeFiles/3.22.1-g37088a8-dirty/CMakeCXXCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeSystemSpecificInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeGenericSystem.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeInitializeConfigs.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Linux.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/UnixPaths.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeLanguageInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-C.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/CMakeCommonCompilerMacros.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/GNU.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/CMakeCommonCompilerMacros.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang-C.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android-Clang.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/flags.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCommonLanguageInclude.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCXXInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeLanguageInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-CXX.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang-CXX.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCommonLanguageInclude.cmake"
}
],
"kind" : "cmakeFiles",
"paths" :
{
"build" : "D:/MyProject/kcompressor/app/.cxx/Debug/j1t3m4l4/x86",
"source" : "D:/MyProject/kcompressor/app/src/main/cpp"
},
"version" :
{
"major" : 1,
"minor" : 0
}
}
@@ -1,803 +0,0 @@
{
"inputs" :
[
{
"path" : "CMakeLists.txt"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineSystem.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/android.toolchain.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/android-legacy.toolchain.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/abis.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/platforms.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Determine.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android-Determine.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeSystem.cmake.in"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/Debug/j1t3m4l4/x86/CMakeFiles/3.22.1-g37088a8-dirty/CMakeSystem.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/android.toolchain.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeSystemSpecificInitialize.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Initialize.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android-Initialize.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Determine-C.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android/Determine-Compiler.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Determine-Compiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompilerId.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCompilerIdDetection.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/ADSP-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/ARMCC-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/ARMClang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/AppleClang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-DetermineCompilerInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Borland-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Bruce-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-DetermineCompilerInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Compaq-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Cray-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Embarcadero-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Fujitsu-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/FujitsuClang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/GHS-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/GNU-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/HP-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IAR-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Intel-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IntelLLVM-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/MSVC-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/NVHPC-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/NVIDIA-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/OpenWatcom-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/PGI-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/PathScale-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/SCO-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/SDCC-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/SunPro-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/TI-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/TinyCC-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/VisualAge-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IBMCPP-C-DetermineVersionInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Watcom-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/XL-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IBMCPP-C-DetermineVersionInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/XLClang-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/zOS-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IBMCPP-C-DetermineVersionInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeFindBinUtils.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-FindBinUtils.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCCompiler.cmake.in"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/Debug/j1t3m4l4/x86/CMakeFiles/3.22.1-g37088a8-dirty/CMakeCCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCXXCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Determine-CXX.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android/Determine-Compiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompilerId.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCompilerIdDetection.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/ADSP-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/ARMCC-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/ARMClang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/AppleClang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-DetermineCompilerInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Borland-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-DetermineCompilerInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Comeau-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Compaq-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Cray-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Embarcadero-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Fujitsu-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/FujitsuClang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/GHS-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/GNU-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/HP-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IAR-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Intel-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IntelLLVM-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/MSVC-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/NVHPC-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/NVIDIA-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/OpenWatcom-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/PGI-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/PathScale-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/SCO-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/SunPro-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/TI-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/VisualAge-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IBMCPP-CXX-DetermineVersionInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Watcom-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/XL-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IBMCPP-CXX-DetermineVersionInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/XLClang-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/zOS-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IBMCPP-CXX-DetermineVersionInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeFindBinUtils.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-FindBinUtils.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCXXCompiler.cmake.in"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/Debug/j1t3m4l4/x86/CMakeFiles/3.22.1-g37088a8-dirty/CMakeCXXCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeSystemSpecificInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeGenericSystem.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeInitializeConfigs.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Linux.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/UnixPaths.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeLanguageInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-C.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/CMakeCommonCompilerMacros.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/GNU.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/CMakeCommonCompilerMacros.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang-C.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android-Clang.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/flags.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCommonLanguageInclude.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeTestCCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeTestCompilerCommon.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompilerABI.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeParseImplicitIncludeInfo.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeParseImplicitLinkInfo.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeParseLibraryArchitecture.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeTestCompilerCommon.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCCompilerABI.c"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompileFeatures.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Internal/FeatureTesting.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCCompiler.cmake.in"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/Debug/j1t3m4l4/x86/CMakeFiles/3.22.1-g37088a8-dirty/CMakeCCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCXXInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeLanguageInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-CXX.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang-CXX.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCommonLanguageInclude.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeTestCXXCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeTestCompilerCommon.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompilerABI.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeParseImplicitIncludeInfo.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeParseImplicitLinkInfo.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeParseLibraryArchitecture.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeTestCompilerCommon.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCXXCompilerABI.cpp"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompileFeatures.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Internal/FeatureTesting.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCXXCompiler.cmake.in"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/Debug/j1t3m4l4/x86/CMakeFiles/3.22.1-g37088a8-dirty/CMakeCXXCompiler.cmake"
}
],
"kind" : "cmakeFiles",
"paths" :
{
"build" : "D:/MyProject/kcompressor/app/.cxx/Debug/j1t3m4l4/x86",
"source" : "D:/MyProject/kcompressor/app/src/main/cpp"
},
"version" :
{
"major" : 1,
"minor" : 0
}
}
@@ -39,7 +39,7 @@
{
"directoryIndex" : 0,
"id" : "kcompressor::@6890427a1f51a3e7e1df",
"jsonFile" : "target-kcompressor-Debug-ae80138bec7f082a7437.json",
"jsonFile" : "target-kcompressor-Debug-1aaac36e3445681fcf73.json",
"name" : "kcompressor",
"projectIndex" : 0
}
@@ -26,7 +26,7 @@
"objects" :
[
{
"jsonFile" : "codemodel-v2-1c2dfbc938f6e8d2bdc4.json",
"jsonFile" : "codemodel-v2-fec8e92bb9819ccfa7f0.json",
"kind" : "codemodel",
"version" :
{
@@ -44,7 +44,7 @@
}
},
{
"jsonFile" : "cmakeFiles-v1-816317ebe17bd015b004.json",
"jsonFile" : "cmakeFiles-v1-29f5731a000e123c37c8.json",
"kind" : "cmakeFiles",
"version" :
{
@@ -69,7 +69,7 @@
},
"cmakeFiles-v1" :
{
"jsonFile" : "cmakeFiles-v1-816317ebe17bd015b004.json",
"jsonFile" : "cmakeFiles-v1-29f5731a000e123c37c8.json",
"kind" : "cmakeFiles",
"version" :
{
@@ -79,7 +79,7 @@
},
"codemodel-v2" :
{
"jsonFile" : "codemodel-v2-1c2dfbc938f6e8d2bdc4.json",
"jsonFile" : "codemodel-v2-fec8e92bb9819ccfa7f0.json",
"kind" : "codemodel",
"version" :
{
@@ -227,6 +227,11 @@
"fragment" : "-Wl,--end-group",
"role" : "libraries"
},
{
"backtrace" : 2,
"fragment" : "-lmediandk",
"role" : "libraries"
},
{
"backtrace" : 2,
"fragment" : "-landroid",
Binary file not shown.
+4
View File
@@ -1,3 +1,7 @@
# ninja log v5
0 11 0 clean 267b28daf0e986
2 143 8029506551739850 build.ninja f83080019da48f8e
0 91 8029506551739850 build.ninja f83080019da48f8e
0 7 0 clean 267b28daf0e986
0 8 0 clean 267b28daf0e986
0 9 0 clean 267b28daf0e986
File diff suppressed because one or more lines are too long
@@ -0,0 +1,188 @@
{
"inputs" :
[
{
"path" : "CMakeLists.txt"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/arm64-v8a/CMakeFiles/3.22.1-g37088a8-dirty/CMakeSystem.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/android.toolchain.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/android-legacy.toolchain.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/abis.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/platforms.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeSystemSpecificInitialize.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Initialize.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android-Initialize.cmake"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/arm64-v8a/CMakeFiles/3.22.1-g37088a8-dirty/CMakeCCompiler.cmake"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/arm64-v8a/CMakeFiles/3.22.1-g37088a8-dirty/CMakeCXXCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeSystemSpecificInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeGenericSystem.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeInitializeConfigs.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Linux.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/UnixPaths.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeLanguageInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-C.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/CMakeCommonCompilerMacros.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/GNU.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/CMakeCommonCompilerMacros.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang-C.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android-Clang.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/flags.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCommonLanguageInclude.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCXXInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeLanguageInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-CXX.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang-CXX.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCommonLanguageInclude.cmake"
}
],
"kind" : "cmakeFiles",
"paths" :
{
"build" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/arm64-v8a",
"source" : "D:/MyProject/kcompressor/app/src/main/cpp"
},
"version" :
{
"major" : 1,
"minor" : 0
}
}
@@ -1,803 +0,0 @@
{
"inputs" :
[
{
"path" : "CMakeLists.txt"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineSystem.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/android.toolchain.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/android-legacy.toolchain.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/abis.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/platforms.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Determine.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android-Determine.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeSystem.cmake.in"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/arm64-v8a/CMakeFiles/3.22.1-g37088a8-dirty/CMakeSystem.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/android.toolchain.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeSystemSpecificInitialize.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Initialize.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android-Initialize.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Determine-C.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android/Determine-Compiler.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Determine-Compiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompilerId.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCompilerIdDetection.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/ADSP-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/ARMCC-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/ARMClang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/AppleClang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-DetermineCompilerInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Borland-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Bruce-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-DetermineCompilerInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Compaq-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Cray-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Embarcadero-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Fujitsu-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/FujitsuClang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/GHS-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/GNU-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/HP-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IAR-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Intel-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IntelLLVM-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/MSVC-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/NVHPC-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/NVIDIA-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/OpenWatcom-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/PGI-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/PathScale-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/SCO-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/SDCC-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/SunPro-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/TI-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/TinyCC-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/VisualAge-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IBMCPP-C-DetermineVersionInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Watcom-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/XL-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IBMCPP-C-DetermineVersionInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/XLClang-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/zOS-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IBMCPP-C-DetermineVersionInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeFindBinUtils.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-FindBinUtils.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCCompiler.cmake.in"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/arm64-v8a/CMakeFiles/3.22.1-g37088a8-dirty/CMakeCCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCXXCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Determine-CXX.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android/Determine-Compiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompilerId.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCompilerIdDetection.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/ADSP-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/ARMCC-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/ARMClang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/AppleClang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-DetermineCompilerInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Borland-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-DetermineCompilerInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Comeau-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Compaq-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Cray-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Embarcadero-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Fujitsu-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/FujitsuClang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/GHS-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/GNU-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/HP-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IAR-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Intel-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IntelLLVM-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/MSVC-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/NVHPC-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/NVIDIA-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/OpenWatcom-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/PGI-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/PathScale-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/SCO-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/SunPro-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/TI-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/VisualAge-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IBMCPP-CXX-DetermineVersionInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Watcom-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/XL-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IBMCPP-CXX-DetermineVersionInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/XLClang-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/zOS-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IBMCPP-CXX-DetermineVersionInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeFindBinUtils.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-FindBinUtils.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCXXCompiler.cmake.in"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/arm64-v8a/CMakeFiles/3.22.1-g37088a8-dirty/CMakeCXXCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeSystemSpecificInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeGenericSystem.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeInitializeConfigs.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Linux.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/UnixPaths.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeLanguageInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-C.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/CMakeCommonCompilerMacros.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/GNU.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/CMakeCommonCompilerMacros.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang-C.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android-Clang.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/flags.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCommonLanguageInclude.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeTestCCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeTestCompilerCommon.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompilerABI.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeParseImplicitIncludeInfo.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeParseImplicitLinkInfo.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeParseLibraryArchitecture.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeTestCompilerCommon.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCCompilerABI.c"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompileFeatures.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Internal/FeatureTesting.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCCompiler.cmake.in"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/arm64-v8a/CMakeFiles/3.22.1-g37088a8-dirty/CMakeCCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCXXInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeLanguageInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-CXX.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang-CXX.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCommonLanguageInclude.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeTestCXXCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeTestCompilerCommon.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompilerABI.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeParseImplicitIncludeInfo.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeParseImplicitLinkInfo.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeParseLibraryArchitecture.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeTestCompilerCommon.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCXXCompilerABI.cpp"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompileFeatures.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Internal/FeatureTesting.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCXXCompiler.cmake.in"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/arm64-v8a/CMakeFiles/3.22.1-g37088a8-dirty/CMakeCXXCompiler.cmake"
}
],
"kind" : "cmakeFiles",
"paths" :
{
"build" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/arm64-v8a",
"source" : "D:/MyProject/kcompressor/app/src/main/cpp"
},
"version" :
{
"major" : 1,
"minor" : 0
}
}
@@ -39,7 +39,7 @@
{
"directoryIndex" : 0,
"id" : "kcompressor::@6890427a1f51a3e7e1df",
"jsonFile" : "target-kcompressor-RelWithDebInfo-745c599d677a0a62bc26.json",
"jsonFile" : "target-kcompressor-RelWithDebInfo-629175f078d00ae34e12.json",
"name" : "kcompressor",
"projectIndex" : 0
}
@@ -26,7 +26,7 @@
"objects" :
[
{
"jsonFile" : "codemodel-v2-ca44f5329f21eeb68a38.json",
"jsonFile" : "codemodel-v2-a509508c860c257628de.json",
"kind" : "codemodel",
"version" :
{
@@ -44,7 +44,7 @@
}
},
{
"jsonFile" : "cmakeFiles-v1-ff60db6e57d229ebd4fb.json",
"jsonFile" : "cmakeFiles-v1-3abc5f63397bb35955a6.json",
"kind" : "cmakeFiles",
"version" :
{
@@ -69,7 +69,7 @@
},
"cmakeFiles-v1" :
{
"jsonFile" : "cmakeFiles-v1-ff60db6e57d229ebd4fb.json",
"jsonFile" : "cmakeFiles-v1-3abc5f63397bb35955a6.json",
"kind" : "cmakeFiles",
"version" :
{
@@ -79,7 +79,7 @@
},
"codemodel-v2" :
{
"jsonFile" : "codemodel-v2-ca44f5329f21eeb68a38.json",
"jsonFile" : "codemodel-v2-a509508c860c257628de.json",
"kind" : "codemodel",
"version" :
{
@@ -227,6 +227,11 @@
"fragment" : "-Wl,--end-group",
"role" : "libraries"
},
{
"backtrace" : 2,
"fragment" : "-lmediandk",
"role" : "libraries"
},
{
"backtrace" : 2,
"fragment" : "-landroid",
@@ -1,8 +1,12 @@
# ninja log v5
0 794 8029187898973068 CMakeFiles/kcompressor.dir/compressor_common.cpp.o adb2af10dbb0ffbb
0 95 8029506554287663 build.ninja 4ea1f7cd834922f1
3 814 8029187899145234 CMakeFiles/kcompressor.dir/native_compressor.cpp.o fe03857812d5987e
5 1362 8029187904608351 CMakeFiles/kcompressor.dir/image_compressor.cpp.o 966f53d8dadbca3b
8 1427 8029187905203701 CMakeFiles/kcompressor.dir/video_compressor.cpp.o d7b1b2f4d613b4df
1428 1667 8029187906763470 D:/MyProject/kcompressor/app/build/intermediates/cxx/RelWithDebInfo/1j3m5w6j/obj/arm64-v8a/libkcompressor.so a8059da3bd0eeb96
0 9 0 clean 267b28daf0e986
0 9 0 clean 267b28daf0e986
0 8 0 clean 267b28daf0e986
1 92 8029506554287663 build.ninja 4ea1f7cd834922f1
0 7 0 clean 267b28daf0e986
0 12 0 clean 267b28daf0e986
0 8 0 clean 267b28daf0e986
File diff suppressed because one or more lines are too long
@@ -0,0 +1,188 @@
{
"inputs" :
[
{
"path" : "CMakeLists.txt"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/armeabi-v7a/CMakeFiles/3.22.1-g37088a8-dirty/CMakeSystem.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/android.toolchain.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/android-legacy.toolchain.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/abis.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/platforms.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeSystemSpecificInitialize.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Initialize.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android-Initialize.cmake"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/armeabi-v7a/CMakeFiles/3.22.1-g37088a8-dirty/CMakeCCompiler.cmake"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/armeabi-v7a/CMakeFiles/3.22.1-g37088a8-dirty/CMakeCXXCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeSystemSpecificInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeGenericSystem.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeInitializeConfigs.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Linux.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/UnixPaths.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeLanguageInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-C.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/CMakeCommonCompilerMacros.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/GNU.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/CMakeCommonCompilerMacros.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang-C.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android-Clang.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/flags.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCommonLanguageInclude.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCXXInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeLanguageInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-CXX.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang-CXX.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCommonLanguageInclude.cmake"
}
],
"kind" : "cmakeFiles",
"paths" :
{
"build" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/armeabi-v7a",
"source" : "D:/MyProject/kcompressor/app/src/main/cpp"
},
"version" :
{
"major" : 1,
"minor" : 0
}
}
@@ -1,803 +0,0 @@
{
"inputs" :
[
{
"path" : "CMakeLists.txt"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineSystem.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/android.toolchain.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/android-legacy.toolchain.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/abis.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/platforms.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Determine.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android-Determine.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeSystem.cmake.in"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/armeabi-v7a/CMakeFiles/3.22.1-g37088a8-dirty/CMakeSystem.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/android.toolchain.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeSystemSpecificInitialize.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Initialize.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android-Initialize.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Determine-C.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android/Determine-Compiler.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Determine-Compiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompilerId.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCompilerIdDetection.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/ADSP-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/ARMCC-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/ARMClang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/AppleClang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-DetermineCompilerInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Borland-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Bruce-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-DetermineCompilerInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Compaq-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Cray-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Embarcadero-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Fujitsu-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/FujitsuClang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/GHS-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/GNU-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/HP-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IAR-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Intel-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IntelLLVM-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/MSVC-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/NVHPC-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/NVIDIA-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/OpenWatcom-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/PGI-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/PathScale-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/SCO-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/SDCC-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/SunPro-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/TI-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/TinyCC-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/VisualAge-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IBMCPP-C-DetermineVersionInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Watcom-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/XL-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IBMCPP-C-DetermineVersionInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/XLClang-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/zOS-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IBMCPP-C-DetermineVersionInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeFindBinUtils.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-FindBinUtils.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCCompiler.cmake.in"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/armeabi-v7a/CMakeFiles/3.22.1-g37088a8-dirty/CMakeCCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCXXCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Determine-CXX.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android/Determine-Compiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompilerId.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCompilerIdDetection.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/ADSP-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/ARMCC-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/ARMClang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/AppleClang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-DetermineCompilerInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Borland-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-DetermineCompilerInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Comeau-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Compaq-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Cray-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Embarcadero-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Fujitsu-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/FujitsuClang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/GHS-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/GNU-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/HP-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IAR-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Intel-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IntelLLVM-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/MSVC-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/NVHPC-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/NVIDIA-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/OpenWatcom-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/PGI-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/PathScale-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/SCO-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/SunPro-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/TI-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/VisualAge-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IBMCPP-CXX-DetermineVersionInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Watcom-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/XL-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IBMCPP-CXX-DetermineVersionInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/XLClang-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/zOS-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IBMCPP-CXX-DetermineVersionInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeFindBinUtils.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-FindBinUtils.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCXXCompiler.cmake.in"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/armeabi-v7a/CMakeFiles/3.22.1-g37088a8-dirty/CMakeCXXCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeSystemSpecificInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeGenericSystem.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeInitializeConfigs.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Linux.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/UnixPaths.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeLanguageInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-C.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/CMakeCommonCompilerMacros.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/GNU.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/CMakeCommonCompilerMacros.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang-C.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android-Clang.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/flags.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCommonLanguageInclude.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeTestCCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeTestCompilerCommon.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompilerABI.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeParseImplicitIncludeInfo.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeParseImplicitLinkInfo.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeParseLibraryArchitecture.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeTestCompilerCommon.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCCompilerABI.c"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompileFeatures.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Internal/FeatureTesting.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCCompiler.cmake.in"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/armeabi-v7a/CMakeFiles/3.22.1-g37088a8-dirty/CMakeCCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCXXInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeLanguageInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-CXX.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang-CXX.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCommonLanguageInclude.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeTestCXXCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeTestCompilerCommon.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompilerABI.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeParseImplicitIncludeInfo.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeParseImplicitLinkInfo.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeParseLibraryArchitecture.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeTestCompilerCommon.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCXXCompilerABI.cpp"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompileFeatures.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Internal/FeatureTesting.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCXXCompiler.cmake.in"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/armeabi-v7a/CMakeFiles/3.22.1-g37088a8-dirty/CMakeCXXCompiler.cmake"
}
],
"kind" : "cmakeFiles",
"paths" :
{
"build" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/armeabi-v7a",
"source" : "D:/MyProject/kcompressor/app/src/main/cpp"
},
"version" :
{
"major" : 1,
"minor" : 0
}
}
@@ -39,7 +39,7 @@
{
"directoryIndex" : 0,
"id" : "kcompressor::@6890427a1f51a3e7e1df",
"jsonFile" : "target-kcompressor-RelWithDebInfo-4dc1e40339f74e2db246.json",
"jsonFile" : "target-kcompressor-RelWithDebInfo-25940feaa70a370999db.json",
"name" : "kcompressor",
"projectIndex" : 0
}
@@ -26,7 +26,7 @@
"objects" :
[
{
"jsonFile" : "codemodel-v2-5e9f9d1615c87e7f8cde.json",
"jsonFile" : "codemodel-v2-dcc619b9c8e7323ecd00.json",
"kind" : "codemodel",
"version" :
{
@@ -44,7 +44,7 @@
}
},
{
"jsonFile" : "cmakeFiles-v1-864ecaeb9d56f94c7529.json",
"jsonFile" : "cmakeFiles-v1-1e77ed3892865ae67a2a.json",
"kind" : "cmakeFiles",
"version" :
{
@@ -69,7 +69,7 @@
},
"cmakeFiles-v1" :
{
"jsonFile" : "cmakeFiles-v1-864ecaeb9d56f94c7529.json",
"jsonFile" : "cmakeFiles-v1-1e77ed3892865ae67a2a.json",
"kind" : "cmakeFiles",
"version" :
{
@@ -79,7 +79,7 @@
},
"codemodel-v2" :
{
"jsonFile" : "codemodel-v2-5e9f9d1615c87e7f8cde.json",
"jsonFile" : "codemodel-v2-dcc619b9c8e7323ecd00.json",
"kind" : "codemodel",
"version" :
{
@@ -227,6 +227,11 @@
"fragment" : "-Wl,--end-group",
"role" : "libraries"
},
{
"backtrace" : 2,
"fragment" : "-lmediandk",
"role" : "libraries"
},
{
"backtrace" : 2,
"fragment" : "-landroid",
@@ -1,8 +1,12 @@
# ninja log v5
0 787 8029187927760538 CMakeFiles/kcompressor.dir/compressor_common.cpp.o 6a18ebe4bf23ff4c
1451 1700 8029187936161958 D:/MyProject/kcompressor/app/build/intermediates/cxx/RelWithDebInfo/1j3m5w6j/obj/armeabi-v7a/libkcompressor.so d83368780ff05daf
1 92 8029506553058322 build.ninja de0149c609cfe238
4 830 8029187928180710 CMakeFiles/kcompressor.dir/native_compressor.cpp.o 2561d13e2ec28901
6 1371 8029187933562682 CMakeFiles/kcompressor.dir/image_compressor.cpp.o c99d1a9dc80d375b
9 1450 8029187934303847 CMakeFiles/kcompressor.dir/video_compressor.cpp.o 32681f6efee839b1
1451 1700 8029187936161958 D:/MyProject/kcompressor/app/build/intermediates/cxx/RelWithDebInfo/1j3m5w6j/obj/armeabi-v7a/libkcompressor.so d83368780ff05daf
0 9 0 clean 267b28daf0e986
0 11 0 clean 267b28daf0e986
1 93 8029506553058322 build.ninja de0149c609cfe238
0 7 0 clean 267b28daf0e986
0 10 0 clean 267b28daf0e986
0 9 0 clean 267b28daf0e986
File diff suppressed because one or more lines are too long
@@ -39,7 +39,7 @@
{
"directoryIndex" : 0,
"id" : "kcompressor::@6890427a1f51a3e7e1df",
"jsonFile" : "target-kcompressor-RelWithDebInfo-fb91a9f13fd2d7dbcec7.json",
"jsonFile" : "target-kcompressor-RelWithDebInfo-1b896933e8907deccf69.json",
"name" : "kcompressor",
"projectIndex" : 0
}
@@ -26,7 +26,7 @@
"objects" :
[
{
"jsonFile" : "codemodel-v2-cc2b53ce3a30785fbd5e.json",
"jsonFile" : "codemodel-v2-0d230ca2ec7fffcc65d0.json",
"kind" : "codemodel",
"version" :
{
@@ -79,7 +79,7 @@
},
"codemodel-v2" :
{
"jsonFile" : "codemodel-v2-cc2b53ce3a30785fbd5e.json",
"jsonFile" : "codemodel-v2-0d230ca2ec7fffcc65d0.json",
"kind" : "codemodel",
"version" :
{
@@ -227,6 +227,11 @@
"fragment" : "-Wl,--end-group",
"role" : "libraries"
},
{
"backtrace" : 2,
"fragment" : "-lmediandk",
"role" : "libraries"
},
{
"backtrace" : 2,
"fragment" : "-landroid",
@@ -1,10 +1,12 @@
# ninja log v5
0 9 0 clean 267b28daf0e986
1 100 8029187940586389 build.ninja af12574c3879f389
3 776 8029187948911413 CMakeFiles/kcompressor.dir/compressor_common.cpp.o 39bdd443ba7e458d
0 8 0 clean 267b28daf0e986
0 100 8029506555540742 build.ninja af12574c3879f389
0 824 8029187949395675 CMakeFiles/kcompressor.dir/native_compressor.cpp.o c4401d2af9681fa8
3 776 8029187948911413 CMakeFiles/kcompressor.dir/compressor_common.cpp.o 39bdd443ba7e458d
6 1412 8029187955245026 CMakeFiles/kcompressor.dir/image_compressor.cpp.o 70fefa06449145a1
8 1523 8029187956312024 CMakeFiles/kcompressor.dir/video_compressor.cpp.o 627e3e3b8c70a589
1523 1718 8029187957662419 D:/MyProject/kcompressor/app/build/intermediates/cxx/RelWithDebInfo/1j3m5w6j/obj/x86/libkcompressor.so 8a9e3764c4fde8af
0 92 8029506555540742 build.ninja af12574c3879f389
0 8 0 clean 267b28daf0e986
0 9 0 clean 267b28daf0e986
0 9 0 clean 267b28daf0e986
0 7 0 clean 267b28daf0e986
@@ -92,7 +92,7 @@ build CMakeFiles/kcompressor.dir/image_compressor.cpp.o: CXX_COMPILER__kcompress
build D$:/MyProject/kcompressor/app/build/intermediates/cxx/RelWithDebInfo/1j3m5w6j/obj/x86/libkcompressor.so: CXX_SHARED_LIBRARY_LINKER__kcompressor_RelWithDebInfo CMakeFiles/kcompressor.dir/native_compressor.cpp.o CMakeFiles/kcompressor.dir/compressor_common.cpp.o CMakeFiles/kcompressor.dir/video_compressor.cpp.o CMakeFiles/kcompressor.dir/image_compressor.cpp.o | D$:/MyProject/kcompressor/app/src/main/cpp/third_party/ffmpeg-android/x86/lib/libavfilter.a D$:/MyProject/kcompressor/app/src/main/cpp/third_party/ffmpeg-android/x86/lib/libavformat.a D$:/MyProject/kcompressor/app/src/main/cpp/third_party/ffmpeg-android/x86/lib/libavcodec.a D$:/MyProject/kcompressor/app/src/main/cpp/third_party/ffmpeg-android/x86/lib/libswscale.a D$:/MyProject/kcompressor/app/src/main/cpp/third_party/ffmpeg-android/x86/lib/libswresample.a D$:/MyProject/kcompressor/app/src/main/cpp/third_party/ffmpeg-android/x86/lib/libavutil.a D$:/MyProject/kcompressor/app/src/main/cpp/third_party/ffmpeg-android/x86/lib/libx264.a D$:/MyProject/kcompressor/app/src/main/cpp/third_party/ffmpeg-android/x86/lib/libx265.a D$:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libturbojpeg.a D$:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libjpeg.a D$:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libwebp.a D$:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libsharpyuv.a D$:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libavif.a D$:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libaom.a D$:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libyuv.a D$:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libimagequant.a D$:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/liboxipng_ffi.a D$:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libkimage_png.a
LANGUAGE_COMPILE_FLAGS = -g -DANDROID -fdata-sections -ffunction-sections -funwind-tables -fstack-protector-strong -no-canonical-prefixes -mstackrealign -D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -std=c++17 -fexceptions -frtti -O2 -g -DNDEBUG
LINK_FLAGS = -static-libstdc++ -Wl,--build-id=sha1 -Wl,--no-rosegment -Wl,--no-undefined-version -Wl,--fatal-warnings -Wl,--no-undefined -Qunused-arguments -Wl,--gc-sections
LINK_LIBRARIES = -Wl,--start-group D:/MyProject/kcompressor/app/src/main/cpp/third_party/ffmpeg-android/x86/lib/libavfilter.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/ffmpeg-android/x86/lib/libavformat.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/ffmpeg-android/x86/lib/libavcodec.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/ffmpeg-android/x86/lib/libswscale.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/ffmpeg-android/x86/lib/libswresample.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/ffmpeg-android/x86/lib/libavutil.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/ffmpeg-android/x86/lib/libx264.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/ffmpeg-android/x86/lib/libx265.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libturbojpeg.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libjpeg.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libwebp.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libsharpyuv.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libavif.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libaom.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libyuv.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libimagequant.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/liboxipng_ffi.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libkimage_png.a -Wl,--end-group -landroid -llog -lz -lm -ldl -latomic -lc++_static -latomic -lm
LINK_LIBRARIES = -Wl,--start-group D:/MyProject/kcompressor/app/src/main/cpp/third_party/ffmpeg-android/x86/lib/libavfilter.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/ffmpeg-android/x86/lib/libavformat.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/ffmpeg-android/x86/lib/libavcodec.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/ffmpeg-android/x86/lib/libswscale.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/ffmpeg-android/x86/lib/libswresample.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/ffmpeg-android/x86/lib/libavutil.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/ffmpeg-android/x86/lib/libx264.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/ffmpeg-android/x86/lib/libx265.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libturbojpeg.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libjpeg.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libwebp.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libsharpyuv.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libavif.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libaom.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libyuv.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libimagequant.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/liboxipng_ffi.a D:/MyProject/kcompressor/app/src/main/cpp/third_party/android-image-compres/x86/lib/libkimage_png.a -Wl,--end-group -lmediandk -landroid -llog -lz -lm -ldl -latomic -lc++_static -latomic -lm
OBJECT_DIR = CMakeFiles\kcompressor.dir
POST_BUILD = cd .
PRE_LINK = cd .
@@ -1,803 +0,0 @@
{
"inputs" :
[
{
"path" : "CMakeLists.txt"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineSystem.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/android.toolchain.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/android-legacy.toolchain.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/abis.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/platforms.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Determine.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android-Determine.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeSystem.cmake.in"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/x86_64/CMakeFiles/3.22.1-g37088a8-dirty/CMakeSystem.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/android.toolchain.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeSystemSpecificInitialize.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Initialize.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android-Initialize.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Determine-C.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android/Determine-Compiler.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Determine-Compiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompilerId.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCompilerIdDetection.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/ADSP-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/ARMCC-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/ARMClang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/AppleClang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-DetermineCompilerInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Borland-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Bruce-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-DetermineCompilerInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Compaq-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Cray-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Embarcadero-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Fujitsu-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/FujitsuClang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/GHS-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/GNU-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/HP-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IAR-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Intel-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IntelLLVM-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/MSVC-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/NVHPC-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/NVIDIA-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/OpenWatcom-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/PGI-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/PathScale-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/SCO-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/SDCC-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/SunPro-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/TI-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/TinyCC-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/VisualAge-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IBMCPP-C-DetermineVersionInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Watcom-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/XL-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IBMCPP-C-DetermineVersionInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/XLClang-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/zOS-C-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IBMCPP-C-DetermineVersionInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeFindBinUtils.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-FindBinUtils.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCCompiler.cmake.in"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/x86_64/CMakeFiles/3.22.1-g37088a8-dirty/CMakeCCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCXXCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Determine-CXX.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android/Determine-Compiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompilerId.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCompilerIdDetection.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/ADSP-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/ARMCC-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/ARMClang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/AppleClang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-DetermineCompilerInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Borland-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-DetermineCompilerInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Comeau-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Compaq-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Cray-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Embarcadero-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Fujitsu-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/FujitsuClang-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/GHS-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/GNU-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/HP-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IAR-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Intel-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IntelLLVM-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/MSVC-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/NVHPC-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/NVIDIA-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/OpenWatcom-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/PGI-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/PathScale-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/SCO-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/SunPro-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/TI-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/VisualAge-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IBMCPP-CXX-DetermineVersionInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Watcom-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/XL-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IBMCPP-CXX-DetermineVersionInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/XLClang-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/zOS-CXX-DetermineCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/IBMCPP-CXX-DetermineVersionInternal.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeFindBinUtils.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-FindBinUtils.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCXXCompiler.cmake.in"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/x86_64/CMakeFiles/3.22.1-g37088a8-dirty/CMakeCXXCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeSystemSpecificInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeGenericSystem.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeInitializeConfigs.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Linux.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/UnixPaths.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeLanguageInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-C.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/CMakeCommonCompilerMacros.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/GNU.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/CMakeCommonCompilerMacros.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang-C.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android-Clang.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/flags.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCommonLanguageInclude.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeTestCCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeTestCompilerCommon.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompilerABI.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeParseImplicitIncludeInfo.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeParseImplicitLinkInfo.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeParseLibraryArchitecture.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeTestCompilerCommon.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCCompilerABI.c"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompileFeatures.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Internal/FeatureTesting.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCCompiler.cmake.in"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/x86_64/CMakeFiles/3.22.1-g37088a8-dirty/CMakeCCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCXXInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeLanguageInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-CXX.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang-CXX.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCommonLanguageInclude.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeTestCXXCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeTestCompilerCommon.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompilerABI.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeParseImplicitIncludeInfo.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeParseImplicitLinkInfo.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeParseLibraryArchitecture.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeTestCompilerCommon.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCXXCompilerABI.cpp"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeDetermineCompileFeatures.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Internal/FeatureTesting.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCXXCompiler.cmake.in"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/x86_64/CMakeFiles/3.22.1-g37088a8-dirty/CMakeCXXCompiler.cmake"
}
],
"kind" : "cmakeFiles",
"paths" :
{
"build" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/x86_64",
"source" : "D:/MyProject/kcompressor/app/src/main/cpp"
},
"version" :
{
"major" : 1,
"minor" : 0
}
}
@@ -0,0 +1,188 @@
{
"inputs" :
[
{
"path" : "CMakeLists.txt"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/x86_64/CMakeFiles/3.22.1-g37088a8-dirty/CMakeSystem.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/android.toolchain.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/android-legacy.toolchain.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/abis.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/platforms.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeSystemSpecificInitialize.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Initialize.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android-Initialize.cmake"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/x86_64/CMakeFiles/3.22.1-g37088a8-dirty/CMakeCCompiler.cmake"
},
{
"isGenerated" : true,
"path" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/x86_64/CMakeFiles/3.22.1-g37088a8-dirty/CMakeCXXCompiler.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeSystemSpecificInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeGenericSystem.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeInitializeConfigs.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Linux.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/UnixPaths.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeLanguageInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-C.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/CMakeCommonCompilerMacros.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/GNU.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/CMakeCommonCompilerMacros.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang-C.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/hooks/pre/Android-Clang.cmake"
},
{
"isExternal" : true,
"path" : "D:/Android/sdk/ndk/28.2.13676358/build/cmake/flags.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCommonLanguageInclude.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCXXInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeLanguageInformation.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang-CXX.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Compiler/Clang.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang-CXX.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/Platform/Android-Clang.cmake"
},
{
"isCMake" : true,
"isExternal" : true,
"path" : "D:/Android/sdk/cmake/3.22.1/share/cmake-3.22/Modules/CMakeCommonLanguageInclude.cmake"
}
],
"kind" : "cmakeFiles",
"paths" :
{
"build" : "D:/MyProject/kcompressor/app/.cxx/RelWithDebInfo/1j3m5w6j/x86_64",
"source" : "D:/MyProject/kcompressor/app/src/main/cpp"
},
"version" :
{
"major" : 1,
"minor" : 0
}
}
@@ -39,7 +39,7 @@
{
"directoryIndex" : 0,
"id" : "kcompressor::@6890427a1f51a3e7e1df",
"jsonFile" : "target-kcompressor-RelWithDebInfo-f612c8e8deb350eb4aaa.json",
"jsonFile" : "target-kcompressor-RelWithDebInfo-755384221a37a352fad1.json",
"name" : "kcompressor",
"projectIndex" : 0
}
@@ -26,7 +26,7 @@
"objects" :
[
{
"jsonFile" : "codemodel-v2-2aa65859c809d225bace.json",
"jsonFile" : "codemodel-v2-7d8f93174a7b687bb5f3.json",
"kind" : "codemodel",
"version" :
{
@@ -44,7 +44,7 @@
}
},
{
"jsonFile" : "cmakeFiles-v1-2473dbf68cffdc6fc751.json",
"jsonFile" : "cmakeFiles-v1-b45bcbff36384d7096d0.json",
"kind" : "cmakeFiles",
"version" :
{
@@ -69,7 +69,7 @@
},
"cmakeFiles-v1" :
{
"jsonFile" : "cmakeFiles-v1-2473dbf68cffdc6fc751.json",
"jsonFile" : "cmakeFiles-v1-b45bcbff36384d7096d0.json",
"kind" : "cmakeFiles",
"version" :
{
@@ -79,7 +79,7 @@
},
"codemodel-v2" :
{
"jsonFile" : "codemodel-v2-2aa65859c809d225bace.json",
"jsonFile" : "codemodel-v2-7d8f93174a7b687bb5f3.json",
"kind" : "codemodel",
"version" :
{
@@ -227,6 +227,11 @@
"fragment" : "-Wl,--end-group",
"role" : "libraries"
},
{
"backtrace" : 2,
"fragment" : "-lmediandk",
"role" : "libraries"
},
{
"backtrace" : 2,
"fragment" : "-landroid",
@@ -1,8 +1,12 @@
# ninja log v5
3 750 8029187976745550 CMakeFiles/kcompressor.dir/compressor_common.cpp.o e948351abac712f4
1 90 8029506556797001 build.ninja a6235447c6f6ba26
0 798 8029187977212028 CMakeFiles/kcompressor.dir/native_compressor.cpp.o 11a9e5946f3f9e42
8 1358 8029187982797733 CMakeFiles/kcompressor.dir/image_compressor.cpp.o d8e972cfc758d537
6 1494 8029187984087538 CMakeFiles/kcompressor.dir/video_compressor.cpp.o 6f7ed18233f2755
1494 1770 8029187985812012 D:/MyProject/kcompressor/app/build/intermediates/cxx/RelWithDebInfo/1j3m5w6j/obj/x86_64/libkcompressor.so c324cc0b7c1e37af
0 9 0 clean 267b28daf0e986
0 7 0 clean 267b28daf0e986
0 92 8029506556797001 build.ninja a6235447c6f6ba26
0 7 0 clean 267b28daf0e986
0 9 0 clean 267b28daf0e986
0 8 0 clean 267b28daf0e986
File diff suppressed because one or more lines are too long
+222 -1
View File
@@ -1,5 +1,6 @@
#include <jni.h>
#include <string>
#include <cerrno>
#include "compressor_common.h"
#include "video_compressor.h"
@@ -7,6 +8,8 @@
extern "C" {
#include <libavcodec/avcodec.h>
#include <libavcodec/bsf.h>
#include <libavutil/error.h>
}
static std::string jstring_to_string(JNIEnv *env, jstring value, const char *fallback) {
@@ -24,6 +27,42 @@ static std::string jstring_to_string(JNIEnv *env, jstring value, const char *fal
return result;
}
static bool is_mediacodec_encoder_name(const std::string &encoder) {
return encoder == "h264_mediacodec" ||
encoder == "hevc_mediacodec";
}
static const char *required_mediacodec_bsf_name(const std::string &encoder) {
if (encoder == "h264_mediacodec") {
return "h264_mp4toannexb";
}
if (encoder == "hevc_mediacodec") {
return "hevc_mp4toannexb";
}
return nullptr;
}
static bool required_mediacodec_bsf_available(const std::string &encoder) {
const char *bsf_name = required_mediacodec_bsf_name(encoder);
if (!bsf_name) {
return true;
}
return av_bsf_get_by_name(bsf_name) != nullptr;
}
static std::string fallback_cpu_encoder_for(const std::string &encoder) {
if (encoder == "hevc_mediacodec" && avcodec_find_encoder_by_name("libx265")) {
return "libx265";
}
return "libx264";
}
extern "C"
JNIEXPORT jboolean JNICALL
Java_com_kikyps_kcompressor_NativeCompressor_isVideoEncoderAvailable(JNIEnv *env,
@@ -36,7 +75,19 @@ Java_com_kikyps_kcompressor_NativeCompressor_isVideoEncoderAvailable(JNIEnv *env
}
const AVCodec *codec = avcodec_find_encoder_by_name(encoder.c_str());
return codec ? JNI_TRUE : JNI_FALSE;
if (!codec) {
return JNI_FALSE;
}
// MediaCodec encoder di FFmpeg membutuhkan bitstream filter tertentu.
// Jika FFmpeg static build dibuat dengan --disable-bsfs atau BSF terkait tidak di-enable,
// avcodec_open2() dapat gagal dengan: "Bitstream filter not found".
if (is_mediacodec_encoder_name(encoder) &&
!required_mediacodec_bsf_available(encoder)) {
return JNI_FALSE;
}
return JNI_TRUE;
}
extern "C"
@@ -71,6 +122,21 @@ Java_com_kikyps_kcompressor_NativeCompressor_compressFd(JNIEnv *env,
encoder = "libx264";
}
if (is_mediacodec_encoder_name(encoder) &&
!required_mediacodec_bsf_available(encoder)) {
std::string old_encoder = encoder;
encoder = fallback_cpu_encoder_for(old_encoder);
callback_progress(
env,
callback,
0,
std::string("Hardware GPU tidak aktif: FFmpeg build belum menyertakan bitstream filter ") +
required_mediacodec_bsf_name(old_encoder) +
". Fallback ke CPU."
);
}
if (targetShortSide < 0) targetShortSide = 0;
if (crf < 0) crf = 26;
@@ -88,6 +154,9 @@ Java_com_kikyps_kcompressor_NativeCompressor_compressFd(JNIEnv *env,
audioBitrate = 128000;
}
const std::string requested_encoder = encoder;
const bool requested_hardware_encoder = is_mediacodec_encoder_name(requested_encoder);
reset_cancel_requested();
int ret = compress_video_fd_impl(
@@ -105,6 +174,158 @@ Java_com_kikyps_kcompressor_NativeCompressor_compressFd(JNIEnv *env,
callback
);
// Runtime fallback:
// Beberapa device/FFmpeg build terlihat punya encoder MediaCodec,
// tetapi avcodec_open2() tetap gagal, misalnya:
// "Bitstream filter not found" atau error vendor MediaCodec.
// Dalam kondisi ini, ulangi otomatis memakai CPU agar compress tidak gagal total.
if (ret < 0 && requested_hardware_encoder && !is_cancel_requested()) {
std::string cpu_encoder = fallback_cpu_encoder_for(requested_encoder);
callback_progress(
env,
callback,
0,
std::string("Hardware GPU gagal. Fallback otomatis ke ") +
cpu_encoder +
"."
);
reset_cancel_requested();
ret = compress_video_fd_impl(
env,
static_cast<int>(inputFd),
static_cast<int>(outputFd),
static_cast<int>(targetShortSide),
static_cast<int>(inputRotationDegrees),
static_cast<int>(crf),
0,
cpu_encoder,
preset_str,
audio_mode,
static_cast<int>(audioBitrate),
callback
);
}
return static_cast<jint>(ret);
}
extern "C"
JNIEXPORT jint JNICALL
Java_com_kikyps_kcompressor_NativeCompressor_compressFdToPath(JNIEnv *env,
jclass,
jint inputFd,
jstring outputPath,
jint targetShortSide,
jint inputRotationDegrees,
jint crf,
jint videoBitrate,
jstring encoderName,
jstring preset,
jstring audioMode,
jint audioBitrate,
jobject callback) {
std::string output_path = jstring_to_string(env, outputPath, "");
std::string encoder = jstring_to_string(env, encoderName, "libx264");
std::string preset_str = jstring_to_string(env, preset, "medium");
std::string audio_mode = jstring_to_string(env, audioMode, "copy");
if (output_path.empty()) {
callback_progress(env, callback, 0, "Output temp path kosong");
return static_cast<jint>(AVERROR(EINVAL));
}
if (encoder != "libx264" &&
encoder != "libx265" &&
encoder != "h264_mediacodec" &&
encoder != "hevc_mediacodec") {
encoder = "libx264";
}
if (is_mediacodec_encoder_name(encoder) &&
!required_mediacodec_bsf_available(encoder)) {
std::string old_encoder = encoder;
encoder = fallback_cpu_encoder_for(old_encoder);
callback_progress(
env,
callback,
0,
std::string("Hardware GPU tidak lengkap di build FFmpeg. Fallback ke ") +
encoder +
"."
);
}
if (targetShortSide < 0) targetShortSide = 0;
if (crf < 0) crf = 26;
if (crf > 51) crf = 51;
if (videoBitrate < 0) {
videoBitrate = 0;
}
if (audio_mode != "copy" && audio_mode != "aac" && audio_mode != "mute") {
audio_mode = "copy";
}
if (audioBitrate <= 0) {
audioBitrate = 128000;
}
const std::string requested_encoder = encoder;
const bool requested_hardware_encoder = is_mediacodec_encoder_name(requested_encoder);
reset_cancel_requested();
int ret = compress_video_fd_to_path_impl(
env,
static_cast<int>(inputFd),
output_path,
static_cast<int>(targetShortSide),
static_cast<int>(inputRotationDegrees),
static_cast<int>(crf),
static_cast<int>(videoBitrate),
encoder,
preset_str,
audio_mode,
static_cast<int>(audioBitrate),
callback
);
if (ret < 0 && requested_hardware_encoder && !is_cancel_requested()) {
std::string cpu_encoder = fallback_cpu_encoder_for(requested_encoder);
callback_progress(
env,
callback,
0,
std::string("Hardware GPU gagal. Fallback otomatis ke ") +
cpu_encoder +
"."
);
reset_cancel_requested();
ret = compress_video_fd_to_path_impl(
env,
static_cast<int>(inputFd),
output_path,
static_cast<int>(targetShortSide),
static_cast<int>(inputRotationDegrees),
static_cast<int>(crf),
0,
cpu_encoder,
preset_str,
audio_mode,
static_cast<int>(audioBitrate),
callback
);
}
return static_cast<jint>(ret);
}
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,60 @@
/* Version ID for the JPEG library.
* Might be useful for tests like "#if JPEG_LIB_VERSION >= 60".
*/
#define JPEG_LIB_VERSION 80
/* libjpeg-turbo version */
#define LIBJPEG_TURBO_VERSION 3.1.90
/* libjpeg-turbo version in integer form */
#define LIBJPEG_TURBO_VERSION_NUMBER 3001090
/* Support arithmetic encoding when using 8-bit samples */
#define C_ARITH_CODING_SUPPORTED 1
/* Support arithmetic decoding when using 8-bit samples */
#define D_ARITH_CODING_SUPPORTED 1
/* Support in-memory source/destination managers */
#define MEM_SRCDST_SUPPORTED 1
/* Use accelerated SIMD routines when using 8-bit samples */
/* #undef WITH_SIMD */
/* This version of libjpeg-turbo supports run-time selection of data precision,
* so BITS_IN_JSAMPLE is no longer used to specify the data precision at build
* time. However, some downstream software expects the macro to be defined.
* Since 12-bit data precision is an opt-in feature that requires explicitly
* calling 12-bit-specific libjpeg API functions and using 12-bit-specific data
* types, the unmodified portion of the libjpeg API still behaves as if it were
* built for 8-bit precision, and JSAMPLE is still literally an 8-bit data
* type. Thus, it is correct to define BITS_IN_JSAMPLE to 8 here.
*/
#ifndef BITS_IN_JSAMPLE
#define BITS_IN_JSAMPLE 8
#endif
#ifdef _WIN32
#undef RIGHT_SHIFT_IS_UNSIGNED
/* Define "boolean" as unsigned char, not int, per Windows custom */
#ifndef __RPCNDR_H__ /* don't conflict if rpcndr.h already read */
typedef unsigned char boolean;
#endif
#define HAVE_BOOLEAN /* prevent jmorecfg.h from redefining it */
/* Define "INT32" as int, not long, per Windows custom */
#if !(defined(_BASETSD_H_) || defined(_BASETSD_H)) /* don't conflict if basetsd.h already read */
typedef short INT16;
typedef signed int INT32;
#endif
#define XMD_H /* prevent jmorecfg.h from redefining it */
#else
/* Define if your (broken) compiler shifts signed values as if they were
unsigned. */
/* #undef RIGHT_SHIFT_IS_UNSIGNED */
#endif
@@ -0,0 +1,336 @@
/*
* jerror.h
*
* This file was part of the Independent JPEG Group's software:
* Copyright (C) 1994-1997, Thomas G. Lane.
* Modified 1997-2009 by Guido Vollbeding.
* Lossless JPEG Modifications:
* Copyright (C) 1999, Ken Murchison.
* libjpeg-turbo Modifications:
* Copyright (C) 2014, 2017, 2021-2023, 2026, D. R. Commander.
* For conditions of distribution and use, see the accompanying README.ijg
* file.
*
* This file defines the error and message codes for the JPEG library.
* Edit this file to add new codes, or to translate the message strings to
* some other language.
* A set of error-reporting macros are defined too. Some applications using
* the JPEG library may wish to include this file to get the error codes
* and/or the macros.
*/
/*
* To define the enum list of message codes, include this file without
* defining macro JMESSAGE. To create a message string table, include it
* again with a suitable JMESSAGE definition (see jerror.c for an example).
*/
#ifndef JMESSAGE
#ifndef JERROR_H
/* First time through, define the enum list */
#define JMAKE_ENUM_LIST
#else
/* Repeated inclusions of this file are no-ops unless JMESSAGE is defined */
#define JMESSAGE(code, string)
#endif /* JERROR_H */
#endif /* JMESSAGE */
#ifdef JMAKE_ENUM_LIST
typedef enum {
#define JMESSAGE(code, string) code,
#endif /* JMAKE_ENUM_LIST */
JMESSAGE(JMSG_NOMESSAGE, "Bogus message code %d") /* Must be first entry! */
/* For maintenance convenience, list is alphabetical by message code name */
#if JPEG_LIB_VERSION < 70
JMESSAGE(JERR_ARITH_NOTIMPL, "Sorry, arithmetic coding is not implemented")
#endif
JMESSAGE(JERR_BAD_ALIGN_TYPE, "ALIGN_TYPE is wrong, please fix")
JMESSAGE(JERR_BAD_ALLOC_CHUNK, "MAX_ALLOC_CHUNK is wrong, please fix")
JMESSAGE(JERR_BAD_BUFFER_MODE, "Bogus buffer control mode")
JMESSAGE(JERR_BAD_COMPONENT_ID, "Invalid component ID %d in SOS")
#if JPEG_LIB_VERSION >= 70
JMESSAGE(JERR_BAD_CROP_SPEC, "Invalid crop request")
#endif
JMESSAGE(JERR_BAD_DCT_COEF,
"DCT coefficient (lossy) or spatial difference (lossless) out of range")
JMESSAGE(JERR_BAD_DCTSIZE, "IDCT output block size %d not supported")
#if JPEG_LIB_VERSION >= 70
JMESSAGE(JERR_BAD_DROP_SAMPLING,
"Component index %d: mismatching sampling ratio %d:%d, %d:%d, %c")
#endif
JMESSAGE(JERR_BAD_HUFF_TABLE, "Bogus Huffman table definition")
JMESSAGE(JERR_BAD_IN_COLORSPACE, "Bogus input colorspace")
JMESSAGE(JERR_BAD_J_COLORSPACE, "Bogus JPEG colorspace")
JMESSAGE(JERR_BAD_LENGTH, "Bogus marker length")
JMESSAGE(JERR_BAD_LIB_VERSION,
"Wrong JPEG library version: library is %d, caller expects %d")
JMESSAGE(JERR_BAD_MCU_SIZE, "Sampling factors too large for interleaved scan")
JMESSAGE(JERR_BAD_POOL_ID, "Invalid memory pool code %d")
JMESSAGE(JERR_BAD_PRECISION, "Unsupported JPEG data precision %d")
JMESSAGE(JERR_BAD_PROGRESSION,
"Invalid progressive/lossless parameters Ss=%d Se=%d Ah=%d Al=%d")
JMESSAGE(JERR_BAD_PROG_SCRIPT,
"Invalid progressive/lossless parameters at scan script entry %d")
JMESSAGE(JERR_BAD_SAMPLING, "Bogus sampling factors")
JMESSAGE(JERR_BAD_SCAN_SCRIPT, "Invalid scan script at entry %d")
JMESSAGE(JERR_BAD_STATE, "Improper call to JPEG library in state %d")
JMESSAGE(JERR_BAD_STRUCT_SIZE,
"JPEG parameter struct mismatch: library thinks size is %u, caller expects %u")
JMESSAGE(JERR_BAD_VIRTUAL_ACCESS, "Bogus virtual array access")
JMESSAGE(JERR_BUFFER_SIZE, "Buffer passed to JPEG library is too small")
JMESSAGE(JERR_CANT_SUSPEND, "Suspension not allowed here")
JMESSAGE(JERR_CCIR601_NOTIMPL, "CCIR601 sampling not implemented yet")
JMESSAGE(JERR_COMPONENT_COUNT, "Too many color components: %d, max %d")
JMESSAGE(JERR_CONVERSION_NOTIMPL, "Unsupported color conversion request")
JMESSAGE(JERR_DAC_INDEX, "Bogus DAC index %d")
JMESSAGE(JERR_DAC_VALUE, "Bogus DAC value 0x%x")
JMESSAGE(JERR_DHT_INDEX, "Bogus DHT index %d")
JMESSAGE(JERR_DQT_INDEX, "Bogus DQT index %d")
JMESSAGE(JERR_EMPTY_IMAGE, "Empty JPEG image (DNL not supported)")
JMESSAGE(JERR_EMS_READ, "Read from EMS failed")
JMESSAGE(JERR_EMS_WRITE, "Write to EMS failed")
JMESSAGE(JERR_EOI_EXPECTED, "Didn't expect more than one scan")
JMESSAGE(JERR_FILE_READ, "Input file read error")
JMESSAGE(JERR_FILE_WRITE, "Output file write error --- out of disk space?")
JMESSAGE(JERR_FRACT_SAMPLE_NOTIMPL, "Fractional sampling not implemented yet")
JMESSAGE(JERR_HUFF_CLEN_OVERFLOW, "Huffman code size table overflow")
JMESSAGE(JERR_HUFF_MISSING_CODE, "Missing Huffman code table entry")
JMESSAGE(JERR_IMAGE_TOO_BIG, "Maximum supported image dimension is %u pixels")
JMESSAGE(JERR_INPUT_EMPTY, "Empty input file")
JMESSAGE(JERR_INPUT_EOF, "Premature end of input file")
JMESSAGE(JERR_MISMATCHED_QUANT_TABLE,
"Cannot transcode due to multiple use of quantization table %d")
JMESSAGE(JERR_MISSING_DATA, "Scan script does not transmit all data")
JMESSAGE(JERR_MODE_CHANGE, "Invalid color quantization mode change")
JMESSAGE(JERR_NOTIMPL, "Requested features are incompatible")
JMESSAGE(JERR_NOT_COMPILED, "Requested feature was omitted at compile time")
#if JPEG_LIB_VERSION >= 70
JMESSAGE(JERR_NO_ARITH_TABLE, "Arithmetic table 0x%02x was not defined")
#endif
JMESSAGE(JERR_NO_BACKING_STORE, "Memory limit exceeded")
JMESSAGE(JERR_NO_HUFF_TABLE, "Huffman table 0x%02x was not defined")
JMESSAGE(JERR_NO_IMAGE, "JPEG datastream contains no image")
JMESSAGE(JERR_NO_QUANT_TABLE, "Quantization table 0x%02x was not defined")
JMESSAGE(JERR_NO_SOI, "Not a JPEG file: starts with 0x%02x 0x%02x")
JMESSAGE(JERR_OUT_OF_MEMORY, "Insufficient memory (case %d)")
JMESSAGE(JERR_QUANT_COMPONENTS,
"Cannot quantize more than %d color components")
JMESSAGE(JERR_QUANT_FEW_COLORS, "Cannot quantize to fewer than %d colors")
JMESSAGE(JERR_QUANT_MANY_COLORS, "Cannot quantize to more than %d colors")
JMESSAGE(JERR_SOF_DUPLICATE, "Invalid JPEG file structure: two SOF markers")
JMESSAGE(JERR_SOF_NO_SOS, "Invalid JPEG file structure: missing SOS marker")
JMESSAGE(JERR_SOF_UNSUPPORTED, "Unsupported JPEG process: SOF type 0x%02x")
JMESSAGE(JERR_SOI_DUPLICATE, "Invalid JPEG file structure: two SOI markers")
JMESSAGE(JERR_SOS_NO_SOF, "Invalid JPEG file structure: SOS before SOF")
JMESSAGE(JERR_TFILE_CREATE, "Failed to create temporary file %s")
JMESSAGE(JERR_TFILE_READ, "Read failed on temporary file")
JMESSAGE(JERR_TFILE_SEEK, "Seek failed on temporary file")
JMESSAGE(JERR_TFILE_WRITE,
"Write failed on temporary file --- out of disk space?")
JMESSAGE(JERR_TOO_LITTLE_DATA, "Application transferred too few scanlines")
JMESSAGE(JERR_UNKNOWN_MARKER, "Unsupported marker type 0x%02x")
JMESSAGE(JERR_VIRTUAL_BUG, "Virtual array controller messed up")
JMESSAGE(JERR_WIDTH_OVERFLOW, "Image too wide for this implementation")
JMESSAGE(JERR_XMS_READ, "Read from XMS failed")
JMESSAGE(JERR_XMS_WRITE, "Write to XMS failed")
JMESSAGE(JMSG_COPYRIGHT, JCOPYRIGHT)
JMESSAGE(JMSG_VERSION, JVERSION)
JMESSAGE(JTRC_16BIT_TABLES,
"Caution: quantization tables are too coarse for baseline JPEG")
JMESSAGE(JTRC_ADOBE,
"Adobe APP14 marker: version %d, flags 0x%04x 0x%04x, transform %d")
JMESSAGE(JTRC_APP0, "Unknown APP0 marker (not JFIF), length %u")
JMESSAGE(JTRC_APP14, "Unknown APP14 marker (not Adobe), length %u")
JMESSAGE(JTRC_DAC, "Define Arithmetic Table 0x%02x: 0x%02x")
JMESSAGE(JTRC_DHT, "Define Huffman Table 0x%02x")
JMESSAGE(JTRC_DQT, "Define Quantization Table %d precision %d")
JMESSAGE(JTRC_DRI, "Define Restart Interval %u")
JMESSAGE(JTRC_EMS_CLOSE, "Freed EMS handle %u")
JMESSAGE(JTRC_EMS_OPEN, "Obtained EMS handle %u")
JMESSAGE(JTRC_EOI, "End Of Image")
JMESSAGE(JTRC_HUFFBITS, " %3d %3d %3d %3d %3d %3d %3d %3d")
JMESSAGE(JTRC_JFIF, "JFIF APP0 marker: version %d.%02d, density %dx%d %d")
JMESSAGE(JTRC_JFIF_BADTHUMBNAILSIZE,
"Warning: thumbnail image size does not match data length %u")
JMESSAGE(JTRC_JFIF_EXTENSION, "JFIF extension marker: type 0x%02x, length %u")
JMESSAGE(JTRC_JFIF_THUMBNAIL, " with %d x %d thumbnail image")
JMESSAGE(JTRC_MISC_MARKER, "Miscellaneous marker 0x%02x, length %u")
JMESSAGE(JTRC_PARMLESS_MARKER, "Unexpected marker 0x%02x")
JMESSAGE(JTRC_QUANTVALS, " %4u %4u %4u %4u %4u %4u %4u %4u")
JMESSAGE(JTRC_QUANT_3_NCOLORS, "Quantizing to %d = %d*%d*%d colors")
JMESSAGE(JTRC_QUANT_NCOLORS, "Quantizing to %d colors")
JMESSAGE(JTRC_QUANT_SELECTED, "Selected %d colors for quantization")
JMESSAGE(JTRC_RECOVERY_ACTION, "At marker 0x%02x, recovery action %d")
JMESSAGE(JTRC_RST, "RST%d")
JMESSAGE(JTRC_SMOOTH_NOTIMPL,
"Smoothing not supported with nonstandard sampling ratios")
JMESSAGE(JTRC_SOF, "Start Of Frame 0x%02x: width=%u, height=%u, components=%d")
JMESSAGE(JTRC_SOF_COMPONENT, " Component %d: %dhx%dv q=%d")
JMESSAGE(JTRC_SOI, "Start of Image")
JMESSAGE(JTRC_SOS, "Start Of Scan: %d components")
JMESSAGE(JTRC_SOS_COMPONENT, " Component %d: dc=%d ac=%d")
JMESSAGE(JTRC_SOS_PARAMS, " Ss=%d, Se=%d, Ah=%d, Al=%d")
JMESSAGE(JTRC_TFILE_CLOSE, "Closed temporary file %s")
JMESSAGE(JTRC_TFILE_OPEN, "Opened temporary file %s")
JMESSAGE(JTRC_THUMB_JPEG,
"JFIF extension marker: JPEG-compressed thumbnail image, length %u")
JMESSAGE(JTRC_THUMB_PALETTE,
"JFIF extension marker: palette thumbnail image, length %u")
JMESSAGE(JTRC_THUMB_RGB,
"JFIF extension marker: RGB thumbnail image, length %u")
JMESSAGE(JTRC_UNKNOWN_IDS,
"Unrecognized component IDs %d %d %d, assuming YCbCr (lossy) or RGB (lossless)")
JMESSAGE(JTRC_XMS_CLOSE, "Freed XMS handle %u")
JMESSAGE(JTRC_XMS_OPEN, "Obtained XMS handle %u")
JMESSAGE(JWRN_ADOBE_XFORM, "Unknown Adobe color transform code %d")
#if JPEG_LIB_VERSION >= 70
JMESSAGE(JWRN_ARITH_BAD_CODE, "Corrupt JPEG data: bad arithmetic code")
#endif
JMESSAGE(JWRN_BOGUS_PROGRESSION,
"Inconsistent progression sequence for component %d coefficient %d")
JMESSAGE(JWRN_EXTRANEOUS_DATA,
"Corrupt JPEG data: %u extraneous bytes before marker 0x%02x")
JMESSAGE(JWRN_HIT_MARKER, "Corrupt JPEG data: premature end of data segment")
JMESSAGE(JWRN_HUFF_BAD_CODE, "Corrupt JPEG data: bad Huffman code")
JMESSAGE(JWRN_JFIF_MAJOR, "Warning: unknown JFIF revision number %d.%02d")
JMESSAGE(JWRN_JPEG_EOF, "Premature end of JPEG file")
JMESSAGE(JWRN_MUST_RESYNC,
"Corrupt JPEG data: found marker 0x%02x instead of RST%d")
JMESSAGE(JWRN_NOT_SEQUENTIAL, "Invalid SOS parameters for sequential JPEG")
JMESSAGE(JWRN_TOO_MUCH_DATA, "Application transferred too many scanlines")
#if JPEG_LIB_VERSION < 70
JMESSAGE(JERR_BAD_CROP_SPEC, "Invalid crop request")
#if defined(C_ARITH_CODING_SUPPORTED) || defined(D_ARITH_CODING_SUPPORTED)
JMESSAGE(JERR_NO_ARITH_TABLE, "Arithmetic table 0x%02x was not defined")
JMESSAGE(JWRN_ARITH_BAD_CODE, "Corrupt JPEG data: bad arithmetic code")
#endif
#endif
JMESSAGE(JWRN_BOGUS_ICC, "Corrupt JPEG data: bad ICC marker")
#if JPEG_LIB_VERSION < 70
JMESSAGE(JERR_BAD_DROP_SAMPLING,
"Component index %d: mismatching sampling ratio %d:%d, %d:%d, %c")
#endif
JMESSAGE(JERR_BAD_RESTART,
"Invalid restart interval %d; must be an integer multiple of the number of MCUs in an MCU row (%d)")
#ifdef JMAKE_ENUM_LIST
JMSG_LASTMSGCODE
} J_MESSAGE_CODE;
#undef JMAKE_ENUM_LIST
#endif /* JMAKE_ENUM_LIST */
/* Zap JMESSAGE macro so that future re-inclusions do nothing by default */
#undef JMESSAGE
#ifndef JERROR_H
#define JERROR_H
/* Macros to simplify using the error and trace message stuff */
/* The first parameter is either type of cinfo pointer */
/* Fatal errors (print message and exit) */
#define ERREXIT(cinfo, code) \
((cinfo)->err->msg_code = (code), \
(*(cinfo)->err->error_exit) ((j_common_ptr)(cinfo)))
#define ERREXIT1(cinfo, code, p1) \
((cinfo)->err->msg_code = (code), \
(cinfo)->err->msg_parm.i[0] = (p1), \
(*(cinfo)->err->error_exit) ((j_common_ptr)(cinfo)))
#define ERREXIT2(cinfo, code, p1, p2) \
((cinfo)->err->msg_code = (code), \
(cinfo)->err->msg_parm.i[0] = (p1), \
(cinfo)->err->msg_parm.i[1] = (p2), \
(*(cinfo)->err->error_exit) ((j_common_ptr)(cinfo)))
#define ERREXIT3(cinfo, code, p1, p2, p3) \
((cinfo)->err->msg_code = (code), \
(cinfo)->err->msg_parm.i[0] = (p1), \
(cinfo)->err->msg_parm.i[1] = (p2), \
(cinfo)->err->msg_parm.i[2] = (p3), \
(*(cinfo)->err->error_exit) ((j_common_ptr)(cinfo)))
#define ERREXIT4(cinfo, code, p1, p2, p3, p4) \
((cinfo)->err->msg_code = (code), \
(cinfo)->err->msg_parm.i[0] = (p1), \
(cinfo)->err->msg_parm.i[1] = (p2), \
(cinfo)->err->msg_parm.i[2] = (p3), \
(cinfo)->err->msg_parm.i[3] = (p4), \
(*(cinfo)->err->error_exit) ((j_common_ptr)(cinfo)))
#define ERREXIT6(cinfo, code, p1, p2, p3, p4, p5, p6) \
((cinfo)->err->msg_code = (code), \
(cinfo)->err->msg_parm.i[0] = (p1), \
(cinfo)->err->msg_parm.i[1] = (p2), \
(cinfo)->err->msg_parm.i[2] = (p3), \
(cinfo)->err->msg_parm.i[3] = (p4), \
(cinfo)->err->msg_parm.i[4] = (p5), \
(cinfo)->err->msg_parm.i[5] = (p6), \
(*(cinfo)->err->error_exit) ((j_common_ptr)(cinfo)))
#define ERREXITS(cinfo, code, str) \
((cinfo)->err->msg_code = (code), \
strncpy((cinfo)->err->msg_parm.s, (str), JMSG_STR_PARM_MAX - 1), \
(cinfo)->err->msg_parm.s[JMSG_STR_PARM_MAX - 1] = '\0', \
(*(cinfo)->err->error_exit) ((j_common_ptr)(cinfo)))
#define MAKESTMT(stuff) do { stuff } while (0)
/* Nonfatal errors (we can keep going, but the data is probably corrupt) */
#define WARNMS(cinfo, code) \
((cinfo)->err->msg_code = (code), \
(*(cinfo)->err->emit_message) ((j_common_ptr)(cinfo), -1))
#define WARNMS1(cinfo, code, p1) \
((cinfo)->err->msg_code = (code), \
(cinfo)->err->msg_parm.i[0] = (p1), \
(*(cinfo)->err->emit_message) ((j_common_ptr)(cinfo), -1))
#define WARNMS2(cinfo, code, p1, p2) \
((cinfo)->err->msg_code = (code), \
(cinfo)->err->msg_parm.i[0] = (p1), \
(cinfo)->err->msg_parm.i[1] = (p2), \
(*(cinfo)->err->emit_message) ((j_common_ptr)(cinfo), -1))
/* Informational/debugging messages */
#define TRACEMS(cinfo, lvl, code) \
((cinfo)->err->msg_code = (code), \
(*(cinfo)->err->emit_message) ((j_common_ptr)(cinfo), (lvl)))
#define TRACEMS1(cinfo, lvl, code, p1) \
((cinfo)->err->msg_code = (code), \
(cinfo)->err->msg_parm.i[0] = (p1), \
(*(cinfo)->err->emit_message) ((j_common_ptr)(cinfo), (lvl)))
#define TRACEMS2(cinfo, lvl, code, p1, p2) \
((cinfo)->err->msg_code = (code), \
(cinfo)->err->msg_parm.i[0] = (p1), \
(cinfo)->err->msg_parm.i[1] = (p2), \
(*(cinfo)->err->emit_message) ((j_common_ptr)(cinfo), (lvl)))
#define TRACEMS3(cinfo, lvl, code, p1, p2, p3) \
MAKESTMT(int *_mp = (cinfo)->err->msg_parm.i; \
_mp[0] = (p1); _mp[1] = (p2); _mp[2] = (p3); \
(cinfo)->err->msg_code = (code); \
(*(cinfo)->err->emit_message) ((j_common_ptr)(cinfo), (lvl)); )
#define TRACEMS4(cinfo, lvl, code, p1, p2, p3, p4) \
MAKESTMT(int *_mp = (cinfo)->err->msg_parm.i; \
_mp[0] = (p1); _mp[1] = (p2); _mp[2] = (p3); _mp[3] = (p4); \
(cinfo)->err->msg_code = (code); \
(*(cinfo)->err->emit_message) ((j_common_ptr)(cinfo), (lvl)); )
#define TRACEMS5(cinfo, lvl, code, p1, p2, p3, p4, p5) \
MAKESTMT(int *_mp = (cinfo)->err->msg_parm.i; \
_mp[0] = (p1); _mp[1] = (p2); _mp[2] = (p3); _mp[3] = (p4); \
_mp[4] = (p5); \
(cinfo)->err->msg_code = (code); \
(*(cinfo)->err->emit_message) ((j_common_ptr)(cinfo), (lvl)); )
#define TRACEMS8(cinfo, lvl, code, p1, p2, p3, p4, p5, p6, p7, p8) \
MAKESTMT(int *_mp = (cinfo)->err->msg_parm.i; \
_mp[0] = (p1); _mp[1] = (p2); _mp[2] = (p3); _mp[3] = (p4); \
_mp[4] = (p5); _mp[5] = (p6); _mp[6] = (p7); _mp[7] = (p8); \
(cinfo)->err->msg_code = (code); \
(*(cinfo)->err->emit_message) ((j_common_ptr)(cinfo), (lvl)); )
#define TRACEMSS(cinfo, lvl, code, str) \
((cinfo)->err->msg_code = (code), \
strncpy((cinfo)->err->msg_parm.s, (str), JMSG_STR_PARM_MAX), \
(cinfo)->err->msg_parm.s[JMSG_STR_PARM_MAX - 1] = '\0', \
(*(cinfo)->err->emit_message) ((j_common_ptr)(cinfo), (lvl)))
#endif /* JERROR_H */
@@ -0,0 +1,389 @@
/*
* jmorecfg.h
*
* This file was part of the Independent JPEG Group's software:
* Copyright (C) 1991-1997, Thomas G. Lane.
* Modified 1997-2009 by Guido Vollbeding.
* Lossless JPEG Modifications:
* Copyright (C) 1999, Ken Murchison.
* libjpeg-turbo Modifications:
* Copyright (C) 2009, 2011, 2014-2015, 2018, 2020, 2022, 2026,
* D. R. Commander.
* For conditions of distribution and use, see the accompanying README.ijg
* file.
*
* This file contains additional configuration options that customize the
* JPEG software for special applications or support machine-dependent
* optimizations. Most users will not need to touch this file.
*/
/*
* Maximum number of components (color channels) allowed in JPEG image.
* To meet the letter of Rec. ITU-T T.81 | ISO/IEC 10918-1, set this to 255.
* However, darn few applications need more than 4 channels (maybe 5 for CMYK +
* alpha mask). We recommend 10 as a reasonable compromise; use 4 if you are
* really short on memory. (Each allowed component costs a hundred or so
* bytes of storage, whether actually used in an image or not.)
*/
#define MAX_COMPONENTS 10 /* maximum number of image components */
/*
* Basic data types.
* You may need to change these if you have a machine with unusual data
* type sizes; for example, "char" not 8 bits, "short" not 16 bits,
* or "long" not 32 bits. We don't care whether "int" is 16 or 32 bits,
* but it had better be at least 16.
*/
/* Representation of a single sample (pixel element value).
* We frequently allocate large arrays of these, so it's important to keep
* them small. But if you have memory to burn and access to char or short
* arrays is very slow on your hardware, you might want to change these.
*/
/* JSAMPLE should be the smallest type that will hold the values 0..255. */
typedef unsigned char JSAMPLE;
#define GETJSAMPLE(value) ((int)(value))
#define MAXJSAMPLE 255
#define CENTERJSAMPLE 128
/* J12SAMPLE should be the smallest type that will hold the values 0..4095. */
typedef short J12SAMPLE;
#define MAXJ12SAMPLE 4095
#define CENTERJ12SAMPLE 2048
/* J16SAMPLE should be the smallest type that will hold the values 0..65535. */
typedef unsigned short J16SAMPLE;
#define MAXJ16SAMPLE 65535
#define CENTERJ16SAMPLE 32768
/* Representation of a DCT frequency coefficient.
* This should be a signed value of at least 16 bits; "short" is usually OK.
* Again, we allocate large arrays of these, but you can change to int
* if you have memory to burn and "short" is really slow.
*/
typedef short JCOEF;
/* Compressed datastreams are represented as arrays of JOCTET.
* These must be EXACTLY 8 bits wide, at least once they are written to
* external storage. Note that when using the stdio data source/destination
* managers, this is also the data type passed to fread/fwrite.
*/
typedef unsigned char JOCTET;
#define GETJOCTET(value) (value)
/* These typedefs are used for various table entries and so forth.
* They must be at least as wide as specified; but making them too big
* won't cost a huge amount of memory, so we don't provide special
* extraction code like we did for JSAMPLE. (In other words, these
* typedefs live at a different point on the speed/space tradeoff curve.)
*/
/* UINT8 must hold at least the values 0..255. */
typedef unsigned char UINT8;
/* UINT16 must hold at least the values 0..65535. */
typedef unsigned short UINT16;
/* INT16 must hold at least the values -32768..32767. */
#ifndef XMD_H /* X11/xmd.h correctly defines INT16 */
typedef short INT16;
#endif
/* INT32 must hold at least signed 32-bit values.
*
* NOTE: The INT32 typedef dates back to libjpeg v5 (1994.) Integers were
* sometimes 16-bit back then (MS-DOS), which is why INT32 is typedef'd to
* long. It also wasn't common (or at least as common) in 1994 for INT32 to be
* defined by platform headers. Since then, however, INT32 is defined in
* several other common places:
*
* Xmd.h (X11 header) typedefs INT32 to int on 64-bit platforms and long on
* 32-bit platforms (i.e always a 32-bit signed type.)
*
* basetsd.h (Win32 header) typedefs INT32 to int (always a 32-bit signed type
* on modern platforms.)
*
* qglobal.h (Qt header) typedefs INT32 to int (always a 32-bit signed type on
* modern platforms.)
*
* This is a recipe for conflict, since "long" and "int" aren't always
* compatible types. Since the definition of INT32 has technically been part
* of the libjpeg API for more than 20 years, we can't remove it, but we do not
* use it internally any longer. We instead define a separate type (JLONG)
* for internal use, which ensures that internal behavior will always be the
* same regardless of any external headers that may be included.
*/
#ifndef XMD_H /* X11/xmd.h correctly defines INT32 */
#ifndef _BASETSD_H_ /* Microsoft defines it in basetsd.h */
#ifndef _BASETSD_H /* MinGW is slightly different */
#ifndef QGLOBAL_H /* Qt defines it in qglobal.h */
typedef long INT32;
#endif
#endif
#endif
#endif
/* Datatype used for image dimensions. The JPEG standard only supports
* images up to 64K*64K due to 16-bit fields in SOF markers. Therefore
* "unsigned int" is sufficient on all machines. However, if you need to
* handle larger images and you don't mind deviating from the spec, you
* can change this datatype. (Note that changing this datatype will
* potentially require modifying the SIMD code. The x86-64 SIMD extensions,
* in particular, assume a 32-bit JDIMENSION.)
*/
typedef unsigned int JDIMENSION;
#define JPEG_MAX_DIMENSION 65500L /* a tad under 64K to prevent overflows */
/* These macros are used in all function definitions and extern declarations.
* You could modify them if you need to change function linkage conventions;
* in particular, you'll need to do that to make the library a Windows DLL.
* Another application is to make all functions global for use with debuggers
* or code profilers that require it.
*/
/* a function called through method pointers: */
#define METHODDEF(type) static type
/* a function used only in its module: */
#define LOCAL(type) static type
/* a function referenced thru EXTERNs: */
#define GLOBAL(type) type
/* a reference to a GLOBAL function: */
#define EXTERN(type) extern type
/* Originally, this macro was used as a way of defining function prototypes
* for both modern compilers as well as older compilers that did not support
* prototype parameters. libjpeg-turbo has never supported these older,
* non-ANSI compilers, but the macro is still included because there is some
* software out there that uses it.
*/
#define JMETHOD(type, methodname, arglist) type (*methodname) arglist
/* libjpeg-turbo no longer supports platforms that have far symbols (MS-DOS),
* but again, some software relies on this macro.
*/
#undef FAR
#define FAR
/*
* On a few systems, type boolean and/or its values FALSE, TRUE may appear
* in standard header files. Or you may have conflicts with application-
* specific header files that you want to include together with these files.
* Defining HAVE_BOOLEAN before including jpeglib.h should make it work.
*/
#ifndef HAVE_BOOLEAN
typedef int boolean;
#endif
#ifndef FALSE /* in case these macros already exist */
#define FALSE 0 /* values of boolean */
#endif
#ifndef TRUE
#define TRUE 1
#endif
/*
* The remaining options affect code selection within the JPEG library,
* but they don't need to be visible to most applications using the library.
* To minimize application namespace pollution, the symbols won't be
* defined unless JPEG_INTERNALS or JPEG_INTERNAL_OPTIONS has been defined.
*/
#ifdef JPEG_INTERNALS
#define JPEG_INTERNAL_OPTIONS
#endif
#ifdef JPEG_INTERNAL_OPTIONS
/*
* These defines indicate whether to include various optional functions.
* Undefining some of these symbols will produce a smaller but less capable
* library. Note that you can leave certain source files out of the
* compilation/linking process if you've #undef'd the corresponding symbols.
* (You may HAVE to do that if your compiler doesn't like null source files.)
*/
/* Capability options common to encoder and decoder: */
#define DCT_ISLOW_SUPPORTED /* accurate integer method */
#define DCT_IFAST_SUPPORTED /* less accurate int method [legacy feature] */
#define DCT_FLOAT_SUPPORTED /* floating-point method [legacy feature] */
/* Encoder capability options: */
#define C_MULTISCAN_FILES_SUPPORTED /* Multiple-scan JPEG files? */
#define C_PROGRESSIVE_SUPPORTED /* Progressive JPEG? (Requires
C_MULTISCAN_FILES_SUPPORTED and
ENTROPY_OPT_SUPPORTED) */
#define C_LOSSLESS_SUPPORTED /* Lossless JPEG? */
#define ENTROPY_OPT_SUPPORTED /* Optimization of entropy coding parms? */
/* Note: if you selected 12-bit data precision, it is dangerous to turn off
* ENTROPY_OPT_SUPPORTED. The standard Huffman tables are only good for 8-bit
* precision, so jchuff.c normally uses entropy optimization to compute
* usable tables for higher precision. If you don't want to do optimization,
* you'll have to supply different default Huffman tables.
* The exact same statements apply for lossless JPEG: the default tables don't
* work for lossless mode. (This may get fixed, however.)
*/
#define INPUT_SMOOTHING_SUPPORTED /* Input image smoothing option? */
/* Decoder capability options: */
#define D_MULTISCAN_FILES_SUPPORTED /* Multiple-scan JPEG files? */
#define D_PROGRESSIVE_SUPPORTED /* Progressive JPEG? (Requires
D_MULTISCAN_FILES_SUPPORTED) */
#define D_LOSSLESS_SUPPORTED /* Lossless JPEG? (Requires
D_MULTISCAN_FILES_SUPPORTED) */
#define SAVE_MARKERS_SUPPORTED /* jpeg_save_markers() needed? */
#define BLOCK_SMOOTHING_SUPPORTED /* Block smoothing? (Progressive only) */
#define IDCT_SCALING_SUPPORTED /* Output rescaling via IDCT? (Requires
DCT_ISLOW_SUPPORTED) */
#define UPSAMPLE_MERGING_SUPPORTED /* Fast path for sloppy upsampling? */
#define QUANT_1PASS_SUPPORTED /* 1-pass color quantization? */
#define QUANT_2PASS_SUPPORTED /* 2-pass color quantization? */
/* more capability options later, no doubt */
/*
* The RGB_RED, RGB_GREEN, RGB_BLUE, and RGB_PIXELSIZE macros are a vestigial
* feature of libjpeg. The idea was that, if an application developer needed
* to compress from/decompress to a BGR/BGRX/RGBX/XBGR/XRGB buffer, they could
* change these macros, rebuild libjpeg, and link their application statically
* with it. In reality, few people ever did this, because there were some
* severe restrictions involved (cjpeg and djpeg no longer worked properly,
* compressing/decompressing RGB JPEGs no longer worked properly, and the color
* quantizer wouldn't work with pixel sizes other than 3.) Furthermore, since
* all of the O/S-supplied versions of libjpeg were built with the default
* values of RGB_RED, RGB_GREEN, RGB_BLUE, and RGB_PIXELSIZE, many applications
* have come to regard these values as immutable.
*
* The libjpeg-turbo colorspace extensions provide a much cleaner way of
* compressing from/decompressing to buffers with arbitrary component orders
* and pixel sizes. Thus, we do not support changing the values of RGB_RED,
* RGB_GREEN, RGB_BLUE, or RGB_PIXELSIZE. In addition to the restrictions
* listed above, changing these values will also break the SIMD extensions and
* the regression tests.
*/
#define RGB_RED 0 /* Offset of Red in an RGB scanline element */
#define RGB_GREEN 1 /* Offset of Green */
#define RGB_BLUE 2 /* Offset of Blue */
#define RGB_PIXELSIZE 3 /* JSAMPLEs per RGB scanline element */
#define JPEG_NUMCS 17
#define EXT_RGB_RED 0
#define EXT_RGB_GREEN 1
#define EXT_RGB_BLUE 2
#define EXT_RGB_PIXELSIZE 3
#define EXT_RGBX_RED 0
#define EXT_RGBX_GREEN 1
#define EXT_RGBX_BLUE 2
#define EXT_RGBX_PIXELSIZE 4
#define EXT_BGR_RED 2
#define EXT_BGR_GREEN 1
#define EXT_BGR_BLUE 0
#define EXT_BGR_PIXELSIZE 3
#define EXT_BGRX_RED 2
#define EXT_BGRX_GREEN 1
#define EXT_BGRX_BLUE 0
#define EXT_BGRX_PIXELSIZE 4
#define EXT_XBGR_RED 3
#define EXT_XBGR_GREEN 2
#define EXT_XBGR_BLUE 1
#define EXT_XBGR_PIXELSIZE 4
#define EXT_XRGB_RED 1
#define EXT_XRGB_GREEN 2
#define EXT_XRGB_BLUE 3
#define EXT_XRGB_PIXELSIZE 4
static const int rgb_red[JPEG_NUMCS] = {
-1, -1, RGB_RED, -1, -1, -1, EXT_RGB_RED, EXT_RGBX_RED,
EXT_BGR_RED, EXT_BGRX_RED, EXT_XBGR_RED, EXT_XRGB_RED,
EXT_RGBX_RED, EXT_BGRX_RED, EXT_XBGR_RED, EXT_XRGB_RED,
-1
};
static const int rgb_green[JPEG_NUMCS] = {
-1, -1, RGB_GREEN, -1, -1, -1, EXT_RGB_GREEN, EXT_RGBX_GREEN,
EXT_BGR_GREEN, EXT_BGRX_GREEN, EXT_XBGR_GREEN, EXT_XRGB_GREEN,
EXT_RGBX_GREEN, EXT_BGRX_GREEN, EXT_XBGR_GREEN, EXT_XRGB_GREEN,
-1
};
static const int rgb_blue[JPEG_NUMCS] = {
-1, -1, RGB_BLUE, -1, -1, -1, EXT_RGB_BLUE, EXT_RGBX_BLUE,
EXT_BGR_BLUE, EXT_BGRX_BLUE, EXT_XBGR_BLUE, EXT_XRGB_BLUE,
EXT_RGBX_BLUE, EXT_BGRX_BLUE, EXT_XBGR_BLUE, EXT_XRGB_BLUE,
-1
};
static const int rgb_pixelsize[JPEG_NUMCS] = {
-1, -1, RGB_PIXELSIZE, -1, -1, -1, EXT_RGB_PIXELSIZE, EXT_RGBX_PIXELSIZE,
EXT_BGR_PIXELSIZE, EXT_BGRX_PIXELSIZE, EXT_XBGR_PIXELSIZE, EXT_XRGB_PIXELSIZE,
EXT_RGBX_PIXELSIZE, EXT_BGRX_PIXELSIZE, EXT_XBGR_PIXELSIZE, EXT_XRGB_PIXELSIZE,
-1
};
/* Definitions for speed-related optimizations. */
/* On some machines (notably 68000 series) "int" is 32 bits, but multiplying
* two 16-bit shorts is faster than multiplying two ints. Define MULTIPLIER
* as short on such a machine. MULTIPLIER must be at least 16 bits wide.
*/
#ifndef MULTIPLIER
#ifndef WITH_SIMD
#define MULTIPLIER int /* type for fastest integer multiply */
#else
#define MULTIPLIER short /* prefer 16-bit with SIMD for parellelism */
#endif
#endif
/* FAST_FLOAT should be either float or double, whichever is done faster
* by your compiler. (Note that this type is only used in the floating point
* DCT routines, so it only matters if you've defined DCT_FLOAT_SUPPORTED.)
*/
#ifndef FAST_FLOAT
#define FAST_FLOAT float
#endif
#endif /* JPEG_INTERNAL_OPTIONS */
File diff suppressed because it is too large Load Diff
@@ -0,0 +1,101 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
#ifndef BUFFER_HH
#define BUFFER_HH
#include <qpdf/DLL.h>
#include <cstddef>
#include <memory>
#include <string>
#include <string_view>
class Buffer
{
public:
QPDF_DLL
Buffer();
// Create a Buffer object whose memory is owned by the class and will be freed when the Buffer
// object is destroyed.
QPDF_DLL
Buffer(size_t size);
QPDF_DLL
Buffer(std::string&& content);
// Create a Buffer object whose memory is owned by the caller and will not be freed when the
// Buffer is destroyed.
QPDF_DLL
Buffer(unsigned char* buf, size_t size);
QPDF_DLL
Buffer(std::string& content);
Buffer(Buffer const&) = delete;
Buffer& operator=(Buffer const&) = delete;
QPDF_DLL
Buffer(Buffer&&) noexcept;
QPDF_DLL
Buffer& operator=(Buffer&&) noexcept;
QPDF_DLL
~Buffer();
QPDF_DLL
size_t getSize() const;
QPDF_DLL
unsigned char const* getBuffer() const;
QPDF_DLL
unsigned char* getBuffer();
// Create a new copy of the Buffer. The new Buffer owns an independent copy of the data.
QPDF_DLL
Buffer copy() const;
// Move the content of the Buffer. After calling this method, the Buffer will be empty if the
// buffer owns its memory. Otherwise, the Buffer will be unchanged.
QPDF_DLL
std::string move();
// Return a string_view to the data.
QPDF_DLL
std::string_view view() const;
// Return a pointer to the data. NB: Unlike getBuffer, this method returns a valid pointer even
// if the Buffer is empty.
QPDF_DLL
char const* data() const;
// Return a pointer to the data. NB: Unlike getBuffer, this method returns a valid pointer even
// if the Buffer is empty.
QPDF_DLL
char* data();
QPDF_DLL
bool empty() const;
QPDF_DLL
size_t size() const;
private:
class Members;
std::unique_ptr<Members> m;
};
#endif // BUFFER_HH
@@ -0,0 +1,70 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
#ifndef QPDF_BUFFERINPUTSOURCE_HH
#define QPDF_BUFFERINPUTSOURCE_HH
#include <qpdf/Buffer.hh>
#include <qpdf/InputSource.hh>
#include <memory>
class QPDF_DLL_CLASS BufferInputSource: public InputSource
{
public:
// If own_memory is true, BufferInputSource will delete the buffer when finished with it.
// Otherwise, the caller owns the memory.
QPDF_DLL
BufferInputSource(std::string const& description, Buffer* buf, bool own_memory = false);
// NB This overload copies the string contents.
QPDF_DLL
BufferInputSource(std::string const& description, std::string const& contents);
QPDF_DLL
~BufferInputSource() override;
QPDF_DLL
qpdf_offset_t findAndSkipNextEOL() override;
QPDF_DLL
std::string const& getName() const override;
QPDF_DLL
qpdf_offset_t tell() override;
QPDF_DLL
void seek(qpdf_offset_t offset, int whence) override;
QPDF_DLL
void rewind() override;
QPDF_DLL
size_t read(char* buffer, size_t length) override;
QPDF_DLL
void unreadCh(char ch) override;
private:
#ifndef QPDF_FUTURE
bool own_memory;
std::string description;
Buffer* buf;
qpdf_offset_t cur_offset;
qpdf_offset_t max_offset;
#else
class Members;
std::unique_ptr<Members> m;
#endif
};
#endif // QPDF_BUFFERINPUTSOURCE_HH
@@ -0,0 +1,77 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
#ifndef QPDF_CLOSEDFILEINPUTSOURCE_HH
#define QPDF_CLOSEDFILEINPUTSOURCE_HH
#include <qpdf/InputSource.hh>
#include <memory>
class FileInputSource;
// This is an input source that reads from files, like FileInputSource, except that it opens and
// closes the file surrounding every operation. This decreases efficiency, but it allows many more
// of these to exist at once than the maximum number of open file descriptors. This is used for
// merging large numbers of files.
class QPDF_DLL_CLASS ClosedFileInputSource: public InputSource
{
public:
QPDF_DLL
ClosedFileInputSource(char const* filename);
ClosedFileInputSource(ClosedFileInputSource const&) = delete;
ClosedFileInputSource& operator=(ClosedFileInputSource const&) = delete;
QPDF_DLL
~ClosedFileInputSource() override;
QPDF_DLL
qpdf_offset_t findAndSkipNextEOL() override;
QPDF_DLL
std::string const& getName() const override;
QPDF_DLL
qpdf_offset_t tell() override;
QPDF_DLL
void seek(qpdf_offset_t offset, int whence) override;
QPDF_DLL
void rewind() override;
QPDF_DLL
size_t read(char* buffer, size_t length) override;
QPDF_DLL
void unreadCh(char ch) override;
// The file stays open between calls to stayOpen(true) and stayOpen(false). You can use this to
// surround multiple operations on a single ClosedFileInputSource to reduce the overhead of a
// separate open/close on each call.
QPDF_DLL
void stayOpen(bool);
private:
QPDF_DLL_PRIVATE
void before();
QPDF_DLL_PRIVATE
void after();
std::string filename;
qpdf_offset_t offset{0};
std::shared_ptr<FileInputSource> fis;
bool stay_open{false};
};
#endif // QPDF_CLOSEDFILEINPUTSOURCE_HH
@@ -0,0 +1,297 @@
/* Copyright (c) 2005-2021 Jay Berkenbilt
* Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
*
* This file is part of qpdf.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
* Versions of qpdf prior to version 7 were released under the terms
* of version 2.0 of the Artistic License. At your option, you may
* continue to consider qpdf to be licensed under those terms. Please
* see the manual for additional information.
*/
#ifndef QPDFCONSTANTS_H
#define QPDFCONSTANTS_H
/*
* REMEMBER:
*
* Keep this file 'C' compatible so it can be used from the C and C++
* interfaces.
*/
/* ****************************** NOTE ******************************
Tl;Dr: new values must be added to the end such that no constant's
numerical value changes, even across major releases.
Details:
As new values are added to existing enumerated types in this file,
it is important not to change the actual values of any constants.
This means that, in the absence of explicit assignment of values,
the order of entries can't change even across major releases. Why?
Here are the reasons:
* Many of these constants are used by the C API. The C API is used
through foreign function call interfaces by users of other languages
who may not have access to or the ability to parse a C header file.
As such, users are likely to hard-code numerical values or create
their own constants whose values match. If we change values here,
their code would break, and there would be no way to detect it short
of noticing a bug. Furthermore, it would be difficult to write code
that properly handled more than one version of the qpdf shared
object (e.g. DLL) since the information about what version of qpdf
is involved is only available at runtime.
- It has happened from time to time that a user builds an application
with an incorrectly installed qpdf, such as having mismatched header
files and library files. In the event that they are only using qpdf
interfaces that have been stable across the versions in question,
this turns out to be harmless. If they happen to use non-compatible
interfaces, this results usually in a failure to load or an obvious
runtime error. If we change values of constants, it is possible that
code that links and runs may have mismatched values for constants.
This would create a bug that would be extremely difficult to track
down and impossible for qpdf maintainers to reproduce.
*/
/* Exit Codes from QPDFJob and the qpdf CLI */
enum qpdf_exit_code_e {
qpdf_exit_success = 0,
/* Normal exit codes */
qpdf_exit_error = 2,
qpdf_exit_warning = 3,
/* For --is-encrypted and --requires-password */
qpdf_exit_is_not_encrypted = 2,
qpdf_exit_correct_password = 3,
};
/* Error Codes */
enum qpdf_error_code_e {
qpdf_e_success = 0,
qpdf_e_internal, /* logic/programming error -- indicates bug */
qpdf_e_system, /* I/O error, memory error, etc. */
qpdf_e_unsupported, /* PDF feature not (yet) supported by qpdf */
qpdf_e_password, /* incorrect password for encrypted file */
qpdf_e_damaged_pdf, /* syntax errors or other damage in PDF */
qpdf_e_pages, /* erroneous or unsupported pages structure */
qpdf_e_object, /* type/bounds errors accessing objects */
qpdf_e_json, /* error in qpdf JSON */
qpdf_e_linearization, /* linearization warning */
};
/* Object Types */
/* PDF objects represented by QPDFObjectHandle or, in the C API, by
* qpdf_oh, have a unique type code that has one of the values in the
* list below. As new object types are added to qpdf, additional items
* may be added to the list, so code that switches on these values
* should take that into consideration. (Maintainer note: it would be
* better to call this qpdf_ot_* rather than ot_* to reduce likelihood
* of name collision, but changing the names of the values breaks
* backward compatibility.)
*/
enum qpdf_object_type_e {
/* Object types internal to qpdf */
ot_uninitialized,
ot_reserved,
/* Object types that can occur in the main document */
ot_null,
ot_boolean,
ot_integer,
ot_real,
ot_string,
ot_name,
ot_array,
ot_dictionary,
ot_stream,
/* Additional object types that can occur in content streams */
ot_operator,
ot_inlineimage,
/* Object types internal to qpdf */
ot_unresolved,
ot_destroyed,
ot_reference,
};
/* Write Parameters. See QPDFWriter.hh for details. */
enum qpdf_object_stream_e {
qpdf_o_disable = 0, /* disable object streams */
qpdf_o_preserve, /* preserve object streams */
qpdf_o_generate /* generate object streams */
};
enum qpdf_stream_data_e {
qpdf_s_uncompress = 0, /* uncompress stream data */
qpdf_s_preserve, /* preserve stream data compression */
qpdf_s_compress /* compress stream data */
};
/* Stream data flags */
/* See pipeStreamData in QPDFObjectHandle.hh for details on these flags. */
enum qpdf_stream_encode_flags_e {
qpdf_ef_compress = 1 << 0, /* compress uncompressed streams */
qpdf_ef_normalize = 1 << 1, /* normalize content stream */
};
enum qpdf_stream_decode_level_e {
/* These must be in order from less to more decoding. */
qpdf_dl_none = 0, /* preserve all stream filters */
qpdf_dl_generalized, /* decode general-purpose filters */
qpdf_dl_specialized, /* also decode other non-lossy filters */
qpdf_dl_all /* also decode lossy filters */
};
/* For JSON encoding */
enum qpdf_json_stream_data_e {
qpdf_sj_none = 0,
qpdf_sj_inline,
qpdf_sj_file,
};
/* R3 Encryption Parameters */
enum qpdf_r3_print_e {
qpdf_r3p_full = 0, /* allow all printing */
qpdf_r3p_low, /* allow only low-resolution printing */
qpdf_r3p_none /* allow no printing */
};
/* qpdf_r3_modify_e doesn't allow the full flexibility of the spec. It
* corresponds to options in Acrobat 5's menus. The new interface in
* QPDFWriter offers more granularity and no longer uses this type.
*/
enum qpdf_r3_modify_e /* Allowed changes: */
{
qpdf_r3m_all = 0, /* All editing */
qpdf_r3m_annotate, /* Comments, fill forms, signing, assembly */
qpdf_r3m_form, /* Fill forms, signing, assembly */
qpdf_r3m_assembly, /* Only document assembly */
qpdf_r3m_none /* No modifications */
};
/* Form field flags from the PDF spec */
enum pdf_form_field_flag_e {
/* flags that apply to all form fields */
ff_all_read_only = 1 << 0,
ff_all_required = 1 << 1,
ff_all_no_export = 1 << 2,
/* flags that apply to fields of type /Btn (button) */
ff_btn_no_toggle_off = 1 << 14,
ff_btn_radio = 1 << 15,
ff_btn_pushbutton = 1 << 16,
ff_btn_radios_in_unison = 1 << 17,
/* flags that apply to fields of type /Tx (text) */
ff_tx_multiline = 1 << 12,
ff_tx_password = 1 << 13,
ff_tx_file_select = 1 << 20,
ff_tx_do_not_spell_check = 1 << 22,
ff_tx_do_not_scroll = 1 << 23,
ff_tx_comb = 1 << 24,
ff_tx_rich_text = 1 << 25,
/* flags that apply to fields of type /Ch (choice) */
ff_ch_combo = 1 << 17,
ff_ch_edit = 1 << 18,
ff_ch_sort = 1 << 19,
ff_ch_multi_select = 1 << 21,
ff_ch_do_not_spell_check = 1 << 22,
ff_ch_commit_on_sel_change = 1 << 26
};
/* Annotation flags from the PDF spec */
enum pdf_annotation_flag_e {
an_invisible = 1 << 0,
an_hidden = 1 << 1,
an_print = 1 << 2,
an_no_zoom = 1 << 3,
an_no_rotate = 1 << 4,
an_no_view = 1 << 5,
an_read_only = 1 << 6,
an_locked = 1 << 7,
an_toggle_no_view = 1 << 8,
an_locked_contents = 1 << 9
};
/* Encryption/password status for QPDFJob */
enum qpdf_encryption_status_e { qpdf_es_encrypted = 1 << 0, qpdf_es_password_incorrect = 1 << 1 };
/* Page label types */
enum qpdf_page_label_e {
pl_none,
pl_digits,
pl_alpha_lower,
pl_alpha_upper,
pl_roman_lower,
pl_roman_upper,
};
/**
* @enum qpdf_result_e
* @brief Enum representing result codes for qpdf C-API functions.
*
* Results <= qpdf_r_no_warn indicate success without warnings,
* qpdf_r_no_warn < result <= qpdf_r_success indicates success with warnings, and
* qpdf_r_success < result indicates failure.
*/
enum qpdf_result_e {
/* success */
qpdf_r_ok = 0,
qpdf_r_no_warn = 0xff, /// any result <= qpdf_no_warn indicates success without warning
qpdf_r_success = 0xffff, /// any result <= qpdf_r_success indicates success
/* failure */
qpdf_r_bad_parameter = 0x10000,
qpdf_r_no_warn_mask = 0x7fffff00,
qpdf_r_success_mask = 0x7fff0000,
};
/**
* @enum qpdf_param_e
* @brief This enumeration defines various parameters and configuration options for qpdf C-API
* functions.
*
* The enum values are grouped into sections based on their functionality, such as global
* options or global limits. For the meaning of individual parameters see `qpdf/global.cc`
*/
enum qpdf_param_e {
/* global state */
qpdf_p_limit_errors = 0x10020,
/* global options */
qpdf_p_inspection_mode = 0x11000,
qpdf_p_default_limits = 0x11100,
/* global limits */
/* parser limits */
qpdf_p_parser_max_nesting = 0x13000,
qpdf_p_parser_max_errors,
qpdf_p_parser_max_container_size,
qpdf_p_parser_max_container_size_damaged,
/* stream and filter limits */
qpdf_p_max_stream_filters = 0x14000,
/* next section = 0x20000 */
qpdf_enum_max = 0x7fffffff,
};
#endif /* QPDFCONSTANTS_H */
@@ -0,0 +1,140 @@
/* Copyright (c) 2005-2021 Jay Berkenbilt
* Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
*
* This file is part of qpdf.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
* Versions of qpdf prior to version 7 were released under the terms
* of version 2.0 of the Artistic License. At your option, you may
* continue to consider qpdf to be licensed under those terms. Please
* see the manual for additional information.
*/
#ifndef QPDF_DLL_HH
#define QPDF_DLL_HH
/* The first version of qpdf to include the version constants is 10.6.0. */
#define QPDF_MAJOR_VERSION 12
#define QPDF_MINOR_VERSION 3
#define QPDF_PATCH_VERSION 2
#ifdef QPDF_FUTURE
# define QPDF_VERSION "12.3.2+future"
#else
# define QPDF_VERSION "12.3.2"
#endif
/*
* This file defines symbols that control the which functions,
* classes, and methods are exposed to the public ABI (application
* binary interface). See below for a detailed explanation.
*/
#if defined _WIN32 || defined __CYGWIN__
# ifdef libqpdf_EXPORTS
# define QPDF_DLL __declspec(dllexport)
# else
# define QPDF_DLL
# endif
# define QPDF_DLL_PRIVATE
#elif defined __GNUC__
# define QPDF_DLL __attribute__((visibility("default")))
# define QPDF_DLL_PRIVATE __attribute__((visibility("hidden")))
#else
# define QPDF_DLL
# define QPDF_DLL_PRIVATE
#endif
#ifdef __GNUC__
# define QPDF_DLL_CLASS QPDF_DLL
#else
# define QPDF_DLL_CLASS
#endif
/*
Here's what's happening. See also https://gcc.gnu.org/wiki/Visibility
for a more in-depth discussion.
* Everything in the public ABI must be exported. Things not in the
public ABI should not be exported.
* A class's runtime type information is need if the class is going to
be used as an exception, inherited from, or tested with
dynamic_class. To do these things across a shared object boundary,
runtime type information must be exported.
* On Windows:
* For a symbol (function, method, etc.) to be exported into the
public ABI, it must be explicitly marked for export.
* If you mark a class for export, all symbols in the class,
including private methods, are exported into the DLL, and there is
no way to exclude something from export.
* A class's run-time type information is made available based on the
presence of a compiler flag (with MSVC), which is always on for
qpdf builds.
* Marking classes for export should be done only when *building* the
DLL, not when *using* the DLL.
* It is possible to mark symbols for import for DLL users, but it is
not necessary, and doing it right is complex in our case of being
multi-platform and building both static and shared libraries that
use the same headers, so we don't bother.
* If we don't export base classes with mingw, the vtables don't end
up in the DLL.
* On Linux (and other similar systems):
* Common compilers such as gcc and clang export all symbols into the
public ABI by default. The qpdf build overrides this by using
"visibility=hidden", which makes it behave more like Windows in
that things have to be explicitly exported to appear in the public
ABI.
* As with Windows, marking a class for export causes everything in
the class, including private methods, the be exported. However,
unlike in Windows:
* It is possible to explicitly mark symbols as private
* The only way to get the runtime type and vtable information into
the ABI is to mark the class as exported.
* It is harmless and sometimes necessary to include the visibility
marks when using the library as well as when building it. In
particular, clang on MacOS requires the visibility marks to
match in both cases.
What does this mean:
* On Windows, we never have to export a class, and while there is no
way to "unexport" something, we also have no need to do it.
* On non-Windows, we have to export some classes, and when we do, we
have to "unexport" some of their parts.
* We only use the libqpdf_EXPORTS as a conditional for defining the
symbols for Windows builds.
To achieve this, we use QPDF_DLL_CLASS to export classes, QPDF_DLL to
export methods, and QPDF_DLL_PRIVATE to unexport private methods in
exported classes.
*/
#endif /* QPDF_DLL_HH */
@@ -0,0 +1,64 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
#ifndef QPDF_FILEINPUTSOURCE_HH
#define QPDF_FILEINPUTSOURCE_HH
#include <qpdf/InputSource.hh>
class QPDF_DLL_CLASS FileInputSource: public InputSource
{
public:
FileInputSource() = default;
QPDF_DLL
FileInputSource(char const* filename);
QPDF_DLL
FileInputSource(char const* description, FILE* filep, bool close_file);
QPDF_DLL
void setFilename(char const* filename);
QPDF_DLL
void setFile(char const* description, FILE* filep, bool close_file);
FileInputSource(FileInputSource const&) = delete;
FileInputSource& operator=(FileInputSource const&) = delete;
QPDF_DLL
~FileInputSource() override;
QPDF_DLL
qpdf_offset_t findAndSkipNextEOL() override;
QPDF_DLL
std::string const& getName() const override;
QPDF_DLL
qpdf_offset_t tell() override;
QPDF_DLL
void seek(qpdf_offset_t offset, int whence) override;
QPDF_DLL
void rewind() override;
QPDF_DLL
size_t read(char* buffer, size_t length) override;
QPDF_DLL
void unreadCh(char ch) override;
private:
bool close_file{false};
std::string filename;
FILE* file{nullptr};
};
#endif // QPDF_FILEINPUTSOURCE_HH
@@ -0,0 +1,100 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
#ifndef QPDF_INPUTSOURCE_HH
#define QPDF_INPUTSOURCE_HH
#include <qpdf/DLL.h>
#include <qpdf/Types.h>
#include <cstdio>
#include <memory>
#include <string>
// Remember to use QPDF_DLL_CLASS on anything derived from InputSource so it will work with
// dynamic_cast across the shared object boundary.
class QPDF_DLL_CLASS InputSource
{
public:
InputSource() = default;
virtual ~InputSource() = default;
class QPDF_DLL_CLASS Finder
{
public:
QPDF_DLL
Finder() = default;
QPDF_DLL
virtual ~Finder() = default;
virtual bool check() = 0;
};
QPDF_DLL
void setLastOffset(qpdf_offset_t);
QPDF_DLL
qpdf_offset_t getLastOffset() const;
QPDF_DLL
std::string readLine(size_t max_line_length);
// Find first or last occurrence of a sequence of characters starting within the range defined
// by offset and len such that, when the input source is positioned at the beginning of that
// sequence, finder.check() returns true. If len is 0, the search proceeds until EOF. If a
// qualifying pattern is found, these methods return true and leave the input source positioned
// wherever check() left it at the end of the matching pattern.
QPDF_DLL
bool findFirst(char const* start_chars, qpdf_offset_t offset, size_t len, Finder& finder);
QPDF_DLL
bool findLast(char const* start_chars, qpdf_offset_t offset, size_t len, Finder& finder);
virtual qpdf_offset_t findAndSkipNextEOL() = 0;
virtual std::string const& getName() const = 0;
virtual qpdf_offset_t tell() = 0;
virtual void seek(qpdf_offset_t offset, int whence) = 0;
virtual void rewind() = 0;
virtual size_t read(char* buffer, size_t length) = 0;
// Note: you can only unread the character you just read. The specific character is ignored by
// some implementations, and the implementation doesn't check this. Use of unreadCh is
// semantically equivalent to seek(-1, SEEK_CUR) but is much more efficient.
virtual void unreadCh(char ch) = 0;
// The following methods are for internal use by qpdf only.
inline size_t read(std::string& str, size_t count, qpdf_offset_t at = -1);
inline std::string read(size_t count, qpdf_offset_t at = -1);
size_t read_line(std::string& str, size_t count, qpdf_offset_t at = -1);
std::string read_line(size_t count, qpdf_offset_t at = -1);
inline qpdf_offset_t fastTell();
inline bool fastRead(char&);
inline void fastUnread(bool);
inline void loadBuffer();
protected:
qpdf_offset_t last_offset{0};
private:
// State for fast... methods
static const qpdf_offset_t buf_size = 128;
char buffer[buf_size];
qpdf_offset_t buf_len = 0;
qpdf_offset_t buf_idx = 0;
qpdf_offset_t buf_start = 0;
};
#endif // QPDF_INPUTSOURCE_HH
@@ -0,0 +1,404 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
#ifndef JSON_HH
#define JSON_HH
#include <qpdf/DLL.h>
#include <qpdf/Types.h>
#include <functional>
#include <list>
#include <map>
#include <memory>
#include <set>
#include <string>
#include <vector>
class Pipeline;
class InputSource;
// This is a simple JSON serializer and parser, primarily designed for serializing QPDF Objects as
// JSON. While it may work as a general-purpose JSON parser/serializer, there are better options.
// JSON objects contain their data as smart pointers. When one JSON object is added to another, this
// pointer is copied. This means you can create temporary JSON objects on the stack, add them to
// other objects, and let them go out of scope safely. It also means that if a JSON object is added
// in more than one place, all copies share the underlying data. This makes them similar in
// structure and behavior to QPDFObjectHandle and may feel natural within the QPDF codebase, but it
// is also a good reason not to use this as a general-purpose JSON package.
class JSON
{
public:
static int constexpr LATEST = 2;
JSON() = default;
QPDF_DLL
std::string unparse() const;
// Write the JSON object through a pipeline. The `depth` parameter specifies how deeply nested
// this is in another JSON structure, which makes it possible to write clean-looking JSON
// incrementally.
QPDF_DLL
void write(Pipeline*, size_t depth = 0) const;
// Helper methods for writing JSON incrementally.
//
// "first" -- Several methods take a `bool& first` parameter. The open methods always set it to
// true, and the methods to output items always set it to false. This way, the item and close
// methods can always know whether or not a first item is being written. The intended mode of
// operation is to start with a new `bool first = true` each time a new container is opened and
// to pass that `first` through to all the methods that are called to add top-level items to the
// container as well as to close the container. This lets the JSON object use it to keep track
// of when it's writing a first object and when it's not. If incrementally writing multiple
// levels of depth, a new `first` should be used for each new container that is opened.
//
// "depth" -- Indicate the level of depth. This is used for consistent indentation. When writing
// incrementally, whenever you call a method to add an item to a container, the value of `depth`
// should be one more than whatever value is passed to the container open and close methods.
// Open methods ignore the value of first and set it to false
QPDF_DLL
static void writeDictionaryOpen(Pipeline*, bool& first, size_t depth = 0);
QPDF_DLL
static void writeArrayOpen(Pipeline*, bool& first, size_t depth = 0);
// Close methods don't modify first. A true value indicates that we are closing an empty object.
QPDF_DLL
static void writeDictionaryClose(Pipeline*, bool first, size_t depth = 0);
QPDF_DLL
static void writeArrayClose(Pipeline*, bool first, size_t depth = 0);
// The item methods use the value of first to determine if this is the first item and always set
// it to false.
QPDF_DLL
static void writeDictionaryItem(
Pipeline*, bool& first, std::string const& key, JSON const& value, size_t depth = 0);
// Write just the key of a new dictionary item, useful if writing nested structures. Calls
// writeNext.
QPDF_DLL
static void
writeDictionaryKey(Pipeline* p, bool& first, std::string const& key, size_t depth = 0);
QPDF_DLL
static void writeArrayItem(Pipeline*, bool& first, JSON const& element, size_t depth = 0);
// If writing nested structures incrementally, call writeNext before opening a new array or
// container in the midst of an existing one. The `first` you pass to writeNext should be the
// one for the parent object. The depth should be the one for the child object. Then start a new
// `first` for the nested item. Note that writeDictionaryKey and writeArrayItem call writeNext
// for you, so this is most important when writing subsequent items or container openers to an
// array.
QPDF_DLL
static void writeNext(Pipeline* p, bool& first, size_t depth = 0);
// The JSON spec calls dictionaries "objects", but that creates too much confusion when
// referring to instances of the JSON class.
QPDF_DLL
static JSON makeDictionary();
// addDictionaryMember returns the newly added item.
QPDF_DLL
JSON addDictionaryMember(std::string const& key, JSON const&);
QPDF_DLL
static JSON makeArray();
// addArrayElement returns the newly added item.
QPDF_DLL
JSON addArrayElement(JSON const&);
QPDF_DLL
static JSON makeString(std::string const& utf8);
QPDF_DLL
static JSON makeInt(long long int value);
QPDF_DLL
static JSON makeReal(double value);
QPDF_DLL
static JSON makeNumber(std::string const& encoded);
QPDF_DLL
static JSON makeBool(bool value);
QPDF_DLL
static JSON makeNull();
// A blob serializes as a string. The function will be called by JSON with a pipeline and should
// write binary data to the pipeline but not call finish(). JSON will call finish() at the right
// time.
QPDF_DLL
static JSON makeBlob(std::function<void(Pipeline*)>);
QPDF_DLL
bool isArray() const;
QPDF_DLL
bool isDictionary() const;
// Accessors. Accessor behavior:
//
// - If argument is wrong type, including null, return false
// - If argument is right type, return true and initialize the value
QPDF_DLL
bool getString(std::string& utf8) const;
QPDF_DLL
bool getNumber(std::string& value) const;
QPDF_DLL
bool getBool(bool& value) const;
QPDF_DLL
bool isNull() const;
QPDF_DLL
JSON getDictItem(std::string const& key) const;
QPDF_DLL
bool forEachDictItem(std::function<void(std::string const& key, JSON value)> fn) const;
QPDF_DLL
bool forEachArrayItem(std::function<void(JSON value)> fn) const;
// Check this JSON object against a "schema". This is not a schema according to any standard.
// It's just a template of what the JSON is supposed to contain. The checking does the
// following:
//
// * The schema is a nested structure containing dictionaries, single-element arrays, and
// strings only.
// * Recursively walk the schema. In the items below, "schema object" refers to an object in
// the schema, and "checked object" refers to the corresponding part of the object being
// checked.
// * If the schema object is a dictionary, the checked object must have a dictionary in the
// same place with the same keys. If flags contains f_optional, a key in the schema does not
// have to be present in the object. Otherwise, all keys have to be present. Any key in the
// object must be present in the schema.
// * If the schema object is an array of length 1, the checked object may either be a single
// item or an array of items. The single item or each element of the checked object's
// array is validated against the single element of the schema's array. The rationale behind
// this logic is that a single element may appear wherever the schema allows a
// variable-length array. This makes it possible to start allowing an array in the future
// where a single element was previously required without breaking backward compatibility.
// * If the schema object is an array of length > 1, the checked object must be an array of
// the same length. In this case, each element of the checked object array is validated
// against the corresponding element of the schema array.
// * Otherwise, the value must be a string whose value is a description of the object's
// corresponding value, which may have any type.
//
// QPDF's JSON output conforms to certain strict compatibility rules as discussed in the manual.
// The idea is that a JSON structure created manually in qpdf.cc doubles as both JSON help
// information and a schema for validating the JSON that qpdf generates. Any discrepancies are a
// bug in qpdf.
//
// Flags is a bitwise or of values from check_flags_e.
enum check_flags_e {
f_none = 0,
f_optional = 1 << 0,
};
QPDF_DLL
bool checkSchema(JSON schema, unsigned long flags, std::list<std::string>& errors);
// Same as passing 0 for flags
QPDF_DLL
bool checkSchema(JSON schema, std::list<std::string>& errors);
// A pointer to a Reactor class can be passed to parse, which will enable the caller to react
// to incremental events in the construction of the JSON object. This makes it possible to
// implement SAX-like handling of very large JSON objects.
class QPDF_DLL_CLASS Reactor
{
public:
virtual ~Reactor() = default;
// The start/end methods are called when parsing of a dictionary or array is started or
// ended. The item methods are called when an item is added to a dictionary or array. When
// adding a container to another container, the item method is called with an empty
// container before the lower container's start method is called. See important notes in
// "Item methods" below.
// During parsing of a JSON string, the parser is operating on a single object at a time.
// When a dictionary or array is started, a new context begins, and when that dictionary or
// array is ended, the previous context is resumed. So, for
// example, if you have `{"a": [1]}`, you will receive the
// following method calls
//
// dictionaryStart -- current object is the top-level dictionary
// dictionaryItem -- called with "a" and an empty array
// arrayStart -- current object is the array
// arrayItem -- called with the "1" object
// containerEnd -- now current object is the dictionary again
// containerEnd -- current object is undefined
//
// If the top-level item in a JSON string is a scalar, the topLevelScalar() method will be
// called. No argument is passed since the object is the same as what is returned by
// parse().
QPDF_DLL
virtual void dictionaryStart() = 0;
QPDF_DLL
virtual void arrayStart() = 0;
QPDF_DLL
virtual void containerEnd(JSON const& value) = 0;
QPDF_DLL
virtual void topLevelScalar() = 0;
// Item methods:
//
// The return value of the item methods indicate whether the item has been "consumed". If
// the item method returns true, then the item will not be added to the containing JSON
// object. This is what allows arbitrarily large JSON objects
// to be parsed and not have to be kept in memory.
//
// NOTE: When a dictionary or an array is added to a container, the dictionaryItem or
// arrayItem method is called when the child item's start delimiter is encountered, so the
// JSON object passed in at that time will always be in its initial, empty state.
// Additionally, the child item's start method is not called until after the parent item's
// item method is called. This makes it possible to keep track of the current depth level by
// incrementing level on start methods and decrementing on end methods.
QPDF_DLL
virtual bool dictionaryItem(std::string const& key, JSON const& value) = 0;
QPDF_DLL
virtual bool arrayItem(JSON const& value) = 0;
};
// Create a JSON object from a string.
QPDF_DLL
static JSON parse(std::string const&);
// Create a JSON object from an input source. See above for information about how to use the
// Reactor.
QPDF_DLL
static JSON parse(InputSource&, Reactor* reactor = nullptr);
// parse calls setOffsets to set the inclusive start and non-inclusive end offsets of an object
// relative to its input string. Otherwise, both values are 0.
QPDF_DLL
void setStart(qpdf_offset_t);
QPDF_DLL
void setEnd(qpdf_offset_t);
QPDF_DLL
qpdf_offset_t getStart() const;
QPDF_DLL
qpdf_offset_t getEnd() const;
// The following class does not form part of the public API and is for internal use only.
class Writer;
private:
static void writeClose(Pipeline* p, bool first, size_t depth, char const* delimeter);
enum value_type_e {
vt_none,
vt_dictionary,
vt_array,
vt_string,
vt_number,
vt_bool,
vt_null,
vt_blob,
};
struct JSON_value
{
JSON_value(value_type_e type_code) :
type_code(type_code)
{
}
virtual ~JSON_value() = default;
virtual void write(Pipeline*, size_t depth) const = 0;
const value_type_e type_code{vt_none};
};
struct JSON_dictionary: public JSON_value
{
JSON_dictionary() :
JSON_value(vt_dictionary)
{
}
~JSON_dictionary() override = default;
void write(Pipeline*, size_t depth) const override;
std::map<std::string, JSON> members;
};
struct JSON_array;
struct JSON_string: public JSON_value
{
JSON_string(std::string const& utf8);
~JSON_string() override = default;
void write(Pipeline*, size_t depth) const override;
std::string utf8;
};
struct JSON_number: public JSON_value
{
JSON_number(long long val);
JSON_number(double val);
JSON_number(std::string const& val);
~JSON_number() override = default;
void write(Pipeline*, size_t depth) const override;
std::string encoded;
};
struct JSON_bool: public JSON_value
{
JSON_bool(bool val);
~JSON_bool() override = default;
void write(Pipeline*, size_t depth) const override;
bool value;
};
struct JSON_null: public JSON_value
{
JSON_null() :
JSON_value(vt_null)
{
}
~JSON_null() override = default;
void write(Pipeline*, size_t depth) const override;
};
struct JSON_blob: public JSON_value
{
JSON_blob(std::function<void(Pipeline*)> fn);
~JSON_blob() override = default;
void write(Pipeline*, size_t depth) const override;
std::function<void(Pipeline*)> fn;
};
JSON(std::unique_ptr<JSON_value>);
static void checkSchemaInternal(
JSON_value* this_v,
JSON_value* sch_v,
unsigned long flags,
std::list<std::string>& errors,
std::string prefix);
class Members
{
friend class JSON;
public:
~Members() = default;
private:
Members(std::unique_ptr<JSON_value>);
Members(Members const&) = delete;
std::unique_ptr<JSON_value> value;
// start and end are only populated for objects created by parse
qpdf_offset_t start{0};
qpdf_offset_t end{0};
};
std::shared_ptr<Members> m;
};
struct JSON::JSON_array: public JSON_value
{
JSON_array() :
JSON_value(vt_array)
{
}
~JSON_array() override = default;
void write(Pipeline*, size_t depth) const override;
std::vector<JSON> elements;
};
#endif // JSON_HH
@@ -0,0 +1,155 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
#ifndef OBJECTHANDLE_HH
#define OBJECTHANDLE_HH
#include <qpdf/Constants.h>
#include <qpdf/DLL.h>
#include <qpdf/Types.h>
#include <qpdf/JSON.hh>
#include <qpdf/QPDFExc.hh>
#include <qpdf/QPDFObjGen.hh>
#include <cstdint>
#include <memory>
class QPDF;
class QPDF_Dictionary;
class QPDFObject;
class QPDFObjectHandle;
namespace qpdf
{
class Array;
class BaseDictionary;
class Dictionary;
class Integer;
class Stream;
enum typed : std::uint8_t { strict = 0, any_flag = 1, optional = 2, any = 3, error = 4 };
// Basehandle is only used as a base-class for QPDFObjectHandle like classes. Currently the only
// methods exposed in public API are operators to convert derived objects to QPDFObjectHandle,
// QPDFObjGen and bool.
class BaseHandle
{
friend class ::QPDF;
public:
explicit inline operator bool() const;
inline operator QPDFObjectHandle() const;
QPDF_DLL
operator QPDFObjGen() const;
// The rest of the header file is for qpdf internal use only.
// Return true if both object handles refer to the same underlying object.
bool
operator==(BaseHandle const& other) const
{
return obj == other.obj;
}
// For arrays, return the number of items in the array.
// For null-like objects, return 0.
// For all other objects, return 1.
size_t size() const;
// Return 'true' if size() == 0.
bool
empty() const
{
return size() == 0;
}
QPDFObjectHandle operator[](size_t n) const;
QPDFObjectHandle operator[](int n) const;
QPDFObjectHandle& at(std::string const& key) const;
bool contains(std::string const& key) const;
size_t erase(std::string const& key);
QPDFObjectHandle& find(std::string const& key) const;
bool replace(std::string const& key, QPDFObjectHandle value);
QPDFObjectHandle const& operator[](std::string const& key) const;
std::shared_ptr<QPDFObject> copy(bool shallow = false) const;
// Recursively remove association with any QPDF object. This method may only be called
// during final destruction.
void disconnect(bool only_direct = true);
inline QPDFObjGen id_gen() const;
inline bool indirect() const;
inline bool null() const;
inline qpdf_offset_t offset() const;
inline QPDF* qpdf() const;
inline qpdf_object_type_e raw_type_code() const;
inline qpdf_object_type_e resolved_type_code() const;
inline qpdf_object_type_e type_code() const;
std::string unparse() const;
void write_json(int json_version, JSON::Writer& p) const;
static void warn(QPDF*, QPDFExc&&);
void warn(QPDFExc&&) const;
void warn(std::string const& warning) const;
inline std::shared_ptr<QPDFObject> const& obj_sp() const;
inline QPDFObjectHandle oh() const;
protected:
BaseHandle() = default;
BaseHandle(std::shared_ptr<QPDFObject> const& obj) :
obj(obj) {};
BaseHandle(std::shared_ptr<QPDFObject>&& obj) :
obj(std::move(obj)) {};
BaseHandle(BaseHandle const&) = default;
BaseHandle& operator=(BaseHandle const&) = default;
BaseHandle(BaseHandle&&) = default;
BaseHandle& operator=(BaseHandle&&) = default;
inline BaseHandle(QPDFObjectHandle const& oh);
inline BaseHandle(QPDFObjectHandle&& oh);
~BaseHandle() = default;
template <typename T>
T* as() const;
inline void assign(qpdf_object_type_e required, BaseHandle const& other);
inline void assign(qpdf_object_type_e required, BaseHandle&& other);
inline void nullify();
std::string description() const;
inline QPDFObjectHandle const& get(std::string const& key) const;
void no_ci_warn_if(bool condition, std::string const& warning) const;
void no_ci_stop_if(bool condition, std::string const& warning) const;
void no_ci_stop_damaged_if(bool condition, std::string const& warning) const;
std::invalid_argument invalid_error(std::string const& method) const;
std::runtime_error type_error(char const* expected_type) const;
QPDFExc type_error(char const* expected_type, std::string const& message) const;
char const* type_name() const;
std::shared_ptr<QPDFObject> obj;
};
} // namespace qpdf
#endif // QPDFOBJECTHANDLE_HH
@@ -0,0 +1,65 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
#ifndef PDFVERSION_HH
#define PDFVERSION_HH
#include <qpdf/DLL.h>
#include <string>
// Represent a PDF version. PDF versions are typically major.minor, but PDF 1.7 has several
// extension levels as the ISO 32000 spec was in progress. This class helps with comparison of
// versions.
class PDFVersion
{
public:
PDFVersion() = default;
PDFVersion(PDFVersion const&) = default;
PDFVersion& operator=(PDFVersion const&) = default;
QPDF_DLL
PDFVersion(int major, int minor, int extension = 0);
QPDF_DLL
bool operator<(PDFVersion const& rhs) const;
QPDF_DLL
bool operator==(PDFVersion const& rhs) const;
// Replace this version with the other one if the other one is greater.
QPDF_DLL
void updateIfGreater(PDFVersion const& other);
// Initialize a string and integer suitable for passing to QPDFWriter::setMinimumPDFVersion or
// QPDFWriter::forcePDFVersion.
QPDF_DLL
void getVersion(std::string& version, int& extension_level) const;
QPDF_DLL
int getMajor() const;
QPDF_DLL
int getMinor() const;
QPDF_DLL
int getExtensionLevel() const;
private:
int major_version{0};
int minor_version{0};
int extension_level{0};
};
#endif // PDFVERSION_HH
@@ -0,0 +1,115 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
#ifndef PIPELINE_HH
#define PIPELINE_HH
#include <qpdf/DLL.h>
#include <memory>
#include <string>
// Generalized Pipeline interface. By convention, subclasses of Pipeline are called Pl_Something.
//
// When an instance of Pipeline is created with a pointer to a next pipeline, that pipeline writes
// its data to the next one when it finishes with it. In order to make possible a usage style in
// which a pipeline may be passed to a function which may stick other pipelines in front of it, the
// allocator of a pipeline is responsible for its destruction. In other words, one pipeline object
// does not attempt to manage the memory of its successor.
//
// The client is required to call finish() before destroying a Pipeline in order to avoid loss of
// data. A Pipeline class should not throw an exception in the destructor if this hasn't been done
// though since doing so causes too much trouble when deleting pipelines during error conditions.
//
// Some pipelines are reusable (i.e., you can call write() after calling finish() and can call
// finish() multiple times) while others are not. It is up to the caller to use a pipeline
// according to its own restrictions.
//
// Remember to use QPDF_DLL_CLASS on anything derived from Pipeline so it will work with
// dynamic_cast across the shared object boundary.
class QPDF_DLL_CLASS Pipeline
{
public:
QPDF_DLL
Pipeline(char const* identifier, Pipeline* next);
virtual ~Pipeline() = default;
// Subclasses should implement write and finish to do their jobs and then, if they are not
// end-of-line pipelines, call getNext()->write or getNext()->finish.
QPDF_DLL
virtual void write(unsigned char const* data, size_t len) = 0;
QPDF_DLL
virtual void finish() = 0;
QPDF_DLL
std::string getIdentifier() const;
// These are convenience methods for making it easier to write certain other types of data to
// pipelines without having to cast. The methods that take char const* expect null-terminated C
// strings and do not write the null terminators.
QPDF_DLL
void writeCStr(char const* cstr);
QPDF_DLL
void writeString(std::string const&);
// This allows *p << "x" << "y" but is not intended to be a general purpose << compatible with
// ostream and does not have local awareness or the ability to be "imbued" with properties.
QPDF_DLL
Pipeline& operator<<(char const* cstr);
QPDF_DLL
Pipeline& operator<<(std::string const&);
QPDF_DLL
Pipeline& operator<<(short);
QPDF_DLL
Pipeline& operator<<(int);
QPDF_DLL
Pipeline& operator<<(long);
QPDF_DLL
Pipeline& operator<<(long long);
QPDF_DLL
Pipeline& operator<<(unsigned short);
QPDF_DLL
Pipeline& operator<<(unsigned int);
QPDF_DLL
Pipeline& operator<<(unsigned long);
QPDF_DLL
Pipeline& operator<<(unsigned long long);
// Overloaded write to reduce casting
QPDF_DLL
void write(char const* data, size_t len);
protected:
QPDF_DLL
Pipeline* getNext(bool allow_null = false);
Pipeline*
next() const noexcept
{
return next_;
}
std::string identifier;
private:
Pipeline(Pipeline const&) = delete;
Pipeline& operator=(Pipeline const&) = delete;
Pipeline* next_;
};
#endif // PIPELINE_HH
@@ -0,0 +1,76 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
#ifndef PL_BUFFER_HH
#define PL_BUFFER_HH
#include <qpdf/Buffer.hh>
#include <qpdf/Pipeline.hh>
#include <memory>
#include <string>
// This pipeline accumulates the data passed to it into a memory buffer. Each subsequent use of
// this buffer appends to the data accumulated so far. getBuffer() may be called only after calling
// finish() and before calling any subsequent write(). At that point, a dynamically allocated
// Buffer object is returned and the internal buffer is reset. The caller is responsible for
// deleting the returned Buffer.
//
// For this pipeline, "next" may be null. If a next pointer is provided, this pipeline will also
// pass the data through to it.
class QPDF_DLL_CLASS Pl_Buffer: public Pipeline
{
public:
QPDF_DLL
Pl_Buffer(char const* identifier, Pipeline* next = nullptr);
QPDF_DLL
~Pl_Buffer() override;
QPDF_DLL
void write(unsigned char const*, size_t) override;
QPDF_DLL
void finish() override;
// Each call to getBuffer() resets this object -- see notes above.
// The caller is responsible for deleting the returned Buffer object. See also
// getBufferSharedPointer() and getMallocBuffer().
QPDF_DLL
Buffer* getBuffer();
// Same as getBuffer but wraps the result in a shared pointer.
QPDF_DLL
std::shared_ptr<Buffer> getBufferSharedPointer();
// getMallocBuffer behaves in the same was as getBuffer except the buffer is allocated with
// malloc(), making it suitable for use when calling from other languages. If there is no data,
// *buf is set to a null pointer and *len is set to 0. Otherwise, *buf is a buffer of size *len
// allocated with malloc(). It is the caller's responsibility to call free() on the buffer.
QPDF_DLL
void getMallocBuffer(unsigned char** buf, size_t* len);
// Same as getBuffer but returns the result as a string.
QPDF_DLL
std::string getString();
private:
class Members;
std::unique_ptr<Members> m;
};
#endif // PL_BUFFER_HH
@@ -0,0 +1,64 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
#ifndef PL_CONCATENATE_HH
#define PL_CONCATENATE_HH
#include <qpdf/Pipeline.hh>
// This pipeline will drop all regular finish calls rather than passing them onto next. To finish
// downstream streams, call manualFinish. This makes it possible to pipe multiple streams (e.g.
// with QPDFObjectHandle::pipeStreamData) to a downstream like Pl_Flate that can't handle multiple
// calls to finish().
class QPDF_DLL_CLASS Pl_Concatenate: public Pipeline
{
public:
QPDF_DLL
Pl_Concatenate(char const* identifier, Pipeline* next);
QPDF_DLL
~Pl_Concatenate() override;
QPDF_DLL
void write(unsigned char const* data, size_t len) override;
QPDF_DLL
void finish() override;
// At the very end, call manualFinish to actually finish the rest of the pipeline.
QPDF_DLL
void manualFinish();
private:
class QPDF_DLL_PRIVATE Members
{
friend class Pl_Concatenate;
public:
~Members() = default;
private:
Members() = default;
Members(Members const&) = delete;
};
std::unique_ptr<Members> m{nullptr};
};
#endif // PL_CONCATENATE_HH
@@ -0,0 +1,52 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
#ifndef PL_COUNT_HH
#define PL_COUNT_HH
#include <qpdf/Pipeline.hh>
#include <qpdf/Types.h>
// This pipeline is reusable; i.e., it is safe to call write() after calling finish().
class QPDF_DLL_CLASS Pl_Count: public Pipeline
{
public:
QPDF_DLL
Pl_Count(char const* identifier, Pipeline* next);
QPDF_DLL
~Pl_Count() override;
QPDF_DLL
void write(unsigned char const*, size_t) override;
QPDF_DLL
void finish() override;
// Returns the number of bytes written
QPDF_DLL
qpdf_offset_t getCount() const;
// Returns the last character written, or '\0' if no characters have been written (in which case
// getCount() returns 0)
QPDF_DLL
unsigned char getLastChar() const;
private:
class Members;
std::unique_ptr<Members> m;
};
#endif // PL_COUNT_HH
@@ -0,0 +1,101 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
#ifndef PL_DCT_HH
#define PL_DCT_HH
#include <qpdf/Pipeline.hh>
#include <cstddef>
#include <functional>
// jpeglib.h must be included after cstddef or else it messes up the definition of size_t.
#include <jpeglib.h>
class QPDF_DLL_CLASS Pl_DCT: public Pipeline
{
public:
// Constructor for decompressing image data
QPDF_DLL
Pl_DCT(char const* identifier, Pipeline* next);
// Limit the memory used by jpeglib when decompressing data.
// NB This is a static option affecting all Pl_DCT instances.
QPDF_DLL
static void setMemoryLimit(long limit);
// Limit the number of scans used by jpeglib when decompressing progressive jpegs.
// NB This is a static option affecting all Pl_DCT instances.
QPDF_DLL
static void setScanLimit(int limit);
// Treat corrupt data as a runtime error rather than attempting to decompress regardless. This
// is the qpdf default behaviour. To attempt to decompress corrupt data set 'treat_as_error' to
// false.
// NB This is a static option affecting all Pl_DCT instances.
QPDF_DLL
static void setThrowOnCorruptData(bool treat_as_error);
class QPDF_DLL_CLASS CompressConfig
{
public:
QPDF_DLL
CompressConfig() = default;
QPDF_DLL
virtual ~CompressConfig() = default;
virtual void apply(jpeg_compress_struct*) = 0;
};
QPDF_DLL
static std::unique_ptr<CompressConfig>
make_compress_config(std::function<void(jpeg_compress_struct*)>);
// Constructor for compressing image data
QPDF_DLL
Pl_DCT(
char const* identifier,
Pipeline* next,
JDIMENSION image_width,
JDIMENSION image_height,
int components,
J_COLOR_SPACE color_space,
CompressConfig* config_callback = nullptr);
QPDF_DLL
~Pl_DCT() override;
QPDF_DLL
void write(unsigned char const* data, size_t len) override;
QPDF_DLL
void finish() override;
private:
QPDF_DLL_PRIVATE
void compress(void* cinfo);
QPDF_DLL_PRIVATE
void decompress(void* cinfo);
enum action_e { a_compress, a_decompress };
class Members;
std::unique_ptr<Members> m;
};
#endif // PL_DCT_HH
@@ -0,0 +1,41 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
#ifndef PL_DISCARD_HH
#define PL_DISCARD_HH
#include <qpdf/Pipeline.hh>
// This pipeline discards its output. It is an end-of-line pipeline (with no next).
//
// This pipeline is reusable; i.e., it is safe to call write() after calling finish().
class QPDF_DLL_CLASS Pl_Discard: public Pipeline
{
public:
QPDF_DLL
Pl_Discard();
QPDF_DLL
~Pl_Discard() override;
QPDF_DLL
void write(unsigned char const*, size_t) override;
QPDF_DLL
void finish() override;
};
#endif // PL_DISCARD_HH
@@ -0,0 +1,126 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Versions of qpdf prior to version 7 were released under the terms
// of version 2.0 of the Artistic License. At your option, you may
// continue to consider qpdf to be licensed under those terms. Please
// see the manual for additional information.
#ifndef PL_FLATE_HH
#define PL_FLATE_HH
#include <qpdf/Pipeline.hh>
#include <qpdf/QPDFLogger.hh>
#include <functional>
#include <memory>
#include <string>
class QPDF_DLL_CLASS Pl_Flate: public Pipeline
{
public:
static unsigned int const def_bufsize = 65536;
enum action_e { a_inflate, a_deflate };
QPDF_DLL
Pl_Flate(
char const* identifier,
Pipeline* next,
action_e action,
unsigned int out_bufsize = def_bufsize);
QPDF_DLL
~Pl_Flate() override;
// Limit the memory used.
// NB This is a static option affecting all Pl_Flate instances.
QPDF_DLL
static unsigned long long memory_limit();
QPDF_DLL
static void memory_limit(unsigned long long limit);
QPDF_DLL
void write(unsigned char const* data, size_t len) override;
QPDF_DLL
void finish() override;
// Globally set compression level from 1 (fastest, least
// compression) to 9 (slowest, most compression). Use -1 to set
// the default compression level. This is passed directly to zlib.
// This method returns a pointer to the current Pl_Flate object so
// you can create a pipeline with
// Pl_Flate(...)->setCompressionLevel(...)
QPDF_DLL
static void setCompressionLevel(int);
QPDF_DLL
void setWarnCallback(std::function<void(char const*, int)> callback);
// Returns true if qpdf was built with zopfli support.
QPDF_DLL
static bool zopfli_supported();
// Returns true if zopfli is enabled. Zopfli is enabled if QPDF_ZOPFLI is set to a value other
// than "disabled" and zopfli support is compiled in.
QPDF_DLL
static bool zopfli_enabled();
// If zopfli is supported, returns true. Otherwise, check the QPDF_ZOPFLI
// environment variable as follows:
// - "disabled" or "silent": return true
// - "force": qpdf_exit_error, throw an exception
// - Any other value: issue a warning, and return false
QPDF_DLL
static bool zopfli_check_env(QPDFLogger* logger = nullptr);
private:
QPDF_DLL_PRIVATE
void handleData(unsigned char const* data, size_t len, int flush);
QPDF_DLL_PRIVATE
void checkError(char const* prefix, int error_code);
QPDF_DLL_PRIVATE
void warn(char const*, int error_code);
QPDF_DLL_PRIVATE
void finish_zopfli();
QPDF_DLL_PRIVATE
static int compression_level;
class QPDF_DLL_PRIVATE Members
{
friend class Pl_Flate;
public:
Members(size_t out_bufsize, action_e action);
~Members();
private:
Members(Members const&) = delete;
std::shared_ptr<unsigned char> outbuf;
size_t out_bufsize;
action_e action;
bool initialized;
void* zdata;
unsigned long long written{0};
std::function<void(char const*, int)> callback;
std::unique_ptr<std::string> zopfli_buf;
};
std::unique_ptr<Members> m;
};
#endif // PL_FLATE_HH
@@ -0,0 +1,70 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
#ifndef PL_FUNCTION_HH
#define PL_FUNCTION_HH
#include <qpdf/Pipeline.hh>
#include <functional>
// This pipeline calls an arbitrary function with whatever data is passed to it. This pipeline can
// be reused.
//
// For this pipeline, "next" may be null. If a next pointer is provided, this pipeline will also
// pass the data through to it and will forward finish() to it.
//
// It is okay to not call finish() on this pipeline if it has no "next".
//
// It is okay to keep calling write() after a previous write throws an exception as long as the
// delegated function allows it.
class QPDF_DLL_CLASS Pl_Function: public Pipeline
{
public:
typedef std::function<void(unsigned char const*, size_t)> writer_t;
// The supplied function is called every time write is called.
QPDF_DLL
Pl_Function(char const* identifier, Pipeline* next, writer_t fn);
// The supplied C-style function is called every time write is called. The udata option is
// passed into the function with each call. If the function returns a non-zero value, a runtime
// error is thrown.
typedef int (*writer_c_t)(unsigned char const*, size_t, void*);
QPDF_DLL
Pl_Function(char const* identifier, Pipeline* next, writer_c_t fn, void* udata);
typedef int (*writer_c_char_t)(char const*, size_t, void*);
QPDF_DLL
Pl_Function(char const* identifier, Pipeline* next, writer_c_char_t fn, void* udata);
QPDF_DLL
~Pl_Function() override;
QPDF_DLL
void write(unsigned char const* buf, size_t len) override;
QPDF_DLL
void finish() override;
private:
class Members;
std::unique_ptr<Members> m;
};
#endif // PL_FUNCTION_HH
@@ -0,0 +1,50 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
#ifndef PL_OSTREAM_HH
#define PL_OSTREAM_HH
#include <qpdf/Pipeline.hh>
#include <iostream>
// End-of-line pipeline that simply writes its data to a stdio FILE* object.
//
// This pipeline is reusable.
class QPDF_DLL_CLASS Pl_OStream: public Pipeline
{
public:
// os is externally maintained; this class just writes to and flushes it. It does not close it.
QPDF_DLL
Pl_OStream(char const* identifier, std::ostream& os);
QPDF_DLL
~Pl_OStream() override;
QPDF_DLL
void write(unsigned char const* buf, size_t len) override;
QPDF_DLL
void finish() override;
private:
class Members;
std::unique_ptr<Members> m;
};
#endif // PL_OSTREAM_HH
@@ -0,0 +1,59 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
#ifndef PL_QPDFTOKENIZER_HH
#define PL_QPDFTOKENIZER_HH
#include <qpdf/Pipeline.hh>
#include <qpdf/Pl_Buffer.hh>
#include <qpdf/QPDFObjectHandle.hh>
#include <qpdf/QPDFTokenizer.hh>
#include <memory>
// Tokenize the incoming text using QPDFTokenizer and pass the tokens in turn to a
// QPDFObjectHandle::TokenFilter object. All bytes of incoming content will be included in exactly
// one token and passed downstream.
//
// This is a very low-level interface for working with token filters. Most code will want to use
// QPDFObjectHandle::filterPageContents or QPDFObjectHandle::addTokenFilter. See QPDFObjectHandle.hh
// for details.
class QPDF_DLL_CLASS Pl_QPDFTokenizer: public Pipeline
{
public:
// Whatever pipeline is provided as "next" will be set as the pipeline that the token filter
// writes to. If next is not provided, any output written by the filter will be discarded.
QPDF_DLL
Pl_QPDFTokenizer(
char const* identifier, QPDFObjectHandle::TokenFilter* filter, Pipeline* next = nullptr);
QPDF_DLL
~Pl_QPDFTokenizer() override;
QPDF_DLL
void write(unsigned char const* buf, size_t len) override;
QPDF_DLL
void finish() override;
private:
class Members;
std::unique_ptr<Members> m;
};
#endif // PL_QPDFTOKENIZER_HH
@@ -0,0 +1,60 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
#ifndef PL_RUNLENGTH_HH
#define PL_RUNLENGTH_HH
#include <qpdf/Pipeline.hh>
class QPDF_DLL_CLASS Pl_RunLength: public Pipeline
{
public:
enum action_e { a_encode, a_decode };
QPDF_DLL
Pl_RunLength(char const* identifier, Pipeline* next, action_e action);
QPDF_DLL
~Pl_RunLength() override;
// Limit the memory used.
// NB This is a static option affecting all Pl_RunLength instances.
QPDF_DLL
static void setMemoryLimit(unsigned long long limit);
QPDF_DLL
void write(unsigned char const* data, size_t len) override;
QPDF_DLL
void finish() override;
private:
QPDF_DLL_PRIVATE
void encode(unsigned char const* data, size_t len);
QPDF_DLL_PRIVATE
void decode(unsigned char const* data, size_t len);
QPDF_DLL_PRIVATE
void flush_encode();
enum state_e { st_top, st_copying, st_run };
class Members;
std::unique_ptr<Members> m;
};
#endif // PL_RUNLENGTH_HH
@@ -0,0 +1,51 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
// End-of-line pipeline that simply writes its data to a stdio FILE* object.
#ifndef PL_STDIOFILE_HH
#define PL_STDIOFILE_HH
#include <qpdf/Pipeline.hh>
#include <cstdio>
//
// This pipeline is reusable.
//
class QPDF_DLL_CLASS Pl_StdioFile: public Pipeline
{
public:
// f is externally maintained; this class just writes to and flushes it. It does not close it.
QPDF_DLL
Pl_StdioFile(char const* identifier, FILE* f);
QPDF_DLL
~Pl_StdioFile() override;
QPDF_DLL
void write(unsigned char const* buf, size_t len) override;
QPDF_DLL
void finish() override;
private:
class Members;
std::unique_ptr<Members> m;
};
#endif // PL_STDIOFILE_HH
@@ -0,0 +1,57 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
#ifndef PL_STRING_HH
#define PL_STRING_HH
#include <qpdf/Pipeline.hh>
#include <string>
// This pipeline accumulates the data passed to it into a std::string, a reference to which is
// passed in at construction. Each subsequent use of this pipeline appends to the data accumulated
// so far.
//
// For this pipeline, "next" may be null. If a next pointer is provided, this pipeline will also
// pass the data through to it and will forward finish() to it.
//
// It is okay to not call finish() on this pipeline if it has no "next". This makes it easy to stick
// this in front of another pipeline to capture data that is written to the other pipeline without
// interfering with when finish is called on the other pipeline and without having to put a
// Pl_Concatenate after it.
class QPDF_DLL_CLASS Pl_String: public Pipeline
{
public:
QPDF_DLL
Pl_String(char const* identifier, Pipeline* next, std::string& s);
QPDF_DLL
~Pl_String() override;
QPDF_DLL
void write(unsigned char const* buf, size_t len) override;
QPDF_DLL
void finish() override;
private:
class Members;
std::unique_ptr<Members> m;
};
#endif // PL_STRING_HH
@@ -0,0 +1,245 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Versions of qpdf prior to version 7 were released under the terms
// of version 2.0 of the Artistic License. At your option, you may
// continue to consider qpdf to be licensed under those terms. Please
// see the manual for additional information.
#ifndef POINTERHOLDER_HH
#define POINTERHOLDER_HH
#define POINTERHOLDER_IS_SHARED_POINTER
#ifndef POINTERHOLDER_TRANSITION
// 0 = no deprecation warnings, backward-compatible API
// 1 = make PointerHolder<T>(T*) explicit
// 2 = warn for use of getPointer() and getRefcount()
// 3 = warn for all use of PointerHolder
// 4 = don't define PointerHolder at all
# define POINTERHOLDER_TRANSITION 4
#endif // !defined(POINTERHOLDER_TRANSITION)
#if POINTERHOLDER_TRANSITION < 4
// *** WHAT IS HAPPENING ***
// In qpdf 11, PointerHolder was replaced with std::shared_ptr
// wherever it appeared in the qpdf API. The PointerHolder object is
// now derived from std::shared_ptr to provide a backward-compatible
// interface and is mutually assignable with std::shared_ptr. Code
// that uses containers of PointerHolder will require adjustment.
// In qpdf 11, a backward-compatible PointerHolder was provided with a
// warning if POINTERHOLDER_TRANSITION was not defined. Starting in
// qpdf 12, PointerHolder is absent if POINTERHOLDER_TRANSITION is not
// defined. In a future version of qpdf, PointerHolder will be removed
// outright if it becomes inconvenient to keep it around.
// *** HOW TO TRANSITION ***
// The symbol POINTERHOLDER_TRANSITION can be defined to help you
// transition your code away from PointerHolder. You can define it
// before including any qpdf header files or including its definition
// in your build configuration. If not defined, it automatically gets
// defined to 4, which excludes PointerHolder entirely.
// If you want to work gradually to transition your code away from
// PointerHolder, you can define POINTERHOLDER_TRANSITION and fix the
// code so it compiles without warnings and works correctly. If you
// want to be able to continue to support old qpdf versions at the
// same time, you can write code like this:
// #ifndef POINTERHOLDER_IS_SHARED_POINTER
// ... use PointerHolder as before 10.6
// #else
// ... use PointerHolder or shared_ptr as needed
// #endif
// Each level of POINTERHOLDER_TRANSITION exposes differences between
// PointerHolder and std::shared_ptr. The easiest way to transition is
// to increase POINTERHOLDER_TRANSITION in steps of 1 so that you can
// test and handle changes incrementally.
// POINTERHOLDER_TRANSITION = 1
//
// PointerHolder<T> has an implicit constructor that takes a T*, so
// you can replace a PointerHolder<T>'s pointer by directly assigning
// a T* to it or pass a T* to a function that expects a
// PointerHolder<T>. std::shared_ptr does not have this (risky)
// behavior. When POINTERHOLDER_TRANSITION = 1, PointerHolder<T>'s T*
// constructor is declared explicit. For compatibility with
// std::shared_ptr, you can still assign nullptr to a PointerHolder.
// Constructing all your PointerHolder<T> instances explicitly is
// backward compatible, so you can make this change without
// conditional compilation and still use the changes with older qpdf
// versions.
//
// Also defined is a make_pointer_holder method that acts like
// std::make_shared. You can use this as well, but it is not
// compatible with qpdf prior to 10.6 and not necessary with qpdf
// newer than 10.6.3. Like std::make_shared<T>, make_pointer_holder<T>
// can only be used when the constructor implied by its arguments is
// public. If you previously used this, you can replace it width
// std::make_shared now.
// POINTERHOLDER_TRANSITION = 2
//
// std::shared_ptr has get() and use_count(). PointerHolder has
// getPointer() and getRefcount(). In 10.6.0, get() and use_count()
// were added as well. When POINTERHOLDER_TRANSITION = 2, getPointer()
// and getRefcount() are deprecated. Fix deprecation warnings by
// replacing with get() and use_count(). This breaks compatibility
// with qpdf older than 10.6. Search for CONST BEHAVIOR for an
// additional note.
//
// Once your code is clean at POINTERHOLDER_TRANSITION = 2, the only
// remaining issues that prevent simple replacement of PointerHolder
// with std::shared_ptr are shared arrays and containers, and neither
// of these are used in the qpdf API.
// POINTERHOLDER_TRANSITION = 3
//
// Warn for all use of PointerHolder<T>. This helps you remove all use
// of PointerHolder from your code and use std::shared_ptr instead.
// You will also have to transition any containers of PointerHolder in
// your code.
// POINTERHOLDER_TRANSITION = 4
//
// Suppress definition of the PointerHolder<T> type entirely. This is
// the default behavior starting with qpdf 12.
// CONST BEHAVIOR
// PointerHolder<T> has had a long-standing bug in its const behavior.
// const PointerHolder<T>'s getPointer() method returns a T const*.
// This is incorrect and is not how regular pointers or standard
// library smart pointers behave. Making a PointerHolder<T> const
// should prevent reassignment of its pointer but not affect the thing
// it points to. For that, use PointerHolder<T const>. The new get()
// method behaves correctly in this respect and is therefore slightly
// different from getPointer(). This shouldn't break any correctly
// written code. If you are relying on the incorrect behavior, use
// PointerHolder<T const> instead.
# include <cstddef>
# include <memory>
template <class T>
class PointerHolder: public std::shared_ptr<T>
{
public:
# if POINTERHOLDER_TRANSITION >= 3
[[deprecated("use std::shared_ptr<T> instead")]]
# endif // POINTERHOLDER_TRANSITION >= 3
PointerHolder(std::shared_ptr<T> other) :
std::shared_ptr<T>(other)
{
}
# if POINTERHOLDER_TRANSITION >= 3
[[deprecated("use std::shared_ptr<T> instead")]]
# if POINTERHOLDER_TRANSITION >= 1
explicit
# endif // POINTERHOLDER_TRANSITION >= 1
# endif // POINTERHOLDER_TRANSITION >= 3
PointerHolder(T* pointer = 0) :
std::shared_ptr<T>(pointer)
{
}
// Create a shared pointer to an array
# if POINTERHOLDER_TRANSITION >= 3
[[deprecated("use std::shared_ptr<T> instead")]]
# endif // POINTERHOLDER_TRANSITION >= 3
PointerHolder(bool, T* pointer) :
std::shared_ptr<T>(pointer, std::default_delete<T[]>())
{
}
virtual ~PointerHolder() = default;
# if POINTERHOLDER_TRANSITION >= 2
[[deprecated("use PointerHolder<T>::get() instead of getPointer()")]]
# endif // POINTERHOLDER_TRANSITION >= 2
T*
getPointer()
{
return this->get();
}
# if POINTERHOLDER_TRANSITION >= 2
[[deprecated("use PointerHolder<T>::get() instead of getPointer()")]]
# endif // POINTERHOLDER_TRANSITION >= 2
T const*
getPointer() const
{
return this->get();
}
# if POINTERHOLDER_TRANSITION >= 2
[[deprecated("use PointerHolder<T>::get() instead of getPointer()")]]
# endif // POINTERHOLDER_TRANSITION >= 2
int
getRefcount() const
{
return static_cast<int>(this->use_count());
}
PointerHolder&
operator=(decltype(nullptr))
{
std::shared_ptr<T>::operator=(nullptr);
return *this;
}
T const&
operator*() const
{
return *(this->get());
}
T&
operator*()
{
return *(this->get());
}
T const*
operator->() const
{
return this->get();
}
T*
operator->()
{
return this->get();
}
};
template <typename T, typename... _Args>
inline PointerHolder<T>
make_pointer_holder(_Args&&... __args)
{
return PointerHolder<T>(new T(__args...));
}
template <typename T>
PointerHolder<T>
make_array_pointer_holder(size_t n)
{
return PointerHolder<T>(true, new T[n]);
}
#endif // POINTERHOLDER_TRANSITION < 4
#endif // POINTERHOLDER_HH
@@ -0,0 +1,310 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Versions of qpdf prior to version 7 were released under the terms
// of version 2.0 of the Artistic License. At your option, you may
// continue to consider qpdf to be licensed under those terms. Please
// see the manual for additional information.
#ifndef QINTC_HH
#define QINTC_HH
#include <qpdf/DLL.h>
#include <qpdf/Types.h>
#include <iostream>
#include <limits>
#include <locale>
#include <sstream>
#include <stdexcept>
#include <type_traits>
// This namespace provides safe integer conversion that detects
// overflows. It uses short, cryptic names for brevity.
namespace QIntC // QIntC = qpdf Integer Conversion
{
// to_u is here for backward-compatibility from before we required
// C++-11.
template <typename T>
class to_u
{
public:
typedef typename std::make_unsigned<T>::type type;
};
// Basic IntConverter class, which converts an integer from the
// From class to one of the To class if it can be done safely and
// throws a range_error otherwise. This class is specialized for
// each permutation of signed/unsigned for the From and To
// classes.
template <
typename From,
typename To,
bool From_signed = std::numeric_limits<From>::is_signed,
bool To_signed = std::numeric_limits<To>::is_signed>
class IntConverter
{
};
template <typename From, typename To>
class IntConverter<From, To, false, false>
{
public:
inline static To
convert(From const& i)
{
// From and To are both unsigned.
if (i > std::numeric_limits<To>::max()) {
error(i);
}
return static_cast<To>(i);
}
static void
error(From i)
{
std::ostringstream msg;
msg.imbue(std::locale::classic());
msg << "integer out of range converting " << i << " from a " << sizeof(From)
<< "-byte unsigned type to a " << sizeof(To) << "-byte unsigned type";
throw std::range_error(msg.str());
}
};
template <typename From, typename To>
class IntConverter<From, To, true, true>
{
public:
inline static To
convert(From const& i)
{
// From and To are both signed.
if ((i < std::numeric_limits<To>::min()) || (i > std::numeric_limits<To>::max())) {
error(i);
}
return static_cast<To>(i);
}
static void
error(From i)
{
std::ostringstream msg;
msg.imbue(std::locale::classic());
msg << "integer out of range converting " << i << " from a " << sizeof(From)
<< "-byte signed type to a " << sizeof(To) << "-byte signed type";
throw std::range_error(msg.str());
}
};
template <typename From, typename To>
class IntConverter<From, To, true, false>
{
public:
inline static To
convert(From const& i)
{
// From is signed, and To is unsigned. If i > 0, it's safe to
// convert it to the corresponding unsigned type and to
// compare with To's max.
auto ii = static_cast<typename to_u<From>::type>(i);
if ((i < 0) || (ii > std::numeric_limits<To>::max())) {
error(i);
}
return static_cast<To>(i);
}
static void
error(From i)
{
std::ostringstream msg;
msg.imbue(std::locale::classic());
msg << "integer out of range converting " << i << " from a " << sizeof(From)
<< "-byte signed type to a " << sizeof(To) << "-byte unsigned type";
throw std::range_error(msg.str());
}
};
template <typename From, typename To>
class IntConverter<From, To, false, true>
{
public:
inline static To
convert(From const& i)
{
// From is unsigned, and to is signed. Convert To's max to the
// unsigned version of To and compare i against that.
auto maxval = static_cast<typename to_u<To>::type>(std::numeric_limits<To>::max());
if (i > maxval) {
error(i);
}
return static_cast<To>(i);
}
static void
error(From i)
{
std::ostringstream msg;
msg.imbue(std::locale::classic());
msg << "integer out of range converting " << i << " from a " << sizeof(From)
<< "-byte unsigned type to a " << sizeof(To) << "-byte signed type";
throw std::range_error(msg.str());
}
};
// Specific converters. The return type of each function must match
// the second template parameter to IntConverter.
template <typename T>
inline char
to_char(T const& i)
{
return IntConverter<T, char>::convert(i);
}
template <typename T>
inline unsigned char
to_uchar(T const& i)
{
return IntConverter<T, unsigned char>::convert(i);
}
template <typename T>
inline short
to_short(T const& i)
{
return IntConverter<T, short>::convert(i);
}
template <typename T>
inline unsigned short
to_ushort(T const& i)
{
return IntConverter<T, unsigned short>::convert(i);
}
template <typename T>
inline int
to_int(T const& i)
{
return IntConverter<T, int>::convert(i);
}
template <typename T>
inline unsigned int
to_uint(T const& i)
{
return IntConverter<T, unsigned int>::convert(i);
}
template <typename T>
inline size_t
to_size(T const& i)
{
return IntConverter<T, size_t>::convert(i);
}
template <typename T>
inline qpdf_offset_t
to_offset(T const& i)
{
return IntConverter<T, qpdf_offset_t>::convert(i);
}
template <typename T>
inline long
to_long(T const& i)
{
return IntConverter<T, long>::convert(i);
}
template <typename T>
inline unsigned long
to_ulong(T const& i)
{
return IntConverter<T, unsigned long>::convert(i);
}
template <typename T>
inline long long
to_longlong(T const& i)
{
return IntConverter<T, long long>::convert(i);
}
template <typename T>
inline unsigned long long
to_ulonglong(T const& i)
{
return IntConverter<T, unsigned long long>::convert(i);
}
template <typename T>
void
range_check_error(T const& cur, T const& delta)
{
if ((delta > 0) && ((std::numeric_limits<T>::max() - cur) < delta)) {
std::ostringstream msg;
msg.imbue(std::locale::classic());
msg << "adding " << delta << " to " << cur << " would cause an integer overflow";
throw std::range_error(msg.str());
} else if ((delta < 0) && ((std::numeric_limits<T>::min() - cur) > delta)) {
std::ostringstream msg;
msg.imbue(std::locale::classic());
msg << "adding " << delta << " to " << cur << " would cause an integer underflow";
throw std::range_error(msg.str());
}
}
template <typename T>
inline void
range_check(T const& cur, T const& delta)
{
if ((delta > 0) != (cur > 0)) {
return;
}
QIntC::range_check_error<T>(cur, delta);
}
template <typename T>
void
range_check_subtract_error(T const& cur, T const& delta)
{
if ((delta > 0) && ((std::numeric_limits<T>::min() + delta) > cur)) {
std::ostringstream msg;
msg.imbue(std::locale::classic());
msg << "subtracting " << delta << " from " << cur
<< " would cause an integer underflow";
throw std::range_error(msg.str());
} else if ((delta < 0) && ((std::numeric_limits<T>::max() + delta) < cur)) {
std::ostringstream msg;
msg.imbue(std::locale::classic());
msg << "subtracting " << delta << " from " << cur << " would cause an integer overflow";
throw std::range_error(msg.str());
}
}
template <typename T>
inline void
range_check_subtract(T const& cur, T const& delta)
{
if ((delta >= 0) == (cur >= 0)) {
return;
}
QIntC::range_check_subtract_error<T>(cur, delta);
}
}; // namespace QIntC
#endif // QINTC_HH
@@ -0,0 +1,804 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
#ifndef QPDF_HH
#define QPDF_HH
#include <qpdf/DLL.h>
#include <qpdf/Types.h>
#include <bitset>
#include <cstdio>
#include <functional>
#include <iostream>
#include <list>
#include <map>
#include <memory>
#include <string>
#include <string_view>
#include <vector>
#include <qpdf/Buffer.hh>
#include <qpdf/InputSource.hh>
#include <qpdf/PDFVersion.hh>
#include <qpdf/QPDFExc.hh>
#include <qpdf/QPDFObjGen.hh>
#include <qpdf/QPDFObjectHandle.hh>
#include <qpdf/QPDFStreamFilter.hh>
#include <qpdf/QPDFTokenizer.hh>
#include <qpdf/QPDFWriter.hh>
#include <qpdf/QPDFXRefEntry.hh>
class QPDFLogger;
class QPDF
{
public:
// Get the current version of the QPDF software. See also qpdf/DLL.h
QPDF_DLL
static std::string const& QPDFVersion();
QPDF_DLL
QPDF();
QPDF_DLL
~QPDF();
QPDF_DLL
static std::shared_ptr<QPDF> create();
// Associate a file with a QPDF object and do initial parsing of the file. PDF objects are not
// read until they are needed. A QPDF object may be associated with only one file in its
// lifetime. This method must be called before any methods that potentially ask for information
// about the PDF file are called. Prior to calling this, the only methods that are allowed are
// those that set parameters. If the input file is not encrypted, either a null password or an
// empty password can be used. If the file is encrypted, either the user password or the owner
// password may be supplied. The method setPasswordIsHexKey may be called prior to calling this
// method or any of the other process methods to force the password to be interpreted as a raw
// encryption key. See comments on setPasswordIsHexKey for more information.
QPDF_DLL
void processFile(char const* filename, char const* password = nullptr);
// Parse a PDF from a stdio FILE*. The FILE must be open in binary mode and must be seekable.
// It may be open read only. This works exactly like processFile except that the PDF file is
// read from an already opened FILE*. If close_file is true, the file will be closed at the
// end. Otherwise, the caller is responsible for closing the file.
QPDF_DLL
void processFile(
char const* description, FILE* file, bool close_file, char const* password = nullptr);
// Parse a PDF file loaded into a memory buffer. This works exactly like processFile except
// that the PDF file is in memory instead of on disk. The description appears in any warning or
// error message in place of the file name. The buffer is owned by the caller and must remain
// valid for the lifetime of the QPDF object.
QPDF_DLL
void processMemoryFile(
char const* description, char const* buf, size_t length, char const* password = nullptr);
// Parse a PDF file loaded from a custom InputSource. If you have your own method of retrieving
// a PDF file, you can subclass InputSource and use this method.
QPDF_DLL
void processInputSource(std::shared_ptr<InputSource>, char const* password = nullptr);
// Create a PDF from an input source that contains JSON as written by writeJSON (or qpdf
// --json-output, version 2 or higher). The JSON must be a complete representation of a PDF. See
// "qpdf JSON" in the manual for details. The input JSON may be arbitrarily large. QPDF does not
// load stream data into memory for more than one stream at a time, even if the stream data is
// specified inline.
QPDF_DLL
void createFromJSON(std::string const& json_file);
QPDF_DLL
void createFromJSON(std::shared_ptr<InputSource>);
// Update a PDF from an input source that contains JSON in the same format as is written by
// writeJSON (or qpdf --json-output, version 2 or higher). Objects in the PDF and not in the
// JSON are not modified. See "qpdf JSON" in the manual for details. As with createFromJSON, the
// input JSON may be arbitrarily large.
QPDF_DLL
void updateFromJSON(std::string const& json_file);
QPDF_DLL
void updateFromJSON(std::shared_ptr<InputSource>);
// Write qpdf JSON format to the pipeline "p". The only supported version is 2. The finish()
// method is not called on the pipeline.
//
// The decode_level parameter controls which streams are uncompressed in the JSON. Use
// qpdf_dl_none to preserve all stream data exactly as it appears in the input. The possible
// values for json_stream_data can be found in qpdf/Constants.h and correspond to the
// --json-stream-data command-line argument. If json_stream_data is qpdf_sj_file, file_prefix
// must be specified. Each stream will be written to a file whose path is constructed by
// appending "-nnn" to file_prefix, where "nnn" is the object number (not zero-filled). If
// wanted_objects is empty, write all objects. Otherwise, write only objects whose keys are in
// wanted_objects. Keys may be either "trailer" or of the form "obj:n n R". Invalid keys are
// ignored. This corresponds to the --json-object command-line argument.
//
// QPDF is efficient with regard to memory when writing, allowing you to write arbitrarily large
// PDF files to a pipeline. You can use a pipeline like Pl_Buffer or Pl_String to capture the
// JSON output in memory, but do so with caution as this will allocate enough memory to hold the
// entire PDF file.
QPDF_DLL
void writeJSON(
int version,
Pipeline* p,
qpdf_stream_decode_level_e decode_level,
qpdf_json_stream_data_e json_stream_data,
std::string const& file_prefix,
std::set<std::string> wanted_objects);
// This version of writeJSON enables writing only the "qpdf" key of an in-progress dictionary.
// If the value of "complete" is true, a complete JSON object containing only the "qpdf" key is
// written to the pipeline. If the value of "complete" is false, the "qpdf" key and its value
// are written to the pipeline assuming that a dictionary is already open. The parameter
// first_key indicates whether this is the first key in an in-progress dictionary. It will be
// set to false by writeJSON. The "qpdf" key and value are written as if at depth 1 in a
// prettified JSON output. Remaining arguments are the same as the above version.
QPDF_DLL
void writeJSON(
int version,
Pipeline* p,
bool complete,
bool& first_key,
qpdf_stream_decode_level_e decode_level,
qpdf_json_stream_data_e json_stream_data,
std::string const& file_prefix,
std::set<std::string> wanted_objects);
// Close or otherwise release the input source. Once this has been called, no other methods of
// qpdf can be called safely except for getWarnings and anyWarnings(). After this has been
// called, it is safe to perform operations on the input file such as deleting or renaming it.
QPDF_DLL
void closeInputSource();
// For certain forensic or investigatory purposes, it may sometimes be useful to specify the
// encryption key directly, even though regular PDF applications do not provide a way to do
// this. Calling setPasswordIsHexKey(true) before calling any of the process methods will bypass
// the normal encryption key computation or recovery mechanisms and interpret the bytes in the
// password as a hex-encoded encryption key. Note that we hex-encode the key because it may
// contain null bytes and therefore can't be represented in a char const*.
QPDF_DLL
void setPasswordIsHexKey(bool);
// Create a QPDF object for an empty PDF. This PDF has no pages or objects other than a minimal
// trailer, a document catalog, and a /Pages tree containing zero pages. Pages and other
// objects can be added to the file in the normal way, and the trailer and document catalog can
// be mutated. Calling this method is equivalent to calling processFile on an equivalent PDF
// file. See the pdf-create.cc example for a demonstration of how to use this method to create
// a PDF file from scratch.
QPDF_DLL
void emptyPDF();
// From 10.1: register a new filter implementation for a specific stream filter. You can add
// your own implementations for new filter types or override existing ones provided by the
// library. Registered stream filters are used for decoding only as you can override encoding
// with stream data providers. For example, you could use this method to add support for one of
// the other filter types by using additional third-party libraries that qpdf does not presently
// use. The standard filters are implemented using QPDFStreamFilter classes.
QPDF_DLL
static void registerStreamFilter(
std::string const& filter_name, std::function<std::shared_ptr<QPDFStreamFilter>()> factory);
// Parameter settings
// To capture or redirect output, configure the logger returned by getLogger(). By default, all
// QPDF and QPDFJob objects share the global logger. If you need a private logger for some
// reason, pass a new one to setLogger(). See comments in QPDFLogger.hh for details on
// configuring the logger.
//
// Note that no normal QPDF operations generate output to standard output, so for applications
// that just wish to avoid creating output for warnings and don't call any check functions,
// calling setSuppressWarnings(true) is sufficient.
QPDF_DLL
std::shared_ptr<QPDFLogger> getLogger();
QPDF_DLL
void setLogger(std::shared_ptr<QPDFLogger>);
// This deprecated method is the old way to capture output, but it didn't capture all output.
// See comments above for getLogger and setLogger. This will be removed in QPDF 12. For now, it
// configures a private logger, separating this object from the default logger, and calls
// setOutputStreams on that logger. See QPDFLogger.hh for additional details.
[[deprecated("configure logger from getLogger() or call setLogger()")]] QPDF_DLL void
setOutputStreams(std::ostream* out_stream, std::ostream* err_stream);
// If true, ignore any cross-reference streams in a hybrid file (one that contains both
// cross-reference streams and cross-reference tables). This can be useful for testing to
// ensure that a hybrid file would work with an older reader.
QPDF_DLL
void setIgnoreXRefStreams(bool);
// By default, any warnings are issued to std::cerr or the error stream specified in a call to
// setOutputStreams as they are encountered. If this method is called with a true value,
// reporting of warnings is suppressed. You may still retrieve warnings by calling getWarnings.
QPDF_DLL
void setSuppressWarnings(bool);
// Set the maximum number of warnings. A QPDFExc is thrown if the limit is exceeded.
QPDF_DLL
void setMaxWarnings(size_t);
// By default, QPDF will try to recover if it finds certain types of errors in PDF files. If
// turned off, it will throw an exception on the first such problem it finds without attempting
// recovery.
QPDF_DLL
void setAttemptRecovery(bool);
// Tell other QPDF objects that streams copied from this QPDF need to be fully copied when
// copyForeignObject is called on them. Calling setIgnoreXRefStreams(true) on a QPDF object
// makes it possible for the object and its input source to disappear before streams copied from
// it are written with the destination QPDF object. Confused? Ordinarily, if you are going to
// copy objects from a source QPDF object to a destination QPDF object using copyForeignObject
// or addPage, the source object's input source must stick around until after the destination
// PDF is written. If you call this method on the source QPDF object, it sends a signal to the
// destination object that it must fully copy the stream data when copyForeignObject. It will do
// this by making a copy in RAM. Ordinarily the stream data is copied lazily to avoid
// unnecessary duplication of the stream data. Note that the stream data is copied into RAM only
// once regardless of how many objects the stream is copied into. The result is that, if you
// called setImmediateCopyFrom(true) on a given QPDF object prior to copying any of its streams,
// you do not need to keep it or its input source around after copying its objects to another
// QPDF. This is true even if the source streams use StreamDataProvider. Note that this method
// is called on the QPDF object you are copying FROM, not the one you are copying to. The
// reasoning for this is that there's no reason a given QPDF may not get objects copied to it
// from a variety of other objects, some transient and some not. Since what's relevant is
// whether the source QPDF is transient, the method must be called on the source QPDF, not the
// destination one. This method will make a copy of the stream in RAM, so be sure you have
// enough memory to simultaneously hold all the streams you're copying.
QPDF_DLL
void setImmediateCopyFrom(bool);
// Other public methods
// Return the list of warnings that have been issued so far and clear the list. This method may
// be called even if processFile throws an exception. Note that if setSuppressWarnings was not
// called or was called with a false value, any warnings retrieved here will have already been
// output.
QPDF_DLL
std::vector<QPDFExc> getWarnings();
// Indicate whether any warnings have been issued so far. Does not clear the list of warnings.
QPDF_DLL
bool anyWarnings() const;
// Indicate the number of warnings that have been issued since the last call to getWarnings.
// Does not clear the list of warnings.
QPDF_DLL
size_t numWarnings() const;
// Return an application-scoped unique ID for this QPDF object. This is not a globally unique
// ID. It is constructed using a timestamp and a random number and is intended to be unique
// among QPDF objects that are created by a single run of an application. While it's very likely
// that these are actually globally unique, it is not recommended to use them for long-term
// purposes.
QPDF_DLL
unsigned long long getUniqueId() const;
// Issue a warning on behalf of this QPDF object. It will be emitted with other warnings,
// following warning suppression rules, and it will be available with getWarnings().
QPDF_DLL
void warn(QPDFExc const& e);
// Same as above but creates the QPDFExc object using the arguments passed to warn. The filename
// argument to QPDFExc is omitted. This method uses the filename associated with the QPDF
// object.
QPDF_DLL
void warn(
qpdf_error_code_e error_code,
std::string const& object,
qpdf_offset_t offset,
std::string const& message);
// Return the filename associated with the QPDF object.
QPDF_DLL
std::string getFilename() const;
// Return PDF Version and extension level together as a PDFVersion object
QPDF_DLL
PDFVersion getVersionAsPDFVersion();
// Return just the PDF version from the file
QPDF_DLL
std::string getPDFVersion() const;
QPDF_DLL
int getExtensionLevel();
QPDF_DLL
QPDFObjectHandle getTrailer();
QPDF_DLL
QPDFObjectHandle getRoot();
QPDF_DLL
std::map<QPDFObjGen, QPDFXRefEntry> getXRefTable();
// Public factory methods
// Create a new stream. A subsequent call must be made to replaceStreamData() to provide data
// for the stream. The stream's dictionary may be retrieved by calling getDict(), and the
// resulting dictionary may be modified. Alternatively, you can create a new dictionary and
// call replaceDict to install it.
QPDF_DLL
QPDFObjectHandle newStream();
// Create a new stream. Use the given buffer as the stream data. The stream dictionary's
// /Length key will automatically be set to the size of the data buffer. If additional keys are
// required, the stream's dictionary may be retrieved by calling getDict(), and the resulting
// dictionary may be modified. This method is just a convenient wrapper around the newStream()
// and replaceStreamData(). It is a convenience methods for streams that require no parameters
// beyond the stream length. Note that you don't have to deal with compression yourself if you
// use QPDFWriter. By default, QPDFWriter will automatically compress uncompressed stream data.
// Example programs are provided that illustrate this.
QPDF_DLL
QPDFObjectHandle newStream(std::shared_ptr<Buffer> data);
// Create new stream with data from string. This method will create a copy of the data rather
// than using the user-provided buffer as in the std::shared_ptr<Buffer> version of newStream.
QPDF_DLL
QPDFObjectHandle newStream(std::string const& data);
// A reserved object is a special sentinel used for qpdf to reserve a spot for an object that is
// going to be added to the QPDF object. Normally you don't have to use this type since you can
// just call QPDF::makeIndirectObject. However, in some cases, if you have to create objects
// with circular references, you may need to create a reserved object so that you can have a
// reference to it and then replace the object later. Reserved objects have the special
// property that they can't be resolved to direct objects. This makes it possible to replace a
// reserved object with a new object while preserving existing references to them. When you are
// ready to replace a reserved object with its replacement, use QPDF::replaceReserved for this
// purpose rather than the more general QPDF::replaceObject. It is an error to try to write a
// QPDF with QPDFWriter if it has any reserved objects in it.
QPDF_DLL
QPDFObjectHandle newReserved();
QPDF_DLL
QPDFObjectHandle newIndirectNull();
// Install this object handle as an indirect object and return an indirect reference to it.
QPDF_DLL
QPDFObjectHandle makeIndirectObject(QPDFObjectHandle);
// Retrieve an object by object ID and generation. Returns an indirect reference to it. The
// getObject() methods were added for qpdf 11.
QPDF_DLL
QPDFObjectHandle getObject(QPDFObjGen);
QPDF_DLL
QPDFObjectHandle getObject(int objid, int generation);
// These are older methods, but there is no intention to deprecate
// them.
QPDF_DLL
QPDFObjectHandle getObjectByObjGen(QPDFObjGen);
QPDF_DLL
QPDFObjectHandle getObjectByID(int objid, int generation);
// Replace the object with the given object id with the given object. The object handle passed
// in must be a direct object, though it may contain references to other indirect objects within
// it. Prior to qpdf 10.2.1, after calling this method, existing QPDFObjectHandle instances that
// pointed to the original object still pointed to the original object, resulting in confusing
// and incorrect behavior. This was fixed in 10.2.1, so existing QPDFObjectHandle objects will
// start pointing to the newly replaced object. Note that replacing an object with
// QPDFObjectHandle::newNull() effectively removes the object from the file since a non-existent
// object is treated as a null object. To replace a reserved object, call replaceReserved
// instead.
QPDF_DLL
void replaceObject(QPDFObjGen og, QPDFObjectHandle);
QPDF_DLL
void replaceObject(int objid, int generation, QPDFObjectHandle);
// Swap two objects given by ID. Prior to qpdf 10.2.1, existing QPDFObjectHandle instances that
// reference them objects not notice the swap, but this was fixed in 10.2.1.
QPDF_DLL
void swapObjects(QPDFObjGen og1, QPDFObjGen og2);
QPDF_DLL
void swapObjects(int objid1, int generation1, int objid2, int generation2);
// Replace a reserved object. This is a wrapper around replaceObject but it guarantees that the
// underlying object is a reserved object or a null object. After this call, reserved will
// be a reference to replacement.
QPDF_DLL
void replaceReserved(QPDFObjectHandle reserved, QPDFObjectHandle replacement);
// Copy an object from another QPDF to this one. Starting with qpdf version 8.3.0, it is no
// longer necessary to keep the original QPDF around after the call to copyForeignObject as long
// as the source of any copied stream data is still available. Usually this means you just have
// to keep the input file around, not the QPDF object. The exception to this is if you copy a
// stream that gets its data from a QPDFObjectHandle::StreamDataProvider. In this case only, the
// original stream's QPDF object must stick around because the QPDF object is itself the source
// of the original stream data. For a more in-depth discussion, please see the TODO file.
// Starting in 8.4.0, you can call setImmediateCopyFrom(true) on the SOURCE QPDF object (the one
// you're copying FROM). If you do this prior to copying any of its objects, then neither the
// source QPDF object nor its input source needs to stick around at all regardless of the
// source. The cost is that the stream data is copied into RAM at the time copyForeignObject is
// called. See setImmediateCopyFrom for more information.
//
// The return value of this method is an indirect reference to the copied object in this file.
// This method is intended to be used to copy non-page objects. To copy page objects, pass the
// foreign page object directly to addPage (or addPageAt). If you copy objects that contain
// references to pages, you should copy the pages first using addPage(At). Otherwise references
// to the pages that have not been copied will be replaced with nulls. It is possible to use
// copyForeignObject on page objects if you are not going to use them as pages. Doing so copies
// the object normally but does not update the page structure. For example, it is a valid use
// case to use copyForeignObject for a page that you are going to turn into a form XObject,
// though you can also use QPDFPageObjectHelper::getFormXObjectForPage for that purpose.
//
// When copying objects with this method, object structure will be preserved, so all indirectly
// referenced indirect objects will be copied as well. This includes any circular references
// that may exist. The QPDF object keeps a record of what has already been copied, so shared
// objects will not be copied multiple times. This also means that if you mutate an object that
// has already been copied and try to copy it again, it won't work since the modified object
// will not be recopied. Therefore, you should do all mutation on the original file that you
// are going to do before you start copying its objects to a new file.
QPDF_DLL
QPDFObjectHandle copyForeignObject(QPDFObjectHandle foreign);
// Encryption support
enum encryption_method_e { e_none, e_unknown, e_rc4, e_aes, e_aesv3 };
// To be removed from the public API in qpdf 13. See
// <https:manual.qpdf.org/release-notes.html#r12-3-0-deprecate>.
class EncryptionData
{
public:
// This class holds data read from the encryption dictionary.
EncryptionData(
int V,
int R,
int Length_bytes,
int P,
std::string const& O,
std::string const& U,
std::string const& OE,
std::string const& UE,
std::string const& Perms,
std::string const& id1,
bool encrypt_metadata) :
V(V),
R(R),
Length_bytes(Length_bytes),
P(P),
O(O),
U(U),
OE(OE),
UE(UE),
Perms(Perms),
id1(id1),
encrypt_metadata(encrypt_metadata)
{
}
int getV() const;
int getR() const;
int getLengthBytes() const;
int getP() const;
std::string const& getO() const;
std::string const& getU() const;
std::string const& getOE() const;
std::string const& getUE() const;
std::string const& getPerms() const;
std::string const& getId1() const;
bool getEncryptMetadata() const;
void setO(std::string const&);
void setU(std::string const&);
void setV5EncryptionParameters(
std::string const& O,
std::string const& OE,
std::string const& U,
std::string const& UE,
std::string const& Perms);
private:
EncryptionData(EncryptionData const&) = delete;
EncryptionData& operator=(EncryptionData const&) = delete;
int V;
int R;
int Length_bytes;
int P;
std::string O;
std::string U;
std::string OE;
std::string UE;
std::string Perms;
std::string id1;
bool encrypt_metadata;
};
QPDF_DLL
bool isEncrypted() const;
QPDF_DLL
bool isEncrypted(int& R, int& P);
QPDF_DLL
bool isEncrypted(
int& R,
int& P,
int& V,
encryption_method_e& stream_method,
encryption_method_e& string_method,
encryption_method_e& file_method);
QPDF_DLL
bool ownerPasswordMatched() const;
QPDF_DLL
bool userPasswordMatched() const;
// Encryption permissions -- not enforced by QPDF
QPDF_DLL
bool allowAccessibility();
QPDF_DLL
bool allowExtractAll();
QPDF_DLL
bool allowPrintLowRes();
QPDF_DLL
bool allowPrintHighRes();
QPDF_DLL
bool allowModifyAssembly();
QPDF_DLL
bool allowModifyForm();
QPDF_DLL
bool allowModifyAnnotation();
QPDF_DLL
bool allowModifyOther();
QPDF_DLL
bool allowModifyAll();
// Helper function to trim padding from user password. Calling trim_user_password on the result
// of getPaddedUserPassword gives getTrimmedUserPassword's result.
QPDF_DLL
static void trim_user_password(std::string& user_password);
QPDF_DLL
static std::string compute_data_key(
std::string const& encryption_key,
int objid,
int generation,
bool use_aes,
int encryption_V,
int encryption_R);
// To be removed in qpdf 13. See <https:manual.qpdf.org/release-notes.html#r12-3-0-deprecate>.
[[deprecated("to be removed in qpdf 13")]]
QPDF_DLL static std::string
compute_encryption_key(std::string const& password, EncryptionData const& data);
QPDF_DLL
static void compute_encryption_O_U(
char const* user_password,
char const* owner_password,
int V,
int R,
int key_len,
int P,
bool encrypt_metadata,
std::string const& id1,
std::string& O,
std::string& U);
QPDF_DLL
static void compute_encryption_parameters_V5(
char const* user_password,
char const* owner_password,
int V,
int R,
int key_len,
int P,
bool encrypt_metadata,
std::string const& id1,
std::string& encryption_key,
std::string& O,
std::string& U,
std::string& OE,
std::string& UE,
std::string& Perms);
// Return the full user password as stored in the PDF file. For files encrypted with 40-bit or
// 128-bit keys, the user password can be recovered when the file is opened using the owner
// password. This is not possible with newer encryption formats. If you are attempting to
// recover the user password in a user-presentable form, call getTrimmedUserPassword() instead.
QPDF_DLL
std::string const& getPaddedUserPassword() const;
// Return human-readable form of user password subject to same limitations as
// getPaddedUserPassword().
QPDF_DLL
std::string getTrimmedUserPassword() const;
// Return the previously computed or retrieved encryption key for this file
QPDF_DLL
std::string getEncryptionKey() const;
// Remove security restrictions associated with digitally signed files. From qpdf 11.7.0, this
// is called by QPDFAcroFormDocumentHelper::disableDigitalSignatures and is more useful when
// called from there than when just called by itself.
QPDF_DLL
void removeSecurityRestrictions();
// Linearization support
// Returns true iff the file starts with a linearization parameter dictionary. Does no
// additional validation.
QPDF_DLL
bool isLinearized();
// Performs various sanity checks on a linearized file. Return true if no errors or warnings.
// Otherwise, return false and output errors and warnings to the default output stream
// (std::cout or whatever is configured in the logger). It is recommended for linearization
// errors to be treated as warnings.
QPDF_DLL
bool checkLinearization();
// Calls checkLinearization() and, if possible, prints normalized contents of some of the hints
// tables to the default output stream. Normalization includes adding min values to delta values
// and adjusting offsets based on the location and size of the primary hint stream.
QPDF_DLL
void showLinearizationData();
// Shows the contents of the cross-reference table
QPDF_DLL
void showXRefTable();
// Starting from qpdf 11.0 user code should not need to call this method. Before 11.0 this
// method was used to detect all indirect references to objects that don't exist and resolve
// them by replacing them with null, which is how the PDF spec says to interpret such dangling
// references. This method is called automatically when you try to add any new objects, if you
// call getAllObjects, and before a file is written. The qpdf object caches whether it has run
// this to avoid running it multiple times. Before 11.2.1 you could pass true to force it to run
// again if you had explicitly added new objects that may have additional dangling references.
QPDF_DLL
void fixDanglingReferences(bool force = false);
// Return the approximate number of indirect objects. It is/ approximate because not all objects
// in the file are preserved in all cases, and gaps in object numbering are not preserved.
QPDF_DLL
size_t getObjectCount();
// Returns a list of indirect objects for every object in the xref table. Useful for discovering
// objects that are not otherwise referenced.
QPDF_DLL
std::vector<QPDFObjectHandle> getAllObjects();
// Optimization support -- see doc/optimization. Implemented in QPDF_optimization.cc
// The object_stream_data map maps from a "compressed" object to the object stream that contains
// it. This enables optimize to populate the object <-> user maps with only uncompressed
// objects. If allow_changes is false, an exception will be thrown if any changes are made
// during the optimization process. This is available so that the test suite can make sure that
// a linearized file is already optimized. When called in this way, optimize() still populates
// the object <-> user maps. The optional skip_stream_parameters parameter, if present, is
// called for each stream object. The function should return 2 if optimization should discard
// /Length, /Filter, and /DecodeParms; 1 if it should discard /Length, and 0 if it should
// preserve all keys. This is used by QPDFWriter to avoid creation of dangling objects for
// stream dictionary keys it will be regenerating.
[[deprecated("Unused - see release notes for qpdf 12.1.0")]] QPDF_DLL void optimize(
std::map<int, int> const& object_stream_data,
bool allow_changes = true,
std::function<int(QPDFObjectHandle&)> skip_stream_parameters = nullptr);
// Traverse page tree return all /Page objects. It also detects and resolves cases in which the
// same /Page object is duplicated. For efficiency, this method returns a const reference to an
// internal vector of pages. Calls to addPage, addPageAt, and removePage safely update this, but
// direct manipulation of the pages tree or pushing inheritable objects to the page level may
// invalidate it. See comments for updateAllPagesCache() for additional notes. Newer code should
// use QPDFPageDocumentHelper::getAllPages instead. The decision to expose this internal cache
// was arguably incorrect, but it is being left here for compatibility. It is, however,
// completely safe to use this for files that you are not modifying.
QPDF_DLL
std::vector<QPDFObjectHandle> const& getAllPages();
QPDF_DLL
bool everCalledGetAllPages() const;
QPDF_DLL
bool everPushedInheritedAttributesToPages() const;
// These methods, given a page object or its object/generation number, returns the 0-based index
// into the array returned by getAllPages() for that page. An exception is thrown if the page is
// not found.
QPDF_DLL
int findPage(QPDFObjGen og);
QPDF_DLL
int findPage(QPDFObjectHandle& page);
// This method synchronizes QPDF's cache of the page structure with the actual /Pages tree. If
// you restrict changes to the /Pages tree, including addition, removal, or replacement of pages
// or changes to any /Pages objects, to calls to these page handling APIs, you never need to
// call this method. If you modify /Pages structures directly, you must call this method
// afterwards. This method updates the internal list of pages, so after calling this method,
// any previous references returned by getAllPages() will be valid again. It also resets any
// state about having pushed inherited attributes in /Pages objects down to the pages, so if you
// add any inheritable attributes to a /Pages object, you should also call this method.
QPDF_DLL
void updateAllPagesCache();
// Legacy handling API. These methods are not going anywhere, and you should feel free to
// continue using them if it simplifies your code. Newer code should make use of
// QPDFPageDocumentHelper instead as future page handling methods will be added there. The
// functionality and specification of these legacy methods is identical to the identically named
// methods there, except that these versions use QPDFObjectHandle instead of
// QPDFPageObjectHelper, so please see comments in that file for descriptions. There are
// subtleties you need to know about, so please look at the comments there.
QPDF_DLL
void pushInheritedAttributesToPage();
QPDF_DLL
void addPage(QPDFObjectHandle newpage, bool first);
QPDF_DLL
void addPageAt(QPDFObjectHandle newpage, bool before, QPDFObjectHandle refpage);
QPDF_DLL
void removePage(QPDFObjectHandle page);
// End legacy page helpers
// End of the public API. The following classes and methods are for qpdf internal use only.
class Doc;
inline Doc& doc();
// For testing only -- do not add to DLL
static bool test_json_validators();
private:
// It has never been safe to copy QPDF objects as there is code in the library that assumes
// there are no copies of a QPDF object. Copying QPDF objects was not prevented by the API until
// qpdf 11. If you have been copying QPDF objects, use std::shared_ptr<QPDF> instead. From qpdf
// 11, you can use QPDF::create to create them.
QPDF(QPDF const&) = delete;
QPDF& operator=(QPDF const&) = delete;
static std::string const qpdf_version;
class ObjCache;
class EncryptionParameters;
class StringDecrypter;
class ResolveRecorder;
class JSONReactor;
void removeObject(QPDFObjGen og);
// Calls finish() on the pipeline when done but does not delete it
bool pipeStreamData(
QPDFObjGen og,
qpdf_offset_t offset,
size_t length,
QPDFObjectHandle dict,
bool is_root_metadata,
Pipeline* pipeline,
bool suppress_warnings,
bool will_retry);
static bool pipeStreamData(
std::shared_ptr<QPDF::EncryptionParameters> encp,
std::shared_ptr<InputSource> file,
QPDF& qpdf_for_warning,
QPDFObjGen og,
qpdf_offset_t offset,
size_t length,
QPDFObjectHandle dict,
bool is_root_metadata,
Pipeline* pipeline,
bool suppress_warnings,
bool will_retry);
// methods to support encryption -- implemented in QPDF_encryption.cc
void initializeEncryption();
static std::string
getKeyForObject(std::shared_ptr<EncryptionParameters> encp, QPDFObjGen og, bool use_aes);
void decryptString(std::string&, QPDFObjGen og);
static void decryptStream(
std::shared_ptr<EncryptionParameters> encp,
std::shared_ptr<InputSource> file,
QPDF& qpdf_for_warning,
Pipeline*& pipeline,
QPDFObjGen og,
QPDFObjectHandle& stream_dict,
bool is_root_metadata,
std::unique_ptr<Pipeline>& heap);
// JSON import
void importJSON(std::shared_ptr<InputSource>, bool must_be_complete);
class Members;
// Keep all member variables inside the Members object, which we dynamically allocate. This
// makes it possible to add new private members without breaking binary compatibility.
std::unique_ptr<Members> m;
};
#endif // QPDF_HH
@@ -0,0 +1,234 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
#ifndef QPDFACROFORMDOCUMENTHELPER_HH
#define QPDFACROFORMDOCUMENTHELPER_HH
#include <qpdf/QPDFDocumentHelper.hh>
#include <qpdf/DLL.h>
#include <qpdf/QPDFAnnotationObjectHelper.hh>
#include <qpdf/QPDFFormFieldObjectHelper.hh>
#include <qpdf/QPDFPageObjectHelper.hh>
#include <map>
#include <set>
#include <vector>
// This document helper is intended to help with operations on interactive forms. Here are the key
// things to know:
// * The PDF specification talks about interactive forms and also about form XObjects. While form
// XObjects appear in parts of interactive forms, this class is concerned about interactive forms,
// not form XObjects.
//
// * Interactive forms are discussed in the PDF Specification (ISO PDF 32000-1:2008) section 12.7.
// Also relevant is the section about Widget annotations. Annotations are discussed in section
// 12.5 with annotation dictionaries discussed in 12.5.1. Widget annotations are discussed
// specifically in section 12.5.6.19.
//
// * What you need to know about the structure of interactive forms in PDF files:
//
// - The document catalog contains the key "/AcroForm" which contains a list of fields. Fields are
// represented as a tree structure much like pages. Nodes in the fields tree may contain other
// fields. Fields may inherit values of many of their attributes from ancestors in the tree.
//
// - Fields may also have children that are widget annotations. As a special case, and a cause of
// considerable confusion, if a field has a single annotation as a child, the annotation
// dictionary may be merged with the field dictionary. In that case, the field and the
// annotation are in the same object. Note that, while field dictionary attributes are
// inherited, annotation dictionary attributes are not.
//
// - A page dictionary contains a key called "/Annots" which contains a simple list of
// annotations. For any given annotation of subtype "/Widget", you should encounter that
// annotation in the "/Annots" dictionary of a page, and you should also be able to reach it by
// traversing through the "/AcroForm" dictionary from the document catalog. In the simplest case
// (and also a very common case), a form field's widget annotation will be merged with the field
// object, and the object will appear directly both under "/Annots" in the page dictionary and
// under "/Fields" in the "/AcroForm" dictionary. In a more complex case, you may have to trace
// through various "/Kids" elements in the "/AcroForm" field entry until you find the annotation
// dictionary.
class QPDFAcroFormDocumentHelper: public QPDFDocumentHelper
{
public:
// Get a shared document helper for a given QPDF object.
//
// Retrieving a document helper for a QPDF object rather than creating a new one avoids repeated
// validation of the Acroform structure, which can be expensive.
QPDF_DLL
static QPDFAcroFormDocumentHelper& get(QPDF& qpdf);
// Re-validate the AcroForm structure. This is useful if you have modified the structure of the
// AcroForm dictionary in a way that would invalidate the cache.
//
// If repair is true, the document will be repaired if possible if the validation encounters
// errors.
QPDF_DLL
void validate(bool repair = true);
QPDF_DLL
QPDFAcroFormDocumentHelper(QPDF&);
~QPDFAcroFormDocumentHelper() override = default;
// This class lazily creates an internal cache of the mapping among form fields, annotations,
// and pages. Methods within this class preserve the validity of this cache. However, if you
// modify pages' annotation dictionaries, the document's /AcroForm dictionary, or any form
// fields manually in a way that alters the association between forms, fields, annotations, and
// pages, it may cause this cache to become invalid. This method marks the cache invalid and
// forces it to be regenerated the next time it is needed.
QPDF_DLL
void invalidateCache();
QPDF_DLL
bool hasAcroForm();
// Add a form field, initializing the document's AcroForm dictionary if needed, updating the
// cache if necessary. Note that you are adding fields that are copies of other fields, this
// method may result in multiple fields existing with the same qualified name, which can have
// unexpected side effects. In that case, you should use addAndRenameFormFields() instead.
QPDF_DLL
void addFormField(QPDFFormFieldObjectHelper);
// Add a collection of form fields making sure that their fully qualified names don't conflict
// with already present form fields. Fields within the collection of new fields that have the
// same name as each other will continue to do so.
QPDF_DLL
void addAndRenameFormFields(std::vector<QPDFObjectHandle> fields);
// Remove fields from the fields array
QPDF_DLL
void removeFormFields(std::set<QPDFObjGen> const&);
// Set the name of a field, updating internal records of field names. Name should be UTF-8
// encoded.
QPDF_DLL
void setFormFieldName(QPDFFormFieldObjectHelper, std::string const& name);
// Return a vector of all terminal fields in a document. Terminal fields are fields that have no
// children that are also fields. Terminal fields may still have children that are annotations.
// Intermediate nodes in the fields tree are not included in this list, but you can still reach
// them through the getParent method of the field object helper.
QPDF_DLL
std::vector<QPDFFormFieldObjectHelper> getFormFields();
// Return all the form fields that have the given fully-qualified name and also have an explicit
// "/T" attribute. For this information to be accurate, any changes to field names must be done
// through setFormFieldName() above.
QPDF_DLL
std::set<QPDFObjGen> getFieldsWithQualifiedName(std::string const& name);
// Return the annotations associated with a terminal field. Note that in the case of a field
// having a single annotation, the underlying object will typically be the same as the
// underlying object for the field.
QPDF_DLL
std::vector<QPDFAnnotationObjectHelper> getAnnotationsForField(QPDFFormFieldObjectHelper);
// Return annotations of subtype /Widget for a page.
QPDF_DLL
std::vector<QPDFAnnotationObjectHelper> getWidgetAnnotationsForPage(QPDFPageObjectHelper);
// Return top-level form fields for a page.
QPDF_DLL
std::vector<QPDFFormFieldObjectHelper> getFormFieldsForPage(QPDFPageObjectHelper);
// Return the terminal field that is associated with this annotation. If the annotation
// dictionary is merged with the field dictionary, the underlying object will be the same, but
// this is not always the case. Note that if you call this method with an annotation that is not
// a widget annotation, there will not be an associated field, and this method will return a
// helper associated with a null object (isNull() == true).
QPDF_DLL
QPDFFormFieldObjectHelper getFieldForAnnotation(QPDFAnnotationObjectHelper);
// Return the current value of /NeedAppearances. If /NeedAppearances is missing, return false as
// that is how PDF viewers are supposed to interpret it.
QPDF_DLL
bool getNeedAppearances();
// Indicate whether appearance streams must be regenerated. If you modify a field value, you
// should call setNeedAppearances(true) unless you also generate an appearance stream for the
// corresponding annotation at the same time. If you generate appearance streams for all fields,
// you can call setNeedAppearances(false). If you use QPDFFormFieldObjectHelper::setV, it will
// automatically call this method unless you tell it not to.
QPDF_DLL
void setNeedAppearances(bool);
// If /NeedAppearances is false, do nothing. Otherwise generate appearance streams for all
// widget annotations that need them. See comments in QPDFFormFieldObjectHelper.hh for
// generateAppearance for limitations. For checkbox and radio button fields, this code ensures
// that appearance state is consistent with the field's value and uses any pre-existing
// appearance streams.
QPDF_DLL
void generateAppearancesIfNeeded();
// Disable Digital Signature Fields. Remove all digital signature fields from the document,
// leaving any annotation showing the content of the field intact. This also calls
// QPDF::removeSecurityRestrictions.
QPDF_DLL
void disableDigitalSignatures();
// Note: this method works on all annotations, not just ones with associated fields. For each
// annotation in old_annots, apply the given transformation matrix to create a new annotation.
// New annotations are appended to new_annots. If the annotation is associated with a form
// field, a new form field is created that points to the new annotation and is appended to
// new_fields, and the old field is added to old_fields.
//
// old_annots may belong to a different QPDF object. In that case, you should pass in from_qpdf,
// and copyForeignObject will be called automatically. If this is the case, for efficiency, you
// may pass in a QPDFAcroFormDocumentHelper for the other file to avoid the expensive process of
// creating one for each call to transformAnnotations. New fields and annotations are not added
// to the document or pages. You have to do that yourself after calling transformAnnotations. If
// this operation will leave orphaned fields behind, such as if you are replacing the old
// annotations with the new ones on the same page and the fields and annotations are not shared,
// you will also need to remove the old fields to prevent them from hanging around unreferenced.
QPDF_DLL
void transformAnnotations(
QPDFObjectHandle old_annots,
std::vector<QPDFObjectHandle>& new_annots,
std::vector<QPDFObjectHandle>& new_fields,
std::set<QPDFObjGen>& old_fields,
QPDFMatrix const& cm,
QPDF* from_qpdf = nullptr,
QPDFAcroFormDocumentHelper* from_afdh = nullptr);
// Copy form fields and annotations from one page to another, allowing the from page to be in a
// different QPDF or in the same QPDF. This would typically be called after calling addPage to
// add field/annotation awareness. When just copying the page by itself, annotations end up
// being shared, and fields end up being omitted because there is no reference to the field from
// the page. This method ensures that each separate copy of a page has private annotations and
// that fields and annotations are properly updated to resolve conflicts that may occur from
// common resource and field names across documents. It is basically a wrapper around
// transformAnnotations that handles updating the receiving page. If new_fields is non-null, any
// newly created fields are added to it.
QPDF_DLL
void fixCopiedAnnotations(
QPDFObjectHandle to_page,
QPDFObjectHandle from_page,
QPDFAcroFormDocumentHelper& from_afdh,
std::set<QPDFObjGen>* new_fields = nullptr);
private:
friend class QPDF::Doc;
class Members;
std::shared_ptr<Members> m;
};
#endif // QPDFACROFORMDOCUMENTHELPER_HH
@@ -0,0 +1,105 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
#ifndef QPDFANNOTATIONOBJECTHELPER_HH
#define QPDFANNOTATIONOBJECTHELPER_HH
#include <qpdf/Constants.h>
#include <qpdf/QPDFObjectHelper.hh>
#include <qpdf/DLL.h>
class QPDFAnnotationObjectHelper: public QPDFObjectHelper
{
public:
QPDF_DLL
QPDFAnnotationObjectHelper(QPDFObjectHandle);
~QPDFAnnotationObjectHelper() override = default;
// This class provides helper methods for annotations. More functionality will likely be added
// in the future.
// Some functionality for annotations is also implemented in QPDFAcroFormDocumentHelper and
// QPDFFormFieldObjectHelper. In some cases, functions defined there work for other annotations
// besides widget annotations, but they are implemented with form fields so that they can
// properly handle form fields when needed.
// Return the subtype of the annotation as a string (e.g. "/Widget"). Returns an empty string
// if the subtype (which is required by the spec) is missing.
QPDF_DLL
std::string getSubtype();
QPDF_DLL
QPDFObjectHandle::Rectangle getRect();
QPDF_DLL
QPDFObjectHandle getAppearanceDictionary();
// Return the appearance state as given in "/AS", or an empty string if none is given.
QPDF_DLL
std::string getAppearanceState();
// Return flags from "/F". The value is a logical or of pdf_annotation_flag_e as defined in
// qpdf/Constants.h.
QPDF_DLL
int getFlags();
// Return a specific stream. "which" may be one of "/N", "/R", or "/D" to indicate the normal,
// rollover, or down appearance stream. (Any value may be passed to "which"; if an appearance
// stream of that name exists, it will be returned.) If the value associated with "which" in the
// appearance dictionary is a subdictionary, an appearance state may be specified to select
// which appearance stream is desired. If not specified, the appearance state in "/AS" will
// used.
QPDF_DLL
QPDFObjectHandle getAppearanceStream(std::string const& which, std::string const& state = "");
// Generate text suitable for addition to the containing page's content stream that draws this
// annotation's appearance stream as a form XObject. The value "name" is the resource name that
// will be used to refer to the form xobject. The value "rotate" should be set to the page's
// /Rotate value or 0 if none. The values of required_flags and forbidden_flags are constructed
// by logically "or"ing annotation flags of type pdf_annotation_flag_e defined in
// qpdf/Constants.h. Content will be returned only if all required_flags are set and no
// forbidden_flags are set. For example, including an_no_view in forbidden_flags could be useful
// for creating an on-screen view, and including an_print to required_flags could be useful if
// preparing to print.
QPDF_DLL
std::string getPageContentForAppearance(
std::string const& name,
int rotate,
int required_flags = 0,
int forbidden_flags = an_invisible | an_hidden);
private:
class Members
{
friend class QPDFAnnotationObjectHelper;
public:
~Members() = default;
private:
Members() = default;
Members(Members const&) = delete;
};
std::shared_ptr<Members> m;
};
#endif // QPDFANNOTATIONOBJECTHELPER_HH
@@ -0,0 +1,82 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Versions of qpdf prior to version 7 were released under the terms
// of version 2.0 of the Artistic License. At your option, you may
// continue to consider qpdf to be licensed under those terms. Please
// see the manual for additional information.
#ifndef QPDFCRYPTOIMPL_HH
#define QPDFCRYPTOIMPL_HH
#include <qpdf/DLL.h>
#include <string>
// This class is part of qpdf's pluggable crypto provider support.
// Most users won't need to know or care about this class, but you can
// use it if you want to supply your own crypto implementation. To do
// so, provide an implementation of QPDFCryptoImpl, ensure that you
// register it by calling QPDFCryptoProvider::registerImpl, and make
// it the default by calling QPDFCryptoProvider::setDefaultProvider.
class QPDF_DLL_CLASS QPDFCryptoImpl
{
public:
QPDFCryptoImpl() = default;
virtual ~QPDFCryptoImpl() = default;
// Random Number Generation
virtual void provideRandomData(unsigned char* data, size_t len) = 0;
// Hashing
typedef unsigned char MD5_Digest[16];
virtual void MD5_init() = 0;
virtual void MD5_update(unsigned char const* data, size_t len) = 0;
virtual void MD5_finalize() = 0;
virtual void MD5_digest(MD5_Digest) = 0;
virtual void SHA2_init(int bits) = 0;
virtual void SHA2_update(unsigned char const* data, size_t len) = 0;
virtual void SHA2_finalize() = 0;
virtual std::string SHA2_digest() = 0;
// Encryption/Decryption
// QPDF must support RC4 to be able to work with older PDF files
// and readers. Search for RC4 in README.md
// key_len of -1 means treat key_data as a null-terminated string
virtual void RC4_init(unsigned char const* key_data, int key_len = -1) = 0;
// out_data = 0 means to encrypt/decrypt in place
virtual void
RC4_process(unsigned char const* in_data, size_t len, unsigned char* out_data = nullptr) = 0;
virtual void RC4_finalize() = 0;
static size_t constexpr rijndael_buf_size = 16;
virtual void rijndael_init(
bool encrypt,
unsigned char const* key_data,
size_t key_len,
bool cbc_mode,
unsigned char* cbc_block) = 0;
virtual void rijndael_process(unsigned char* in_data, unsigned char* out_data) = 0;
virtual void rijndael_finalize() = 0;
};
#endif // QPDFCRYPTOIMPL_HH
@@ -0,0 +1,107 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
#ifndef QPDFCRYPTOPROVIDER_HH
#define QPDFCRYPTOPROVIDER_HH
#include <qpdf/DLL.h>
#include <qpdf/QPDFCryptoImpl.hh>
#include <functional>
#include <map>
#include <memory>
#include <set>
#include <string>
// This class is part of qpdf's pluggable crypto provider support. Most users won't need to know or
// care about this class, but you can use it if you want to supply your own crypto implementation.
// See also comments in QPDFCryptoImpl.hh.
class QPDFCryptoProvider
{
public:
// Methods for getting and registering crypto implementations. These methods are not
// thread-safe.
// Return an instance of a crypto provider using the default implementation.
QPDF_DLL
static std::shared_ptr<QPDFCryptoImpl> getImpl();
// Return an instance of the crypto provider registered using the given name.
QPDF_DLL
static std::shared_ptr<QPDFCryptoImpl> getImpl(std::string const& name);
typedef std::function<std::shared_ptr<QPDFCryptoImpl>()> provider_fn;
// Register a crypto implementation with the given name. The provider function must return
// a shared pointer to an instance of the implementation class, which must be derived from
// QPDFCryptoImpl.
QPDF_DLL static void registerImpl(std::string const& name, provider_fn f);
// Register the given type (T) as a crypto implementation. T must be derived from QPDFCryptoImpl
// and must have a constructor that takes no arguments.
template <typename T>
static void
registerImpl(std::string const& name)
{
registerImpl(name, std::make_shared<T>);
}
// Set the crypto provider registered with the given name as the default crypto implementation.
QPDF_DLL
static void setDefaultProvider(std::string const& name);
// Get the names of registered implementations
QPDF_DLL
static std::set<std::string> getRegisteredImpls();
// Get the name of the default crypto provider
QPDF_DLL
static std::string getDefaultProvider();
private:
QPDFCryptoProvider();
~QPDFCryptoProvider() = default;
QPDFCryptoProvider(QPDFCryptoProvider const&) = delete;
QPDFCryptoProvider& operator=(QPDFCryptoProvider const&) = delete;
static QPDFCryptoProvider& getInstance();
std::shared_ptr<QPDFCryptoImpl> getImpl_internal(std::string const& name) const;
void registerImpl_internal(std::string const& name, provider_fn f);
void setDefaultProvider_internal(std::string const& name);
class Members
{
friend class QPDFCryptoProvider;
public:
Members() = default;
~Members() = default;
private:
Members(Members const&) = delete;
Members& operator=(Members const&) = delete;
std::string default_provider;
std::map<std::string, provider_fn> providers;
};
std::shared_ptr<Members> m;
};
#endif // QPDFCRYPTOPROVIDER_HH
@@ -0,0 +1,57 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
#ifndef QPDFDOCUMENTHELPER_HH
#define QPDFDOCUMENTHELPER_HH
#include <qpdf/DLL.h>
#include <qpdf/QPDF.hh>
// This is a base class for QPDF Document Helper classes. Document helpers are classes that provide
// a convenient, higher-level API for accessing document-level structures within a PDF file.
// Document helpers are always initialized with a reference to a QPDF object, and the object can
// always be retrieved. The intention is that you may freely intermix use of document helpers with
// the underlying QPDF object unless there is a specific comment in a specific helper method that
// says otherwise. The pattern of using helper objects was introduced to allow creation of higher
// level helper functions without polluting the public interface of QPDF.
class QPDF_DLL_CLASS QPDFDocumentHelper
{
public:
QPDFDocumentHelper(QPDF& qpdf) :
qpdf(qpdf)
{
}
QPDF_DLL
virtual ~QPDFDocumentHelper();
QPDF&
getQPDF()
{
return qpdf;
}
QPDF const&
getQPDF() const
{
return qpdf;
}
protected:
QPDF& qpdf;
};
#endif // QPDFDOCUMENTHELPER_HH
@@ -0,0 +1,100 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
#ifndef QPDFEFSTREAMOBJECTHELPER_HH
#define QPDFEFSTREAMOBJECTHELPER_HH
#include <qpdf/QPDFObjectHelper.hh>
#include <qpdf/DLL.h>
#include <qpdf/QPDFObjectHandle.hh>
#include <functional>
// This class provides a higher level interface around Embedded File Streams, which are discussed in
// section 7.11.4 of the ISO-32000 PDF specification.
class QPDFEFStreamObjectHelper: public QPDFObjectHelper
{
public:
QPDF_DLL
QPDFEFStreamObjectHelper(QPDFObjectHandle);
~QPDFEFStreamObjectHelper() override = default;
// Date parameters are strings that conform to the PDF spec for date/time strings, which is
// "D:yyyymmddhhmmss<z>" where <z> is either "Z" for UTC or "-hh'mm'" or "+hh'mm'" for timezone
// offset. Examples: "D:20210207161528-05'00'", "D:20210207211528Z". See
// QUtil::qpdf_time_to_pdf_time.
QPDF_DLL
std::string getCreationDate();
QPDF_DLL
std::string getModDate();
// Get size as reported in the object; return 0 if not present.
QPDF_DLL
size_t getSize();
// Subtype is a mime type such as "text/plain"
QPDF_DLL
std::string getSubtype();
// Return the checksum as stored in the object as a binary string. This does not check
// consistency with the data. If not present, return an empty string. The PDF spec specifies
// this as an MD5 checksum and notes that it is not to be used for security purposes since MD5
// is known to be insecure.
QPDF_DLL
std::string getChecksum();
// Setters return a reference to this object so that they can be used as fluent interfaces, e.g.
// efsoh.setCreationDate(x).setModDate(y);
// Create a new embedded file stream with the given stream data, which can be provided in any of
// several ways. To get the new object back, call getObjectHandle() on the returned object. The
// checksum and size are computed automatically and stored. Other parameters may be supplied
// using setters defined below.
QPDF_DLL
static QPDFEFStreamObjectHelper createEFStream(QPDF& qpdf, std::shared_ptr<Buffer> data);
QPDF_DLL
static QPDFEFStreamObjectHelper createEFStream(QPDF& qpdf, std::string const& data);
// The provider function must write the data to the given pipeline. The function may be called
// multiple times by the qpdf library. You can pass QUtil::file_provider(filename) as the
// provider to have the qpdf library provide the contents of filename as a binary.
QPDF_DLL
static QPDFEFStreamObjectHelper
createEFStream(QPDF& qpdf, std::function<void(Pipeline*)> provider);
// Setters for other parameters
QPDF_DLL
QPDFEFStreamObjectHelper& setCreationDate(std::string const&);
QPDF_DLL
QPDFEFStreamObjectHelper& setModDate(std::string const&);
// Set subtype as a mime-type, e.g. "text/plain" or "application/pdf".
QPDF_DLL
QPDFEFStreamObjectHelper& setSubtype(std::string const&);
private:
QPDFObjectHandle getParam(std::string const& pkey);
void setParam(std::string const& pkey, QPDFObjectHandle const&);
static QPDFEFStreamObjectHelper newFromStream(QPDFObjectHandle stream);
class Members;
std::shared_ptr<Members> m;
};
#endif // QPDFEFSTREAMOBJECTHELPER_HH
@@ -0,0 +1,90 @@
// Copyright (c) 2005-2021 Jay Berkenbilt
// Copyright (c) 2022-2026 Jay Berkenbilt and Manfred Holger
//
// This file is part of qpdf.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied. See the License for the specific language governing permissions and limitations under
// the License.
//
// Versions of qpdf prior to version 7 were released under the terms of version 2.0 of the Artistic
// License. At your option, you may continue to consider qpdf to be licensed under those terms.
// Please see the manual for additional information.
#ifndef QPDFEMBEDDEDFILEDOCUMENTHELPER_HH
#define QPDFEMBEDDEDFILEDOCUMENTHELPER_HH
#include <qpdf/QPDFDocumentHelper.hh>
#include <qpdf/DLL.h>
#include <qpdf/QPDF.hh>
#include <qpdf/QPDFFileSpecObjectHelper.hh>
#include <qpdf/QPDFNameTreeObjectHelper.hh>
#include <map>
#include <memory>
// This class provides a higher level interface around document-level file attachments, also known
// as embedded files. These are discussed in sections 7.7.4 and 7.11 of the ISO-32000 PDF
// specification.
class QPDFEmbeddedFileDocumentHelper: public QPDFDocumentHelper
{
public:
// Get a shared document helper for a given QPDF object.
//
// Retrieving a document helper for a QPDF object rather than creating a new one avoids repeated
// validation of the EmbeddedFiles structure, which can be expensive.
QPDF_DLL
static QPDFEmbeddedFileDocumentHelper& get(QPDF& qpdf);
// Re-validate the EmbeddedFiles structure. This is useful if you have modified the structure of
// the EmbeddedFiles dictionary in a way that would invalidate the cache.
//
// If repair is true, the document will be repaired if possible if the validation encounters
// errors.
QPDF_DLL
void validate(bool repair = true);
QPDF_DLL
QPDFEmbeddedFileDocumentHelper(QPDF&);
~QPDFEmbeddedFileDocumentHelper() override = default;
QPDF_DLL
bool hasEmbeddedFiles() const;
QPDF_DLL
std::map<std::string, std::shared_ptr<QPDFFileSpecObjectHelper>> getEmbeddedFiles();
// If an embedded file with the given name exists, return a (shared) pointer to it. Otherwise,
// return nullptr.
QPDF_DLL
std::shared_ptr<QPDFFileSpecObjectHelper> getEmbeddedFile(std::string const& name);
// Add or replace an attachment
QPDF_DLL
void replaceEmbeddedFile(std::string const& name, QPDFFileSpecObjectHelper const&);
// Remove an embedded file if present. Return value is true if the file was present and was
// removed. This method not only removes the embedded file from the embedded files name tree but
// also nulls out the file specification dictionary. This means that any references to this file
// from file attachment annotations will also stop working. This is the best way to make the
// attachment actually disappear from the file and not just from the list of attachments.
QPDF_DLL
bool removeEmbeddedFile(std::string const& name);
private:
void initEmbeddedFiles();
class Members;
std::shared_ptr<Members> m;
};
#endif // QPDFEMBEDDEDFILEDOCUMENTHELPER_HH

Some files were not shown because too many files have changed in this diff Show More