xref: /reactos/base/services/nfsd/CMakeLists.txt (revision 40462c92)
1remove_definitions(-D_WIN32_WINNT=0x502 -DWINVER=0x502)
2add_definitions(-D_WIN32_WINNT=0x601)
3add_definitions(-DNTDDI_VERSION=0x06010000)
4
5include_directories(
6    ${REACTOS_SOURCE_DIR}/dll/3rdparty/libtirpc/tirpc
7    ${REACTOS_SOURCE_DIR}/drivers/filesystems/nfs
8    ${REACTOS_SOURCE_DIR}/dll/np/nfs)
9
10list(APPEND SOURCE
11    acl.c
12    callback_server.c
13    callback_xdr.c
14    daemon_debug.c
15    delegation.c
16    ea.c
17    getattr.c
18    idmap.c
19    lock.c
20    lookup.c
21    mount.c
22    name_cache.c
23    namespace.c
24    nfs41_client.c
25    nfs41_compound.c
26    nfs41_daemon.c
27    nfs41_ops.c
28    nfs41_rpc.c
29    nfs41_server.c
30    nfs41_session.c
31    nfs41_superblock.c
32    nfs41_xdr.c
33    open.c
34    pnfs_debug.c
35    pnfs_device.c
36    pnfs_io.c
37    pnfs_layout.c
38    readdir.c
39    readwrite.c
40    recovery.c
41    service.c
42    setattr.c
43    symlink.c
44    upcall.c
45    util.c
46    volume.c
47    precomp.h)
48
49add_executable(nfsd ${SOURCE} nfsd.rc)
50
51if(MSVC AND (NOT USE_CLANG_CL))
52    # Disable warning C4477 (printf format warnings)
53    target_compile_options(nfsd PRIVATE "/wd4477")
54else()
55    # FIXME: Tons of warnings.
56    target_compile_options(nfsd PRIVATE "-w")
57endif()
58
59set_module_type(nfsd win32cui)
60add_importlibs(nfsd advapi32 iphlpapi kernel32_vista libtirpc msvcrt shell32 ws2_32 wldap32 kernel32 ntdll)
61add_pch(nfsd precomp.h SOURCE)
62add_cd_file(TARGET nfsd DESTINATION reactos/system32 FOR all)
63add_cd_file(FILE "${CMAKE_CURRENT_SOURCE_DIR}/netconfig" DESTINATION reactos/system32/drivers/etc FOR all)
64add_cd_file(FILE "${CMAKE_CURRENT_SOURCE_DIR}/ms-nfs41-idmap.conf" DESTINATION reactos/system32/drivers/etc FOR all)
65