Source: razorqt Version: 0.5.2-4 Severity: wishlist Tags: patch User: reproducible-bui...@lists.alioth.debian.org Usertags: locale X-Debbugs-Cc: reproducible-bui...@lists.alioth.debian.org
Hi! While working on the "reproducible builds" effort [1], we have noticed that razorqt could not be built reproducibly. While generating .desktop files, grep misdetects the input as binary data when a non-UTF8 locale is used. This leads to the embedding of lines like this into the files: "Binary file /build/razorqt-0.5.2/razorqt-resources/sys/translations/razor_zh_TW.desktop matches" The attached patch fixes this by telling grep to treat the input as text. Regards, Reiner [1]: https://wiki.debian.org/ReproducibleBuilds
diff --git a/debian/patches/series b/debian/patches/series index a7bfb4b..becb3b3 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -1,2 +1,3 @@ lightdm3.patch libstatgrab-0.90.patch +unicode-grep.patch diff --git a/debian/patches/unicode-grep.patch b/debian/patches/unicode-grep.patch new file mode 100644 index 0000000..7356279 --- /dev/null +++ b/debian/patches/unicode-grep.patch @@ -0,0 +1,22 @@ +Author: Reiner Herrmann <rei...@reiner-h.de> +Description: Fix misdetection as binary input when LC_ALL=C + +--- a/cmake/RazorTranslate.cmake ++++ b/cmake/RazorTranslate.cmake +@@ -238,13 +238,13 @@ + set(_pattern "'\\[.*]\\s*='") + if (_translations) + add_custom_command(OUTPUT ${_outFile} +- COMMAND grep -v "'#TRANSLATIONS_DIR='" ${_inFile} > ${_outFile} +- COMMAND grep --no-filename ${_pattern} ${_translations} >> ${_outFile} ++ COMMAND grep -a -v "'#TRANSLATIONS_DIR='" ${_inFile} > ${_outFile} ++ COMMAND grep -a --no-filename ${_pattern} ${_translations} >> ${_outFile} + COMMENT "Generating ${_fileName}${_fileExt}" + ) + else() + add_custom_command(OUTPUT ${_outFile} +- COMMAND grep -v "'#TRANSLATIONS_DIR='" ${_inFile} > ${_outFile} ++ COMMAND grep -a -v "'#TRANSLATIONS_DIR='" ${_inFile} > ${_outFile} + COMMENT "Generating ${_fileName}${_fileExt}" + ) + endif()
signature.asc
Description: PGP signature