diff options
author | SangYoun Kwak <sy.kwak@samsung.com> | 2024-05-20 15:20:44 +0900 |
---|---|---|
committer | SangYoun Kwak <sy.kwak@samsung.com> | 2024-05-27 13:56:46 +0900 |
commit | 5fac85345952e9bbc0b7e9a9e1f8cce70dfcd89b (patch) | |
tree | 91b6ab58795efdbaa092e2034b2eaafa330e75db | |
parent | d24a2c219070cdba27b3d1621c928bdcf17462df (diff) | |
download | rootstrap-data-common-5fac85345952e9bbc0b7e9a9e1f8cce70dfcd89b.tar.gz rootstrap-data-common-5fac85345952e9bbc0b7e9a9e1f8cce70dfcd89b.tar.bz2 rootstrap-data-common-5fac85345952e9bbc0b7e9a9e1f8cce70dfcd89b.zip |
Add file_32, file_64 to <necessary> of .xml files
To distinguish 32-bit only files and 64-bit only files, file_32 and
file_64 are added to the <necessary> section of .xml files(glibc, glib2)
Also, these sections should not be modified by convert32.sh and
convert64.sh scripts, these scripts are modified not to manipulate the
file_32 and file_64 sections.
Since file_32 is only for 32-bit build and file_64 is only for 64-bit
build, the rootstrap generation scripts is also modified.
Change-Id: I4a67918986ad9925f369a36fe60926c07d6c04f7
Signed-off-by: SangYoun Kwak <sy.kwak@samsung.com>
-rw-r--r-- | packaging/hal-rootstrap.spec | 1 | ||||
-rw-r--r-- | rs_resource/OSS/baserpm/glibc-rs.xml | 20 | ||||
-rw-r--r-- | rs_resource/OSS/glib2-rs.xml | 8 | ||||
-rwxr-xr-x | script/convert32.sh | 1 | ||||
-rwxr-xr-x | script/convert64.sh | 3 | ||||
-rwxr-xr-x | script/rootstrap_gen_1.0.sh | 7 | ||||
-rwxr-xr-x | script/rootstrap_gen_1.0_64.sh | 7 |
7 files changed, 30 insertions, 17 deletions
diff --git a/packaging/hal-rootstrap.spec b/packaging/hal-rootstrap.spec index 09e6902..bd085d3 100644 --- a/packaging/hal-rootstrap.spec +++ b/packaging/hal-rootstrap.spec @@ -439,6 +439,7 @@ cp packaging/hal-rootstrap.pc %{buildroot}%{_libdir}/pkgconfig/ %files %{hal_rootstrap_install_path}/etc/* +%{hal_rootstrap_install_path}/lib/* %{hal_rootstrap_install_path}/%{_lib}/* %{hal_rootstrap_install_path}/usr/share/* %{hal_rootstrap_install_path}/%{_libdir}/* diff --git a/rs_resource/OSS/baserpm/glibc-rs.xml b/rs_resource/OSS/baserpm/glibc-rs.xml index 8901c1b..26bbec6 100644 --- a/rs_resource/OSS/baserpm/glibc-rs.xml +++ b/rs_resource/OSS/baserpm/glibc-rs.xml @@ -20,11 +20,10 @@ <rpm accept="glibc-locale" arch="armv7l"/> <rpm accept="glibc-profile" arch="armv7l"/> </target> + <necessary> <file>/etc/ld.so.conf</file> <file>/lib/ld-2.30.so</file> - <file>/lib/ld-linux.so.3</file> - <file>/lib/ld-linux-aarch64.so.1</file> <file>/lib/libanl-2.30.so</file> <file>/lib/libanl.so.1</file> <file>/lib/libBrokenLocale-2.30.so</file> @@ -66,7 +65,6 @@ <file>/lib/libthread_db.so.1</file> <file>/lib/libutil-2.30.so</file> <file>/lib/libutil.so.1</file> - <file>/lib/ld-linux-aarch64.so.1</file> <file>/usr/include/aio.h</file> <file>/usr/include/aliases.h</file> <file>/usr/include/alloca.h</file> @@ -313,11 +311,7 @@ <file>/usr/include/glob.h</file> <file>/usr/include/gnu/libc-version.h</file> <file>/usr/include/gnu/lib-names.h</file> - <file>/usr/include/gnu/lib-names-soft.h</file> - <file>/usr/include/gnu/lib-names-lp64.h</file> <file>/usr/include/gnu/stubs.h</file> - <file>/usr/include/gnu/stubs-soft.h</file> - <file>/usr/include/gnu/stubs-lp64.h</file> <file>/usr/include/gnu-versions.h</file> <file>/usr/include/grp.h</file> <file>/usr/include/gshadow.h</file> @@ -471,7 +465,6 @@ <file>/usr/include/sys/fsuid.h</file> <file>/usr/include/sys/gmon.h</file> <file>/usr/include/sys/gmon_out.h</file> - <file>/usr/include/sys/ifunc.h</file> <file>/usr/include/sys/inotify.h</file> <file>/usr/include/sys/ioctl.h</file> <file>/usr/include/sys/ipc.h</file> @@ -859,7 +852,18 @@ <file>/usr/lib/libutil.so</file> <file>/usr/lib/Mcrt1.o</file> <file>/usr/lib/Scrt1.o</file> + + <file_32>/lib/ld-linux.so.3</file_32> + <file_32>/usr/include/gnu/lib-names-soft.h</file_32> + <file_32>/usr/include/gnu/stubs-soft.h</file_32> + + <file_64>/lib64/ld-linux-aarch64.so.1</file_64> + <file_64>/lib/ld-linux-aarch64.so.1</file_64> + <file_64>/usr/include/gnu/lib-names-lp64.h</file_64> + <file_64>/usr/include/gnu/stubs-lp64.h</file_64> + <file_64>/usr/include/sys/ifunc.h$</file_64> </necessary> + <unnecessary> </unnecessary> <include_path>/usr/include</include_path> diff --git a/rs_resource/OSS/glib2-rs.xml b/rs_resource/OSS/glib2-rs.xml index 92e02a0..313f017 100644 --- a/rs_resource/OSS/glib2-rs.xml +++ b/rs_resource/OSS/glib2-rs.xml @@ -334,8 +334,12 @@ <file>/usr/lib/libgthread-2.0.so</file> <file>/usr/lib/libgthread-2.0.so.0</file> <file>/usr/lib/libgthread-2.0.so.0.7800.4</file> - <file>/usr/share/gdb/auto-load/usr/lib/libglib-2.0.so.0.7800.4-gdb.py</file> - <file>/usr/share/gdb/auto-load/usr/lib/libgobject-2.0.so.0.7800.4-gdb.py</file> + + <file_32>/usr/share/gdb/auto-load/usr/lib/libglib-2.0.so.0.7800.4-gdb.py</file_32> + <file_32>/usr/share/gdb/auto-load/usr/lib/libgobject-2.0.so.0.7800.4-gdb.py</file_32> + + <file_64>/usr/share/gdb/auto-load/usr/lib64/libglib-2.0.so.0.7800.4-gdb.py</file_64> + <file_64>/usr/share/gdb/auto-load/usr/lib64/libgobject-2.0.so.0.7800.4-gdb.py</file_64> </necessary> <include_path>/usr/include/gio-unix-2.0</include_path> diff --git a/script/convert32.sh b/script/convert32.sh index cebb9d1..644e2ab 100755 --- a/script/convert32.sh +++ b/script/convert32.sh @@ -6,7 +6,6 @@ find ./ \( -name "*-rs.xml" ! -iname "setup-rs.xml" \) \ -exec xmlstarlet ed -L -u //rootstrap/target/rpm/@arch -v "armv7l" {} \; \ -exec xmlstarlet ed -L -u //rootstrap/library_path -v "/usr/lib" {} \; \ -exec sed -i "s@<file>/usr/lib64/@<file>/usr/lib/@" {} \; \ --exec sed -i "s@<file>/usr/share/gdb/auto-load/usr/lib64/@<file>/usr/share/gdb/auto-load/usr/lib/@" {} \; \ -exec sed -i "s@<file>/lib64/@<file>/lib32/@" {} \; \ -exec sed -i "s@<include_path>/usr/lib64/@<include_path>/usr/lib32/@" {} \; diff --git a/script/convert64.sh b/script/convert64.sh index de8b286..548926e 100755 --- a/script/convert64.sh +++ b/script/convert64.sh @@ -6,7 +6,6 @@ find ./ \( -name "*-rs.xml" ! -iname "setup-rs.xml" \) \ -exec xmlstarlet ed -L -u //rootstrap/target/rpm/@arch -v "aarch64" {} \; \ -exec xmlstarlet ed -L -u //rootstrap/library_path -v "/usr/lib64" {} \; \ -exec sed -i "s@<file>/usr/lib/@<file>/usr/lib64/@" {} \; \ --exec sed -i "s@<file>/usr/share/gdb/auto-load/usr/lib/@<file>/usr/share/gdb/auto-load/usr/lib64/@" {} \; \ -exec sed -i "s@<file>/lib/@<file>/lib64/@" {} \; \ -exec sed -i "s@<include_path>/usr/lib/@<include_path>/usr/lib64/@" {} \; @@ -26,7 +25,7 @@ sed -i "s@SNAPSHOT_URL_POSTFIX_TARGET=.*@SNAPSHOT_URL_POSTFIX_TARGET=\"${SNAPSHO # Post Script #git checkout ./make_rootstrap_64.sh #sed -i "s/asm-arm/asm-arm64/g" make_rootstrap_64.sh -sed -i "s/asm-x86/asm-ia64/g" make_rootstrap_64.sh +#sed -i "s/asm-x86/asm-ia64/g" make_rootstrap_64.sh #git checkout ./script/rootstrap_gen_1.0_64.sh #POSTLINKER_PATH=${PWD_BACKUP}"/script/postlinker" diff --git a/script/rootstrap_gen_1.0.sh b/script/rootstrap_gen_1.0.sh index e868a74..4b08ad7 100755 --- a/script/rootstrap_gen_1.0.sh +++ b/script/rootstrap_gen_1.0.sh @@ -182,8 +182,9 @@ function copy_header_and_so() local dest_dir=$2 local xml_file=$3 local copy_error=0 - local files=() local dest_path="" + local -a files + local -a necessary_files log "***************** $FUNCNAME *****************" ALL=$(xmlstarlet sel -t -m "//necessary[count(file)=1]" -v "./file/text()" ${xml_file}) @@ -196,7 +197,9 @@ function copy_header_and_so() return 1 else log "+ copy necessary files .." - for i in $(xmlstarlet sel -t -m "//necessary/file" -o "." -v "text()" -o " " -n ${xml_file}); do + necessary_files=($(xmlstarlet sel -t -m "//necessary/file" -o "." -v "text()" -o " " -n ${xml_file})) + necessary_files+=($(xmlstarlet sel -t -m "//necessary/file_32" -o "." -v "text()" -o " " -n ${xml_file})) + for i in ${necessary_files[@]}; do cd ${src_dir} log "+ copy file from [${i}]" files=($(ls ${i})) diff --git a/script/rootstrap_gen_1.0_64.sh b/script/rootstrap_gen_1.0_64.sh index 49fc024..c6bcb10 100755 --- a/script/rootstrap_gen_1.0_64.sh +++ b/script/rootstrap_gen_1.0_64.sh @@ -182,8 +182,9 @@ function copy_header_and_so() local dest_dir=$2 local xml_file=$3 local copy_error=0 - local files=() local dest_path="" + local -a files + local -a necessary_files log "***************** $FUNCNAME *****************" ALL=$(xmlstarlet sel -t -m "//necessary[count(file)=1]" -v "./file/text()" ${xml_file}) @@ -196,7 +197,9 @@ function copy_header_and_so() return 1 else log "+ copy necessary files .." - for i in $(xmlstarlet sel -t -m "//necessary/file" -o "." -v "text()" -o " " -n ${xml_file}); do + necessary_files=($(xmlstarlet sel -t -m "//necessary/file" -o "." -v "text()" -o " " -n ${xml_file})) + necessary_files+=($(xmlstarlet sel -t -m "//necessary/file_64" -o "." -v "text()" -o " " -n ${xml_file})) + for i in ${necessary_files[@]}; do cd ${src_dir} log "+ copy file from [${i}]" files=($(ls ${i})) |