gnu: python-vunit: Fix unbundle dependencies.

* gnu/packages/electronics.scm (python-vunit)[arguments]: Remove
dosymlink;  add unbundle and run-examples #:phases.

Change-Id: I088bffa95775a62045c5c6fecb1cf4a47ccda2f8
Signed-off-by: Gabriel Wicki <gabriel@erlikon.ch>
This commit is contained in:
Cayetano Santos 2025-09-21 18:50:56 +02:00 committed by Gabriel Wicki
parent b16cacec26
commit 90fcaa261f
No known key found for this signature in database
GPG key ID: CC98E9F04330FD7F

View file

@ -1737,17 +1737,28 @@ to enforce it.")
(string-append
": \"llvm\",\n\tr\"static elaboration, LLVM JIT code "
"generator\": \"llvm-jit\",")))))
(add-after 'ensure-no-mtimes-pre-1980 'dosymlink
(lambda* (#:key inputs #:allow-other-keys)
(with-directory-excursion "vunit/vhdl/JSON-for-VHDL"
(add-after 'install 'unbundle
(lambda* (#:key inputs outputs #:allow-other-keys)
(let ((site-packages
(string-append (site-packages inputs outputs)
"/vunit/vhdl/")))
(mkdir-p (string-append site-packages "JSON-for-VHDL"))
(symlink
(search-input-directory inputs "/share/json-for-vhdl")
"src"))
(with-directory-excursion "vunit/vhdl"
(delete-file-recursively "osvvm")
(search-input-directory inputs "share/json-for-vhdl")
(string-append site-packages "JSON-for-VHDL/src"))
(symlink
(search-input-directory inputs "/share/osvvm/osvvm")
"osvvm")))))
(search-input-directory inputs "share/osvvm/osvvm")
(string-append site-packages "osvvm")))))
(add-after 'check 'run-examples
;; Run examples as an extra check.
(lambda* (#:key inputs outputs #:allow-other-keys)
(with-directory-excursion "examples/vhdl"
(for-each
(lambda (dir)
(invoke "python3" (string-append dir "/run.py")))
(list
"array" "check" "composite_generics" "json4vhdl" "logging"
"logging" "uart" "vhdl_configuration"))))))
#:test-flags
;; Skip lint tests which require python-pycodestyle, python-pylint and
;; python-mypy to reduce closoure size; some lint test fails, see