RTEMS Source Builder | Draft: rtems/config/tools: Add checks to stdcxx.py install script (!48)

Frank Kuehndel (@frank_k) gitlab at rtems.org
Tue Aug 20 09:52:03 UTC 2024




Frank Kuehndel started a new discussion on rtems/config/tools/rtems-install-stdcxx.cfg: https://gitlab.rtems.org/rtems/tools/rtems-source-builder/-/merge_requests/48#note_111341

 > +# macro defined in the GCC newlib file.
 > +%define rsb_rtems_gcc_version %( \
 > +  if [ -x %{_bindir}/%{_target}-gcc ]; then \
 > +    %{_bindir}/%{_target}-gcc --version | head -1 | awk '{print $3}'; \
 > +  else \
 > +    echo %{gcc_version}; \
 > +  fi \
 > +)
 >  
 > -# Path to the target location of the script: gdb/python
 > -%define stdcxx_script %{_prefix}/share/gdb/python/rtems/stdcxx.py
 > +# Path to the target location of the script: gdb/python/rtems 
 > +%define stdcxx_script_path %{_prefix}/share/gdb/python/rtems
 > +
 > +# Check if the install directory exists. If not, create it 
 > +%([ -d %{stdcxx_script_path} ] || mkdir -p %{stdcxx_script_path})

1. You do not need to check whether the directory exist. `mkdir -p` will not fail if it exist.

2. RSB has options not to install anything (e.g. to only build packages). Does `mkdir -p %{stdcxx_script_path}` create something on the users machine even if RSB is told to install nothing?

-- 
View it on GitLab: https://gitlab.rtems.org/rtems/tools/rtems-source-builder/-/merge_requests/48#note_111341
You're receiving this email because of your account on gitlab.rtems.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/bugs/attachments/20240820/5eedc3a6/attachment-0001.htm>


More information about the bugs mailing list