build: make precompiled headers more useful
This can reduce the compilation time of a release
build (without tests) by more than 40%
Refs: #5212
Change-Id: I977aff0c0c7becbfee8a8b55605b81d0c014829b
diff --git a/wscript b/wscript
index 647347d..2ddc5a5 100644
--- a/wscript
+++ b/wscript
@@ -155,12 +155,10 @@
bld.objects(
target='core-objects',
- features='pch',
source=bld.path.find_node('core').ant_glob('*.cpp') + ['core/version.cpp'],
use='version.cpp version.hpp NDN_CXX BOOST LIBRT',
includes='.',
- export_includes='.',
- headers='core/common.hpp')
+ export_includes='.')
nfd_objects = bld.objects(
target='daemon-objects',
@@ -170,6 +168,8 @@
'daemon/face/unix*.cpp',
'daemon/face/websocket*.cpp',
'daemon/main.cpp']),
+ features='pch',
+ headers='daemon/nfd-pch.hpp',
use='core-objects',
includes='daemon',
export_includes='daemon')