SWDEV-283266 - Fix hipRTC mcin missing symbol

Add back the .type directive needed for ELF
format to add the section to symbol table.
For COFF format the symbol is already added
to the symbol table.

Change-Id: I4920e8dae0af23b4dcabd324b47abc228fcab10f


[ROCm/clr commit: 561310c6d6]
这个提交包含在:
Aaron En Ye Shi 于 2021-05-20 20:24:55 +00:00 提交
1 父节点 2991b08b29
当前提交 2fdac08d13
1 个文件已更改
+10 -2
+10 -2
查看文件
@@ -71,8 +71,10 @@ else
fi
if [[ "$OSTYPE" == cygwin || "$OSTYPE" == msys ]]; then
isWindows=1
tmpdir=.
else
isWindows=0
tmpdir=/tmp
fi
@@ -132,13 +134,19 @@ EOF
generate_rtc_header() {
tmp=$tmpdir/hip_rtc.$$
mkdir -p $tmp
local headerFile="$tmp/hipRTC_header.h"
local mcinFile="$tmp/hipRTC_header.mcin"
cat >$tmp/hipRTC_header.h <<EOF
cat >$headerFile <<EOF
#include "hip/hip_runtime.h"
#include "hip/hip_fp16.h"
EOF
cat >$tmp/hipRTC_header.mcin <<EOF
echo "// Automatically generated script for HIP RTC." > $mcinFile
if [[ $isWindows -eq 0 ]]; then
echo " .type __hipRTC_header,@object" >> $mcinFile
fi
cat >>$mcinFile <<EOF
.section .hipRTC_header,"a"
.globl __hipRTC_header
.globl __hipRTC_header_size