mirror of
https://github.com/NixOS/nix.git
synced 2025-11-09 20:16:03 +01:00
libstore: Speed up builds by using precompiled headers
This commit is contained in:
parent
e920e28734
commit
33d031095f
2 changed files with 9 additions and 0 deletions
|
|
@ -348,6 +348,7 @@ this_library = library(
|
||||||
link_args: linker_export_flags,
|
link_args: linker_export_flags,
|
||||||
prelink : true, # For C++ static initializers
|
prelink : true, # For C++ static initializers
|
||||||
install : true,
|
install : true,
|
||||||
|
cpp_pch : ['pch/precompiled-headers.hh']
|
||||||
)
|
)
|
||||||
|
|
||||||
install_headers(headers, subdir : 'nix/store', preserve_path : true)
|
install_headers(headers, subdir : 'nix/store', preserve_path : true)
|
||||||
|
|
|
||||||
8
src/libstore/pch/precompiled-headers.hh
Normal file
8
src/libstore/pch/precompiled-headers.hh
Normal file
|
|
@ -0,0 +1,8 @@
|
||||||
|
#include "nix/store/store-api.hh"
|
||||||
|
#include "nix/store/realisation.hh"
|
||||||
|
#include "nix/store/derived-path.hh"
|
||||||
|
#include "nix/store/derivations.hh"
|
||||||
|
#include "nix/store/local-store.hh"
|
||||||
|
#include "nix/util/util.hh"
|
||||||
|
|
||||||
|
#include <nlohmann/json.hpp>
|
||||||
Loading…
Add table
Add a link
Reference in a new issue