)]}'
{
  "commit": "dc4e1fde36d7eb1a5ae2064b3ec545b1b0fcee8a",
  "tree": "b4496b7208674f7e39c00a8c2b69bda7b44b29c3",
  "parents": [
    "e7e980c6fa1205495ec66741da916f0b25941963"
  ],
  "author": {
    "name": "Hans-Peter Nilsson",
    "email": "hp@axis.com",
    "time": "Mon Feb 14 23:51:07 2022 +0100"
  },
  "committer": {
    "name": "Hans-Peter Nilsson",
    "email": "hp@bitrange.com",
    "time": "Mon Feb 14 23:51:07 2022 +0100"
  },
  "message": "sim: Fix use of out-of-tree assembler and linker when testing\n\nWith commit 7a259895bb2d \"sim: testsuite: expand arch specific\ntoolchain settings\", trying to use out-of-tree ld and as at test-time\nbroke for the \"primary target\", like when testing a release-tarball.\n\nSubsequent to that commit, all assembler tests without in-tree-built\ntools FAIL, getting errors when trying to call\n$(abs_builddir)/../gas/as-new.  But, that isn\u0027t the actual culprint;\nit\u0027s actually it\u0027s its immediate predecessor, commit 8996c21067373\n\"sim: testsuite: setup per-port toolchain settings for multitarget\nbuild\", which hardcodes in-tree-paths to those tools instead of\nconsidering e.g. $(\u003cX\u003e_FOR_TARGET), the preferred overridable variable\nfor single-target builds, as set up by the toplevel Makefile.\n\nThis commit calls GCC_TARGET_TOOL (a deceptive name; gcc-specific\nfeatures aren\u0027t used) from toplev/config/acx.m4, somewhat like calls\nin toplev/configure.ac but without the NCN_STRICT_CHECK_TARGET_TOOLS\nstep, for each X to find a value for $(\u003cX\u003e_FOR_TARGET).  N.B.: in-tree\ntools still override any ${target}-${tool} found in $PATH, i.e. only\npreviously broken builds are affected.\n\nThe variables $(\u003cX\u003e_FOR_TARGET) are usually overridden by the toplevel\nMakefile to the same value or better, but has to be set here too, as\nautomake \"wants\" Makefiles to be self-contained (you get an error\npointing out that the variable may be empty).  If it hadn\u0027t been for\nthat, SIM_AC_CHECK_TOOLCHAIN_FOR_PRIMARY_TARGET would not be needed.\nThis detail should only (positively) affect users invoking \"make\ncheck\" in sim/ instead of \"make check-sim\" (or \"make check\") at the\ntoplevel.  Now the output from \"configure\" matches the target tools\nactually used by sim at test-time, for the \"primary target\".\n\nUsing $(CC) for \"example-\" targets CC_FOR_TARGET is not changed, as\nthat appears to be a deliberate special-case.\n\nNote that all tools still have to be installed and present in\n$PATH at configure-time to be properly used at test-time.\n\nsim:\n\t* m4/sim_ac_toolchain.m4 (SIM_AC_CHECK_TOOLCHAIN_FOR_PRIMARY_TARGET):\n\tNew defun.\n\t(SIM_TOOLCHAIN_VARS): Call it using AC_REQUIRE, and use variables\n\tAS_FOR_TARGET, LD_FOR_TARGET and CC_FOR_TARGET instead of hard-coded\n\tvalues.\n\t* Makefile.in, configure: Regenerate.\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "8b208e0344302653feefaf566808fc4768ad2f62",
      "old_mode": 33188,
      "old_path": "sim/Makefile.in",
      "new_id": "49a3c0b80dbfca41a349b6030eaf440f8cf63c04",
      "new_mode": 33188,
      "new_path": "sim/Makefile.in"
    },
    {
      "type": "modify",
      "old_id": "51ac74a4ce45277e4a1eeeb68130782c9d6ba14b",
      "old_mode": 33261,
      "old_path": "sim/configure",
      "new_id": "019c2f41cf4227c23477f74a809ce05cc0d2290b",
      "new_mode": 33261,
      "new_path": "sim/configure"
    },
    {
      "type": "modify",
      "old_id": "09b8705c14b7e488f3edc16460f853c967d15f46",
      "old_mode": 33188,
      "old_path": "sim/m4/sim_ac_toolchain.m4",
      "new_id": "74532142929cce38990f7534a2b5a477e0f9178e",
      "new_mode": 33188,
      "new_path": "sim/m4/sim_ac_toolchain.m4"
    }
  ]
}
