-
Notifications
You must be signed in to change notification settings - Fork 75
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This splits out optee-related packages into multiple derivations to allow for easier overriding of individual components. This will eventually allow for the removal of nixos options that override these components, as overlays are now easier to use.
- Loading branch information
Showing
10 changed files
with
290 additions
and
256 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
{ gitRepos | ||
, l4tVersion | ||
, opteeStdenv | ||
, socType | ||
}: | ||
|
||
opteeStdenv.mkDerivation { | ||
pname = "arm-trusted-firmware"; | ||
version = l4tVersion; | ||
src = gitRepos."tegra/optee-src/atf"; | ||
makeFlags = [ | ||
"-C arm-trusted-firmware" | ||
"BUILD_BASE=$(PWD)/build" | ||
"CROSS_COMPILE=${opteeStdenv.cc.targetPrefix}" | ||
"DEBUG=0" | ||
"LOG_LEVEL=20" | ||
"PLAT=tegra" | ||
"SPD=opteed" | ||
"TARGET_SOC=${socType}" | ||
"V=0" | ||
# binutils 2.39 regression | ||
# `warning: /build/source/build/rk3399/release/bl31/bl31.elf has a LOAD segment with RWX permissions` | ||
# See also: https://developer.trustedfirmware.org/T996 | ||
"LDFLAGS=-no-warn-rwx-segments" | ||
]; | ||
|
||
enableParallelBuilding = true; | ||
|
||
installPhase = '' | ||
runHook preInstall | ||
mkdir -p $out | ||
cp ./build/tegra/${socType}/release/bl31.bin $out/bl31.bin | ||
runHook postInstall | ||
''; | ||
|
||
meta.platforms = [ "aarch64-linux" ]; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
{ opteeStdenv, fetchpatch, gitRepos, l4tVersion, pkg-config, libuuid }: | ||
|
||
opteeStdenv.mkDerivation { | ||
pname = "optee_client"; | ||
version = l4tVersion; | ||
src = gitRepos."tegra/optee-src/nv-optee"; | ||
patches = [ | ||
./0001-Don-t-prepend-foo-bar-baz-to-TEEC_LOAD_PATH.patch | ||
(fetchpatch { | ||
name = "tee-supplicant-Allow-for-TA-load-path-to-be-specified-at-runtime.patch"; | ||
url = "https://github.com/OP-TEE/optee_client/commit/f3845d8bee3645eedfcc494be4db034c3c69e9ab.patch"; | ||
stripLen = 1; | ||
extraPrefix = "optee/optee_client/"; | ||
hash = "sha256-XjFpMbyXy74sqnc8l+EgTaPXqwwHcvni1Z68ShokTGc="; | ||
}) | ||
]; | ||
nativeBuildInputs = [ pkg-config ]; | ||
buildInputs = [ libuuid ]; | ||
enableParallelBuilding = true; | ||
makeFlags = [ | ||
"-C optee/optee_client" | ||
"DESTDIR=$(out)" | ||
"SBINDIR=/sbin" | ||
"LIBDIR=/lib" | ||
"INCLUDEDIR=/include" | ||
]; | ||
meta.platforms = [ "aarch64-linux" ]; | ||
} |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.