diff options
Diffstat (limited to 'debian/uncrustify-trinity/uncrustify-trinity-0.75.0/debian/patches/002_trinity_customization.diff')
-rw-r--r-- | debian/uncrustify-trinity/uncrustify-trinity-0.75.0/debian/patches/002_trinity_customization.diff | 231 |
1 files changed, 231 insertions, 0 deletions
diff --git a/debian/uncrustify-trinity/uncrustify-trinity-0.75.0/debian/patches/002_trinity_customization.diff b/debian/uncrustify-trinity/uncrustify-trinity-0.75.0/debian/patches/002_trinity_customization.diff new file mode 100644 index 00000000..c447cc39 --- /dev/null +++ b/debian/uncrustify-trinity/uncrustify-trinity-0.75.0/debian/patches/002_trinity_customization.diff @@ -0,0 +1,231 @@ +Customize and repackage as a TDE package. +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -1,6 +1,6 @@ + cmake_minimum_required(VERSION 3.2) + +-project(uncrustify) ++project(uncrustify-trinity) + + if("${PROJECT_SOURCE_DIR}" STREQUAL "${PROJECT_BINARY_DIR}") + message(FATAL_ERROR " +@@ -239,7 +239,7 @@ + # + # Uncrustify + # +-set(uncrustify_sources ++set(uncrustify-trinity_sources + src/align_add.cpp + src/align_asm_colon.cpp + src/align_assign.cpp +@@ -325,7 +325,7 @@ + ${PROJECT_BINARY_DIR}/src/option_enum.cpp + ) + +-set(uncrustify_headers ++set(uncrustify-trinity_headers + src/add_space_table.h + src/align_add.h + src/align_asm_colon.h +@@ -421,7 +421,7 @@ + ${PROJECT_BINARY_DIR}/uncrustify_version.h + ) + +-set(uncrustify_docs ++set(uncrustify-trinity_docs + "${PROJECT_SOURCE_DIR}/AUTHORS" + "${PROJECT_SOURCE_DIR}/BUGS" + "${PROJECT_SOURCE_DIR}/ChangeLog" +@@ -430,31 +430,31 @@ + "${PROJECT_SOURCE_DIR}/README.md" + ) + +-add_executable(uncrustify ${uncrustify_sources} ${uncrustify_headers}) +-add_dependencies(uncrustify generate_version_header) ++add_executable(uncrustify-trinity ${uncrustify-trinity_sources} ${uncrustify-trinity_headers}) ++add_dependencies(uncrustify-trinity generate_version_header) + + if(CMAKE_VERSION VERSION_LESS 2.8.10) + if(CMAKE_CONFIGURATION_TYPES OR CMAKE_BUILD_TYPE) + # Multi-configuration or build type set +- set_property(TARGET uncrustify APPEND PROPERTY ++ set_property(TARGET uncrustify-trinity APPEND PROPERTY + COMPILE_DEFINITIONS_DEBUG DEBUG + ) + else() + # Single-configuration with no build type set +- set_property(TARGET uncrustify APPEND PROPERTY ++ set_property(TARGET uncrustify-trinity APPEND PROPERTY + COMPILE_DEFINITIONS DEBUG + ) + endif() + else() +- set_property(TARGET uncrustify APPEND PROPERTY ++ set_property(TARGET uncrustify-trinity APPEND PROPERTY + COMPILE_DEFINITIONS $<$<OR:$<CONFIG:Debug>,$<CONFIG:>>:DEBUG> + ) + endif() + + # +-# Generate uncrustify.1 ++# Generate uncrustify-trinity.1 + # +-configure_file(man/uncrustify.1.in uncrustify.1 @ONLY) ++configure_file(man/uncrustify.1.in uncrustify-trinity.1 @ONLY) + + # + # Generate uncrustify.xml (katepart highlighting file) +@@ -476,7 +476,7 @@ + # + OPTION(ENABLE_CODECOVERAGE "Enable code coverage testing support") + if(ENABLE_CODECOVERAGE) +- set(CODECOVERAGE_DEPENDS uncrustify) ++ set(CODECOVERAGE_DEPENDS uncrustify-trinity) + include(${CMAKE_SOURCE_DIR}/cmake/CodeCoverage.cmake) + endif(ENABLE_CODECOVERAGE) + +@@ -484,10 +484,10 @@ + # Build command to run uncrustify on its own sources + # + add_custom_target(format-sources) +-foreach(source IN LISTS uncrustify_sources uncrustify_headers) ++foreach(source IN LISTS uncrustify-trinity_sources uncrustify-trinity_headers) + get_filename_component(source_name ${source} NAME) + add_custom_target(format-${source_name} +- COMMAND uncrustify ++ COMMAND uncrustify-trinity + -c forUncrustifySources.cfg + -lCPP --no-backup ${source} + COMMENT "Formatting ${source}" +@@ -499,7 +499,7 @@ + # + # Package + # +-set(CPACK_PACKAGE_NAME "uncrustify") ++set(CPACK_PACKAGE_NAME "uncrustify-trinity") + set(CPACK_PACKAGE_VERSION "${UNCRUSTIFY_VERSION}") + set(CPACK_PACKAGE_VENDOR "Ben Gardner") + set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "Code beautifier") +@@ -517,8 +517,8 @@ + # Install + # + if(MSVC) +- install(TARGETS uncrustify DESTINATION ".") +- install(FILES ${uncrustify_docs} ++ install(TARGETS uncrustify-trinity DESTINATION ".") ++ install(FILES ${uncrustify-trinity_docs} + DESTINATION "." + ) + install(FILES "${PROJECT_SOURCE_DIR}/documentation/htdocs/index.html" +@@ -530,17 +530,17 @@ + ) + else() + include(GNUInstallDirs) +- install(TARGETS uncrustify ++ install(TARGETS uncrustify-trinity + RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" + ) +- install(FILES "${CMAKE_CURRENT_BINARY_DIR}/uncrustify.1" ++ install(FILES "${CMAKE_CURRENT_BINARY_DIR}/uncrustify-trinity.1" + DESTINATION "${CMAKE_INSTALL_MANDIR}/man1" + ) + install(DIRECTORY "${PROJECT_SOURCE_DIR}/etc/" + DESTINATION "${CMAKE_INSTALL_DOCDIR}/examples" + FILES_MATCHING PATTERN "*.cfg" + ) +- install(FILES ${uncrustify_docs} ++ install(FILES ${uncrustify-trinity_docs} + DESTINATION "${CMAKE_INSTALL_DOCDIR}" + ) + endif() +--- a/tests/CMakeLists.txt ++++ b/tests/CMakeLists.txt +@@ -32,7 +32,7 @@ + add_custom_command( + OUTPUT ${tests_ctest_file} + COMMAND ${PYTHON_EXECUTABLE} run_format_tests.py +- --executable $<TARGET_FILE:uncrustify> ++ --executable $<TARGET_FILE:uncrustify-trinity> + --git ${GIT_EXECUTABLE} + --python ${PYTHON_EXECUTABLE} + --write-ctest ${tests_ctest_file} +@@ -48,7 +48,7 @@ + string(REPLACE ".test" "" lang "${suite}") + add_test(NAME ${lang} + COMMAND ${PYTHON_EXECUTABLE} run_format_tests.py ${lang} +- --executable $<TARGET_FILE:uncrustify> ++ --executable $<TARGET_FILE:uncrustify-trinity> + -d --git ${GIT_EXECUTABLE} + --result-dir ${CMAKE_CURRENT_BINARY_DIR} + WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} +@@ -60,7 +60,7 @@ + add_test( + NAME sources_format + COMMAND ${PYTHON_EXECUTABLE} run_sources_tests.py +- --executable $<TARGET_FILE:uncrustify> ++ --executable $<TARGET_FILE:uncrustify-trinity> + -d --git ${GIT_EXECUTABLE} + --result-dir ${CMAKE_CURRENT_BINARY_DIR} + WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} +@@ -72,7 +72,7 @@ + COMMAND ${PYTHON_EXECUTABLE} + test_cli_options.py + --config $<CONFIG> +- --build ${uncrustify_BINARY_DIR} ++ --build ${uncrustify-trinity_BINARY_DIR} + --diff + --test ${CMAKE_CURRENT_BINARY_DIR}/cli + ${_configs} +@@ -83,11 +83,11 @@ + COMMAND ${PYTHON_EXECUTABLE} + test_cli_options.py + --config $<CONFIG> +- --build ${uncrustify_BINARY_DIR} ++ --build ${uncrustify-trinity_BINARY_DIR} + --apply + --test ${CMAKE_CURRENT_BINARY_DIR}/cli +- DEPENDS uncrustify ++ DEPENDS uncrustify-trinity + WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/cli + ) + +-add_test(NAME sanity COMMAND uncrustify --help) ++add_test(NAME sanity COMMAND uncrustify-trinity --help) +--- a/tests/cli/output/help.txt ++++ b/tests/cli/output/help.txt +@@ -1,5 +1,5 @@ + Usage: +-uncrustify [options] [files ...] ++uncrustify-trinity [options] [files ...] + + If no input files are specified, the input is read from stdin + If reading from stdin, you should specify the language using -l +--- a/tests/cli/test_cli_options.py ++++ b/tests/cli/test_cli_options.py +@@ -492,16 +492,16 @@ + bd_dir = parsed_args.build + test_dir = parsed_args.test + +- bin_paths = [s_path_join(bd_dir, 'uncrustify'), +- s_path_join(bd_dir, 'uncrustify.exe'), +- s_path_join(bd_dir, 'Debug/uncrustify'), +- s_path_join(bd_dir, 'Debug/uncrustify.exe'), +- s_path_join(bd_dir, 'Release/uncrustify'), +- s_path_join(bd_dir, 'Release/uncrustify.exe'), +- s_path_join(bd_dir, 'RelWithDebInfo/uncrustify'), +- s_path_join(bd_dir, 'RelWithDebInfo/uncrustify.exe'), +- s_path_join(bd_dir, 'MinSizeRel/uncrustify'), +- s_path_join(bd_dir, 'MinSizeRel/uncrustify.exe')] ++ bin_paths = [s_path_join(bd_dir, 'uncrustify-trinity'), ++ s_path_join(bd_dir, 'uncrustify-trinity.exe'), ++ s_path_join(bd_dir, 'Debug/uncrustify-trinity'), ++ s_path_join(bd_dir, 'Debug/uncrustify-trinity.exe'), ++ s_path_join(bd_dir, 'Release/uncrustify-trinity'), ++ s_path_join(bd_dir, 'Release/uncrustify-trinity.exe'), ++ s_path_join(bd_dir, 'RelWithDebInfo/uncrustify-trinity'), ++ s_path_join(bd_dir, 'RelWithDebInfo/uncrustify-trinity.exe'), ++ s_path_join(bd_dir, 'MinSizeRel/uncrustify-trinity'), ++ s_path_join(bd_dir, 'MinSizeRel/uncrustify-trinity.exe')] + for uncr_bin in bin_paths: + if not isfile(uncr_bin): + eprint("is not a file: %s" % uncr_bin) |