Skip to content

Commit

Permalink
Fix linux syscall library build for NixOS
Browse files Browse the repository at this point in the history
  • Loading branch information
ehmry committed Jun 19, 2019
1 parent 4c4cc5b commit 11d2a29
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 6 deletions.
2 changes: 1 addition & 1 deletion repos/base-linux/lib/import/import-lx_hybrid.mk
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ HOST_INC_DIR += $(shell echo "int main() {return 0;}" |\
# Nix include paths
#
ifneq ($(nativeBuildInputs),)
HOST_INC_DIR += $(shell find $(nativeBuildInputs) -name include)
HOST_INC_DIR += $(shell find $(nativeBuildInputs) -maxdepth 1 -name include)
endif


Expand Down
8 changes: 6 additions & 2 deletions repos/base-linux/lib/import/import-syscall-linux.mk
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,12 @@ HOST_INC_DIR += /usr/include/$(shell gcc -dumpmachine)
HOST_INC_DIR += /usr/include/i386-linux-gnu
HOST_INC_DIR += /usr/include/x86_64-linux-gnu

# NixOS
HOST_INC_DIR += $(foreach NP,$(NIX_PROFILES),$(NP)/include)
#
# Nix include paths
#
ifneq ($(nativeBuildInputs),)
HOST_INC_DIR += $(shell find $(nativeBuildInputs) -maxdepth 1 -name include)
endif

#
# Some header files installed on GNU/Linux test for the GNU compiler. For
Expand Down
7 changes: 4 additions & 3 deletions tool/dev-shell.nix
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
{ pkgs ? import <nixpkgs> {} }: with pkgs;

stdenv.mkDerivation {
pkgs.mkShell {
name = "genode-dev-env";
buildInputs =
nativeBuildInputs =
[ (import ./toolchain.nix { inherit pkgs; })
stdenv.glibc.dev
git
ccache
tcl
Expand Down Expand Up @@ -33,7 +34,6 @@ stdenv.mkDerivation {
SDL.dev
alsaLib.dev


# ncurses port needs infocmp
ncurses
];
Expand All @@ -44,4 +44,5 @@ stdenv.mkDerivation {
export PS1="\[\033[1;30m\]Genode-dev [\[\033[1;37m\]\w\[\033[1;30m\]] $\[\033[0m\] "
export PS2="\[\033[1;30m\]>\[\033[0m\] "
'';
# Setup a prompt with a distinct appearance
}

0 comments on commit 11d2a29

Please sign in to comment.