11 stdenv.mkDerivation rec {
14 # `git describe --always`
15 firmwareVersion = "v${version}";
17 src = fetchFromGitHub {
18 owner = "blacksphere";
20 rev = firmwareVersion;
21 hash = "sha256-NGzoohmpVwGOncr9AvHYANMf/oEskjmTXYj/Kdx2RwM=";
22 fetchSubmodules = true;
40 # Prevent calling out to `git' to generate a version number:
41 substituteInPlace src/Makefile \
42 --replace '$(shell git describe --always --dirty)' '${firmwareVersion}'
44 # Fix scripts that generate headers:
45 for f in $(find scripts libopencm3/scripts -type f); do
52 ${stdenv.shell} ${./helper.sh}
58 enableParallelBuilding = true;
61 description = "In-application debugger for ARM Cortex microcontrollers";
62 mainProgram = "blackmagic";
64 The Black Magic Probe is a modern, in-application debugging tool
65 for embedded microprocessors. It allows you to see what is going
66 on "inside" an application running on an embedded microprocessor
69 This package builds the firmware for all supported platforms,
70 placing them in separate directories under the firmware
71 directory. It also places the FTDI version of the blackmagic
72 executable in the bin directory.
74 homepage = "https://github.com/blacksphere/blackmagic";
75 license = licenses.gpl3Plus;
76 maintainers = with maintainers; [ pjones sorki ];
77 platforms = platforms.unix;