1
0
mirror of https://github.com/qTox/qTox.git synced 2024-03-22 14:00:36 +08:00

Merge pull request #5946

Emery Hemingway (1):
      feat(build): add nix-shell support
This commit is contained in:
sudden6 2019-12-18 09:42:11 +01:00
commit 9765cf5c72
No known key found for this signature in database
GPG Key ID: 279509B499E032B9
3 changed files with 12 additions and 0 deletions

1
.gitignore vendored
View File

@ -16,6 +16,7 @@ qtox
build-*-Release
build-*-Profile
build-*-Debug
.qtox-wrapped
# Folders
_[Bb]uild*/

View File

@ -714,3 +714,12 @@ target_link_libraries(${PROJECT_NAME}
include(Testing)
include(Installation)
if (DEFINED ENV{IN_NIX_SHELL})
# the qtox binary must be "wrapped" to find the Qt platform plugin
# and other dependencies at runtime
add_custom_command(
TARGET ${PROJECT_NAME}
POST_BUILD
COMMAND nix-shell --run "wrapQtApp ${PROJECT_NAME}")
endif()

2
shell.nix Normal file
View File

@ -0,0 +1,2 @@
{ pkgs ? import <nixpkgs> { } }:
pkgs.mkShell { inputsFrom = with pkgs; [ qtox ]; }