gdb_riscv.bb 949 B

12345678910111213141516171819202122232425262728293031
  1. require recipes-devtools/gdb/gdb.inc
  2. require gdb-${PV}.inc
  3. DEPENDS += "bison-native"
  4. inherit python3-dir
  5. EXTRA_OEMAKE_append_libc-musl = "\
  6. gt_cv_func_gnugettext1_libc=yes \
  7. gt_cv_func_gnugettext2_libc=yes \
  8. gl_cv_func_gettimeofday_clobber=no \
  9. "
  10. do_configure_prepend() {
  11. if [ "${@bb.utils.filter('PACKAGECONFIG', 'python', d)}" ]; then
  12. cat > ${WORKDIR}/python << EOF
  13. #!/bin/sh
  14. case "\$2" in
  15. --includes) echo "-I${STAGING_INCDIR}/${PYTHON_DIR}${PYTHON_ABI}/" ;;
  16. --ldflags) echo "-Wl,-rpath-link,${STAGING_LIBDIR}/.. -Wl,-rpath,${libdir}/.. -lpthread -ldl -lutil -lm -lpython${PYTHON_BASEVERSION}${PYTHON_ABI}" ;;
  17. --exec-prefix) echo "${exec_prefix}" ;;
  18. *) exit 1 ;;
  19. esac
  20. exit 0
  21. EOF
  22. chmod +x ${WORKDIR}/python
  23. fi
  24. }
  25. CFLAGS_append_libc-musl = " -Drpl_gettimeofday=gettimeofday"
  26. ALLOW_EMPTY_gdbserver = "1"