mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-11-21 10:55:51 +02:00
compat/cuda/ptx2c: strip CR from each line
Windows nvcc + cl.exe produce a .ctx file with CR+LF newlines which need to be stripped to work with gcc. Signed-off-by: Timo Rothenpieler <timo@rothenpieler.org>
This commit is contained in:
parent
1ac03c8dc0
commit
7fbc082577
@ -29,7 +29,7 @@ NAME="$(basename "$IN" | sed 's/\..*//')"
|
||||
printf "const char %s_ptx[] = \\" "$NAME" > "$OUT"
|
||||
while read LINE
|
||||
do
|
||||
printf "\n\t\"%s\\\n\"" "$(printf "%s" "$LINE" | sed 's/["\\]/\\&/g')" >> "$OUT"
|
||||
printf "\n\t\"%s\\\n\"" "$(printf "%s" "$LINE" | sed -e 's/\r//g' -e 's/["\\]/\\&/g')" >> "$OUT"
|
||||
done < "$IN"
|
||||
printf ";\n" >> "$OUT"
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user