[oe-commits] [meta-openembedded] 72/77: dos2unix.bbclass: add recipe

git at git.openembedded.org git at git.openembedded.org
Mon Jun 12 07:12:30 UTC 2017


This is an automated email from the git hooks/post-receive script.

martin_jansa pushed a commit to branch master-next
in repository meta-openembedded.

commit 69e3640ff08b0a11dadbf932a860d93a320d4f14
Author: Ming Liu <peter.x.liu at external.atlascopco.com>
AuthorDate: Sun Jun 11 14:54:20 2017 +0200

    dos2unix.bbclass: add recipe
    
    Class for use to convert all CRLF line terminators to LF provided
    that some projects are being developed/maintained on Windows so they
    have different line terminators(CRLF) vs on Linux(LF), which can
    cause annoying patching errors during git push/checkout processes.
    
    Signed-off-by: Ming Liu <peter.x.liu at external.atlascopco.com>
    Signed-off-by: Martin Jansa <Martin.Jansa at gmail.com>
---
 meta-oe/classes/dos2unix.bbclass | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/meta-oe/classes/dos2unix.bbclass b/meta-oe/classes/dos2unix.bbclass
new file mode 100644
index 0000000..1bad998
--- /dev/null
+++ b/meta-oe/classes/dos2unix.bbclass
@@ -0,0 +1,14 @@
+# Class for use to convert all CRLF line terminators to LF
+# provided that some projects are being developed/maintained
+# on Windows so they have different line terminators(CRLF) vs
+# on Linux(LF), which can cause annoying patching errors during
+# git push/checkout processes.
+
+do_convert_crlf_to_lf[depends] += "dos2unix-native:do_populate_sysroot"
+
+# Convert CRLF line terminators to LF
+do_convert_crlf_to_lf () {
+    find ${S} -type f -exec dos2unix {} \;
+}
+
+addtask convert_crlf_to_lf after do_unpack before do_patch

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Openembedded-commits mailing list