moz.build (1240B)
1 # -*- Mode: python; indent-tabs-mode: nil; tab-width: 40 -*- 2 # vim: set filetype=python: 3 # This Source Code Form is subject to the terms of the Mozilla Public 4 # License, v. 2.0. If a copy of the MPL was not distributed with this 5 # file, You can obtain one at http://mozilla.org/MPL/2.0/. 6 7 Library("verifymar") 8 9 UNIFIED_SOURCES += [ 10 "cryptox.c", 11 "mar_verify.c", 12 ] 13 14 FORCE_STATIC_LIB = True 15 16 if CONFIG["OS_ARCH"] == "WINNT": 17 USE_STATIC_MSVCRT = True 18 elif CONFIG["OS_ARCH"] == "Darwin" and not CONFIG["MOZ_USE_NSS_FOR_MAR"]: 19 UNIFIED_SOURCES += [ 20 "MacVerifyCrypto.cpp", 21 ] 22 OS_LIBS += [ 23 "-framework Security", 24 ] 25 else: 26 USE_LIBS += [ 27 "nspr", 28 "nss", 29 "signmar", 30 ] 31 if CONFIG["OS_ARCH"] != "Darwin": 32 # Ideally, this would be '-Wl,-rpath=$ORIGIN', but the build system 33 # doesn't do the right escaping yet. Even more ideally, this would 34 # be LDFLAGS, but the build system doesn't propagate those like 35 # USE_LIBS and OS_LIBS. Bug #1041943. 36 OS_LIBS += [ 37 "-Wl,-rpath=\\$$ORIGIN", 38 ] 39 40 LOCAL_INCLUDES += [ 41 "../src", 42 ] 43 44 if CONFIG["MOZ_USE_NSS_FOR_MAR"]: 45 LOCAL_INCLUDES += ["../sign"] 46 DEFINES["MAR_NSS"] = True