diff options
Diffstat (limited to 'pkgs/os-specific/linux/firmware')
4 files changed, 62 insertions, 60 deletions
diff --git a/pkgs/os-specific/linux/firmware/firmware-linux-nonfree/default.nix b/pkgs/os-specific/linux/firmware/firmware-linux-nonfree/default.nix index acdba5987bbf..724498b960c0 100644 --- a/pkgs/os-specific/linux/firmware/firmware-linux-nonfree/default.nix +++ b/pkgs/os-specific/linux/firmware/firmware-linux-nonfree/default.nix @@ -2,51 +2,13 @@ stdenv.mkDerivation rec { name = "firmware-linux-nonfree-${version}"; - version = "2018-01-04-${src.iwlRev}"; + version = "2018-03-20"; - # The src runCommand automates the process of building a merged repository of both - # - # https://git.kernel.org/cgit/linux/kernel/git/firmware/linux-firmware.git/ - # https://git.kernel.org/cgit/linux/kernel/git/iwlwifi/linux-firmware.git/ - # - # This gives us up to date iwlwifi firmware as well as - # the usual set of firmware. firmware/linux-firmware usually lags kernel releases - # so iwlwifi cards will fail to load on newly released kernels. - # - # To update, go to the above repositories and look for latest tags / commits, then - # update version to the more recent commit date - - src = runCommand "firmware-linux-nonfree-src-merged-${version}" { - shallowSince = "2017-10-01"; - baseRev = "65b1c68c63f974d72610db38dfae49861117cae2"; - iwlRev = "iwlwifi-fw-2017-11-15"; - - # When updating this, you need to let it run with a wrong hash, in order to find out the desired hash - # randomly mutate the hash to break out of fixed hash, when updating - outputHash = "1anr7fblxfcrfrrgq98kzy64yrwygc2wdgi47skdmjxhi3wbrvxz"; - - outputHashAlgo = "sha256"; - outputHashMode = "recursive"; - - # Doing the download on a remote machine just duplicates network - # traffic, so don't do that. - preferLocalBuild = true; - - nativeBuildInputs = [ cacert git gnupg ]; - } '' - git init src && ( - cd src - git config user.email "build-daemon@nixos.org" - git config user.name "Nixos Build Daemon $name" - git remote add base https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git - git remote add iwl https://git.kernel.org/pub/scm/linux/kernel/git/iwlwifi/linux-firmware.git - git fetch --shallow-since=$shallowSince base - git fetch --shallow-since=$shallowSince iwl - git checkout -b work $baseRev - git merge $iwlRev) - rm -rf src/.git - cp -a src $out - ''; + src = fetchgit { + url = "https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git"; + rev = "8c1e439c967a50f0698d61aafdba3841aff10db0"; + sha256 = "110vxgahyx5dvylqrxsm5cmx4a32cl2zchvm6cgc270jz75fg7wd"; + }; preInstall = '' mkdir -p $out diff --git a/pkgs/os-specific/linux/firmware/raspberrypi/default.nix b/pkgs/os-specific/linux/firmware/raspberrypi/default.nix index c71f1c0ea2e9..d00f1b148374 100644 --- a/pkgs/os-specific/linux/firmware/raspberrypi/default.nix +++ b/pkgs/os-specific/linux/firmware/raspberrypi/default.nix @@ -2,36 +2,25 @@ stdenv.mkDerivation rec { name = "raspberrypi-firmware-${version}"; - version = "1.20171029"; + version = "1.20180328"; src = fetchFromGitHub { owner = "raspberrypi"; repo = "firmware"; rev = version; - sha256 = "12aisha8rlr28310hakps04z9p45kd2wvks0w1vxw1kwfh1ncy9s"; + sha256 = "19h4lv11idy268pyrq21c5gsff77d5xr9xjkpmzfpcq34gjh3x21"; }; - dontStrip = true; # Stripping breaks some of the binaries - installPhase = '' mkdir -p $out/share/raspberrypi/boot cp -R boot/* $out/share/raspberrypi/boot - cp -R hardfp/opt/vc/* $out - cp opt/vc/LICENCE $out/share/raspberrypi - - for f in $out/bin/*; do - if isELF "$f"; then - patchelf --set-interpreter "$(cat $NIX_CC/nix-support/dynamic-linker)" "$f" - patchelf --set-rpath "$out/lib" "$f" - fi - done ''; meta = with stdenv.lib; { description = "Firmware for the Raspberry Pi board"; - homepage = https://github.com/raspberrypi; - license = licenses.unfree; + homepage = https://github.com/raspberrypi/firmware; + license = licenses.unfreeRedistributableFirmware; # See https://github.com/raspberrypi/firmware/blob/master/boot/LICENCE.broadcom platforms = [ "armv6l-linux" "armv7l-linux" "aarch64-linux" ]; - maintainers = with maintainers; [ viric tavyc ]; + maintainers = with maintainers; [ dezgeg viric tavyc ]; }; } diff --git a/pkgs/os-specific/linux/firmware/raspberrypi/tools-dont-install-sysv-init-scripts.patch b/pkgs/os-specific/linux/firmware/raspberrypi/tools-dont-install-sysv-init-scripts.patch new file mode 100644 index 000000000000..e12aeeb0cdb8 --- /dev/null +++ b/pkgs/os-specific/linux/firmware/raspberrypi/tools-dont-install-sysv-init-scripts.patch @@ -0,0 +1,20 @@ +diff --git a/interface/vmcs_host/linux/vcfiled/CMakeLists.txt b/interface/vmcs_host/linux/vcfiled/CMakeLists.txt +index aed0e83..b325676 100644 +--- a/interface/vmcs_host/linux/vcfiled/CMakeLists.txt ++++ b/interface/vmcs_host/linux/vcfiled/CMakeLists.txt +@@ -17,15 +17,6 @@ target_link_libraries(vcfiled + install(TARGETS vcfiled + RUNTIME DESTINATION sbin) + +-configure_file (etc/init.d/vcfiled ${PROJECT_BINARY_DIR}/etc/init.d/vcfiled) +- +-# script to start up vcfiled at start of day +-install(PROGRAMS ${PROJECT_BINARY_DIR}/etc/init.d/vcfiled +- DESTINATION /etc/init.d) +-# install locally to the installation directory too +-install(PROGRAMS ${PROJECT_BINARY_DIR}/etc/init.d/vcfiled +- DESTINATION ${VMCS_INSTALL_PREFIX}/share/install) +- + # test program for vcfiled_check library + add_executable(vcfiled_lock_test vcfiled_lock_test.c) + target_link_libraries(vcfiled_lock_test vcfiled_check) diff --git a/pkgs/os-specific/linux/firmware/raspberrypi/tools.nix b/pkgs/os-specific/linux/firmware/raspberrypi/tools.nix new file mode 100644 index 000000000000..7f4c9dae166a --- /dev/null +++ b/pkgs/os-specific/linux/firmware/raspberrypi/tools.nix @@ -0,0 +1,31 @@ +{ stdenv, fetchFromGitHub, cmake, pkgconfig }: + +stdenv.mkDerivation rec { + name = "raspberrypi-tools-${version}"; + version = "2018-02-05"; + + src = fetchFromGitHub { + owner = "raspberrypi"; + repo = "userland"; + rev = "a343dcad1dae4e93f4bfb99496697e207f91027e"; + sha256 = "1z4qrwjb7x3a45mx978q8vyhnx068sgzhymm4z0ayhckji4ngal1"; + }; + + patches = [ ./tools-dont-install-sysv-init-scripts.patch ]; + + nativeBuildInputs = [ cmake pkgconfig ]; + + preConfigure = '' + cmakeFlagsArray+=("-DVMCS_INSTALL_PREFIX=$out") + '' + stdenv.lib.optionalString stdenv.isAarch64 '' + cmakeFlagsArray+=("-DARM64=1") + ''; + + meta = with stdenv.lib; { + description = "Userland tools for the Raspberry Pi board"; + homepage = https://github.com/raspberrypi/userland; + license = licenses.bsd3; + platforms = [ "armv6l-linux" "armv7l-linux" "aarch64-linux" ]; + maintainers = with maintainers; [ dezgeg viric tavyc ]; + }; +} |