Commit ae60a038 authored by Astro's avatar Astro
Browse files

openocd: use card10-scripts

parent 6832940c
Pipeline #1079 failed with stage
in 24 seconds
......@@ -16,16 +16,25 @@ let
];
enableParallelBuilding = true;
});
card10-scripts = stdenv.mkDerivation {
name = "card10-scripts";
src = ./c/openocd/scripts;
dontBuild = true;
installPhase = ''
mkdir -p $out/share/openocd
cp -ar . $out/share/openocd/scripts
'';
};
in
stdenv.mkDerivation {
name = "openocd-card10";
src = maxim-openocd;
phases = [ "unpackPhase" "installPhase" ];
buildInputs = [ maxim-openocd makeWrapper ];
buildInputs = [ makeWrapper maxim-openocd card10-scripts ];
installPhase = ''
mkdir -p $out/bin
makeWrapper ${maxim-openocd}/bin/openocd $out/bin/openocd-card10 \
--add-flags "-f ${maxim-openocd}/share/openocd/scripts/interface/cmsis-dap.cfg" \
--add-flags "-f ${maxim-openocd}/share/openocd/scripts/target/max32665.cfg"
--add-flags "-f ${card10-scripts}/share/openocd/scripts/interface/cmsis-dap.cfg" \
--add-flags "-f ${card10-scripts}/share/openocd/scripts/target/max32665.cfg"
'';
}
......@@ -21,6 +21,6 @@ stdenv.mkDerivation {
# Let openocd output scroll by
sleep 1
echo "Run 'cargo run --release'"
echo "Run 'cargo run --release watchapp'"
'';
}
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment