view CMakeLists.txt @ 0:1e5118fa0cb1

This is NSS with a Cmake Buildsyste To compile a static NSS library for Windows we've used the Chromium-NSS fork and added a Cmake buildsystem to compile it statically for Windows. See README.chromium for chromium changes and README.trustbridge for our modifications.
author Andre Heinecke <andre.heinecke@intevation.de>
date Mon, 28 Jul 2014 10:47:06 +0200
parents
children 247cffdc9b89
line wrap: on
line source
# Copyright (C) 2014 by Bundesamt für Sicherheit in der Informationstechnik
# Software engineering by Intevation GmbH
#
# This file is Free Software under the GNU GPL (v>=2)
# and comes with ABSOLUTELY NO WARRANTY!
# See LICENSE.txt for details.

include_directories(${CMAKE_CURRENT_BINARY_DIR})
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/sqlite)
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/nspr/pr/include)
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/nspr/pr/include/private)
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/nspr/lib/ds)
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/nspr/lib/libc/include)

include_directories(${CMAKE_CURRENT_SOURCE_DIR}/nss/lib/base)
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/nss/lib/certdb)
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/nss/lib/certhigh)
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/nss/lib/cryptohi)
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/nss/lib/dev)
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/nss/lib/freebl)
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/nss/lib/freebl/ecl)
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/nss/lib/freebl/mpi)
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/nss/lib/nss)
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/nss/lib/pk11wrap)
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/nss/lib/pkcs7)
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/nss/lib/pki)
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/nss/lib/smime)
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/nss/lib/softoken)
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/nss/lib/ssl)
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/nss/lib/util)

set (COMMON_DEFINITIONS "-DWIN32 -D_WIN32_WINNT=0x602 -D_NSPR_BUILD -DFORCE_PR_LOG -DXP_PC")
set (COMMON_DEFINITIONS "${COMMON_DEFINITIONS} -DWIN95 -D_PR_GLOBAL_THREADS_ONLY -D_X86_ -UWINNT")
set (COMMON_DEFINITIONS "${COMMON_DEFINITIONS} -DNSPR_STATIC")

set (NSS_DEFINITIONS "${COMMON_DEFINITIONS} -DMP_API_COMPATIBLE -DNSS_DISABLE_DBM -DNSS_STATIC")
set (NSS_DEFINITIONS "${NSS_DEFINITIONS} -DNSS_USE_STATIC_LIBS -DRIJNDAEL_INCLUDE_TABLES -DSHLIB_VERSION=\\\"3\\\"" )
set (NSS_DEFINITIONS "${NSS_DEFINITIONS} -DSOFTOKEN_SHLIB_VERSION=\\\"3\\\" -DUSE_UTIL_DIRECTLY")
set (NSS_DEFINITIONS "${NSS_DEFINITIONS} -DNSS_DISABLE_ROOT_CERTS -DNSS_DISABLE_LIBPKIX -DSHLIB_SUFFIX=\\\"dll\\\"")
set (NSS_DEFINITIONS "${NSS_DEFINITIONS} -DSHLIB_PREFIX=\\\"\\\" -DSOFTOKEN_LIB_NAME=\\\"softokn3.dll\\\"")
set (NSS_DEFINITIONS "${NSS_DEFINITIONS} -DNSS_X86_OR_X64 -DNSS_X86 -D_X86_")
set (NSS_DEFINITIONS "${NSS_DEFINITIONS} -DMP_NO_MP_WORD -DMP_USE_UINT_DIGIT")
#set (NSS_DEFINITIONS "${NSS_DEFINITIONS} -DMP_ASSEMBLY_MULTIPLY -DMP_ASSEMBLY_SQUARE -DMP_ASSEMBLY_DIV_2DX1D ")
set (NSS_DEFINITIONS "${NSS_DEFINITIONS} -DNO_NSPR_10_SUPPORT -DXP_WIN32 -DXP_WIN")

set (NSPR_DEFINITIONS "${COMMON_DEFINITIONS} -D_NSPR_BUILD")

set(nss_static_src
   nss/lib/base/arena.c
   nss/lib/base/error.c
   nss/lib/base/errorval.c
   nss/lib/base/hash.c
   nss/lib/base/hashops.c
   nss/lib/base/item.c
   nss/lib/base/libc.c
   nss/lib/base/list.c
   nss/lib/base/nssutf8.c
   nss/lib/base/tracker.c
   nss/lib/certdb/alg1485.c
   nss/lib/certdb/certdb.c
   nss/lib/certdb/certv3.c
   nss/lib/certdb/certxutl.c
   nss/lib/certdb/crl.c
   nss/lib/certdb/genname.c
   nss/lib/certdb/polcyxtn.c
   nss/lib/certdb/secname.c
   nss/lib/certdb/stanpcertdb.c
   nss/lib/certdb/xauthkid.c
   nss/lib/certdb/xbsconst.c
   nss/lib/certdb/xconst.c
   nss/lib/certhigh/certhigh.c
   nss/lib/certhigh/certhtml.c
   nss/lib/certhigh/certreq.c
   nss/lib/certhigh/certvfy.c
   nss/lib/certhigh/crlv2.c
   nss/lib/certhigh/ocsp.c
   nss/lib/certhigh/ocspsig.c
   nss/lib/certhigh/xcrldist.c
   nss/lib/cryptohi/dsautil.c
   nss/lib/cryptohi/sechash.c
   nss/lib/cryptohi/seckey.c
   nss/lib/cryptohi/secsign.c
   nss/lib/cryptohi/secvfy.c
   nss/lib/dev/ckhelper.c
   nss/lib/dev/devslot.c
   nss/lib/dev/devtoken.c
   nss/lib/dev/devutil.c
   nss/lib/freebl/aeskeywrap.c
   nss/lib/freebl/alg2268.c
   nss/lib/freebl/alghmac.c
   nss/lib/freebl/arcfive.c
   nss/lib/freebl/arcfour.c
   nss/lib/freebl/camellia.c
   nss/lib/freebl/chacha20/chacha20.c
   nss/lib/freebl/chacha20poly1305.c
   nss/lib/freebl/ctr.c
   nss/lib/freebl/cts.c
   nss/lib/freebl/des.c
   nss/lib/freebl/desblapi.c
   nss/lib/freebl/dh.c
   nss/lib/freebl/drbg.c
   nss/lib/freebl/dsa.c
   nss/lib/freebl/ec.c
   nss/lib/freebl/ecdecode.c
   nss/lib/freebl/ecl/ecl.c
   nss/lib/freebl/ecl/ecl_curve.c
   nss/lib/freebl/ecl/ecl_gf.c
   nss/lib/freebl/ecl/ecl_mult.c
   nss/lib/freebl/ecl/ecp_256.c
   nss/lib/freebl/ecl/ecp_256_32.c
   nss/lib/freebl/ecl/ecp_384.c
   nss/lib/freebl/ecl/ecp_521.c
   nss/lib/freebl/ecl/ecp_aff.c
   nss/lib/freebl/ecl/ecp_jac.c
   nss/lib/freebl/ecl/ecp_jm.c
   nss/lib/freebl/ecl/ecp_mont.c
   nss/lib/freebl/ecl/ec_naf.c
   nss/lib/freebl/gcm.c
   nss/lib/freebl/hmacct.c
   nss/lib/freebl/jpake.c
   nss/lib/freebl/md2.c
   nss/lib/freebl/md5.c
   nss/lib/freebl/mpi/mpcpucache.c
   nss/lib/freebl/mpi/mpi.c
   #   nss/lib/freebl/mpi/mpi_x86_asm.c
   nss/lib/freebl/mpi/mplogic.c
   nss/lib/freebl/mpi/mpmontg.c
   nss/lib/freebl/mpi/mpprime.c
   nss/lib/freebl/mpi/mp_gf2m.c
   nss/lib/freebl/poly1305/poly1305.c
   nss/lib/freebl/pqg.c
   nss/lib/freebl/rawhash.c
   nss/lib/freebl/rijndael.c
   nss/lib/freebl/rsa.c
   nss/lib/freebl/rsapkcs.c
   nss/lib/freebl/seed.c
   nss/lib/freebl/sha512.c
   nss/lib/freebl/sha_fast.c
   nss/lib/freebl/shvfy.c
   nss/lib/freebl/sysrand.c
   nss/lib/freebl/tlsprfalg.c
   nss/lib/nss/nssinit.c
   nss/lib/nss/utilwrap.c
   nss/lib/pk11wrap/dev3hack.c
   nss/lib/pk11wrap/pk11akey.c
   nss/lib/pk11wrap/pk11auth.c
   nss/lib/pk11wrap/pk11cert.c
   nss/lib/pk11wrap/pk11cxt.c
   nss/lib/pk11wrap/pk11err.c
   nss/lib/pk11wrap/pk11kea.c
   nss/lib/pk11wrap/pk11list.c
   nss/lib/pk11wrap/pk11load.c
   nss/lib/pk11wrap/pk11mech.c
   nss/lib/pk11wrap/pk11merge.c
   nss/lib/pk11wrap/pk11nobj.c
   nss/lib/pk11wrap/pk11obj.c
   nss/lib/pk11wrap/pk11pars.c
   nss/lib/pk11wrap/pk11pbe.c
   nss/lib/pk11wrap/pk11pk12.c
   nss/lib/pk11wrap/pk11pqg.c
   nss/lib/pk11wrap/pk11sdr.c
   nss/lib/pk11wrap/pk11skey.c
   nss/lib/pk11wrap/pk11slot.c
   nss/lib/pk11wrap/pk11util.c
   nss/lib/pkcs7/certread.c
   nss/lib/pkcs7/p7common.c
   nss/lib/pkcs7/p7create.c
   nss/lib/pkcs7/p7decode.c
   nss/lib/pkcs7/p7encode.c
   nss/lib/pkcs7/p7local.c
   nss/lib/pkcs7/secmime.c
   nss/lib/pki/asymmkey.c
   nss/lib/pki/certdecode.c
   nss/lib/pki/certificate.c
   nss/lib/pki/cryptocontext.c
   nss/lib/pki/pki3hack.c
   nss/lib/pki/pkibase.c
   nss/lib/pki/pkistore.c
   nss/lib/pki/symmkey.c
   nss/lib/pki/tdcache.c
   nss/lib/pki/trustdomain.c
   nss/lib/softoken/fipsaudt.c
   nss/lib/softoken/fipstest.c
   nss/lib/softoken/fipstokn.c
   nss/lib/softoken/jpakesftk.c
   nss/lib/softoken/lgglue.c
   nss/lib/softoken/lowkey.c
   nss/lib/softoken/lowpbe.c
   nss/lib/softoken/padbuf.c
   nss/lib/softoken/pkcs11.c
   nss/lib/softoken/pkcs11c.c
   nss/lib/softoken/pkcs11u.c
   nss/lib/softoken/sdb.c
   nss/lib/softoken/sftkdb.c
   nss/lib/softoken/sftkhmac.c
   nss/lib/softoken/sftkpars.c
   nss/lib/softoken/sftkpwd.c
   nss/lib/softoken/softkver.c
   nss/lib/softoken/tlsprf.c
   nss/lib/util/derdec.c
   nss/lib/util/derenc.c
   nss/lib/util/dersubr.c
   nss/lib/util/dertime.c
   nss/lib/util/errstrs.c
   nss/lib/util/nssb64d.c
   nss/lib/util/nssb64e.c
   nss/lib/util/nssilock.c
   nss/lib/util/nssrwlk.c
   nss/lib/util/oidstring.c
   nss/lib/util/portreg.c
   nss/lib/util/quickder.c
   nss/lib/util/secalgid.c
   nss/lib/util/secasn1d.c
   nss/lib/util/secasn1e.c
   nss/lib/util/secasn1u.c
   nss/lib/util/secdig.c
   nss/lib/util/secitem.c
   nss/lib/util/secoid.c
   nss/lib/util/secport.c
   nss/lib/util/sectime.c
   nss/lib/util/templates.c
   nss/lib/util/utf8.c
   nss/lib/util/utilmod.c
   nss/lib/util/utilpars.c
   nss/lib/nss/nssver.c
   nss/lib/freebl/win_rand.c
   sqlite/sqlite3.c
   )

set(nspr_static_src
   nspr/pr/src/io/prlayer.c
   nspr/pr/src/io/prlog.c
   nspr/pr/src/io/prmapopt.c
   nspr/pr/src/io/prmmap.c
   nspr/pr/src/io/prmwait.c
   nspr/pr/src/io/prpolevt.c
   nspr/pr/src/io/prprf.c
   nspr/pr/src/io/prscanf.c
   nspr/pr/src/io/prsocket.c
   nspr/pr/src/io/prstdio.c
   nspr/pr/src/io/priometh.c
   nspr/pr/src/io/prfile.c
   nspr/pr/src/io/prfdcach.c
   nspr/pr/src/io/prsocket.c
   nspr/pr/src/io/pripv6.c
   nspr/pr/src/io/prio.c
   nspr/pr/src/linking/prlink.c
   nspr/pr/src/malloc/prmalloc.c
   nspr/pr/src/malloc/prmem.c
   nspr/pr/src/md/prosdep.c
   nspr/pr/src/md/windows/ntgc.c
   nspr/pr/src/md/windows/ntinrval.c
   nspr/pr/src/md/windows/ntmisc.c
   nspr/pr/src/md/windows/ntsec.c
   nspr/pr/src/md/windows/ntsem.c
   nspr/pr/src/md/windows/w32ipcsem.c
   nspr/pr/src/md/windows/w32poll.c
   nspr/pr/src/md/windows/w32rng.c
   nspr/pr/src/md/windows/w32shm.c
   nspr/pr/src/md/windows/w95cv.c
   nspr/pr/src/md/windows/w95dllmain.c
   nspr/pr/src/md/windows/w95io.c
   nspr/pr/src/md/windows/w95sock.c
   nspr/pr/src/md/windows/w95thred.c
   nspr/pr/src/md/windows/win32_errors.c
   nspr/pr/src/memory/prseg.c
   nspr/pr/src/memory/prshm.c
   nspr/pr/src/memory/prshma.c
   nspr/pr/src/misc/pralarm.c
   nspr/pr/src/misc/pratom.c
   nspr/pr/src/misc/praton.c
   nspr/pr/src/misc/prcountr.c
   nspr/pr/src/misc/prdtoa.c
   nspr/pr/src/misc/prenv.c
   nspr/pr/src/misc/prerr.c
   nspr/pr/src/misc/prerror.c
   nspr/pr/src/misc/prerrortable.c
   nspr/pr/src/misc/prinit.c
   nspr/pr/src/misc/prinrval.c
   nspr/pr/src/misc/pripc.c
   nspr/pr/src/misc/pripcsem.c
   nspr/pr/src/misc/prlog2.c
   nspr/pr/src/misc/prlong.c
   nspr/pr/src/misc/prnetdb.c
   nspr/pr/src/misc/prolock.c
   nspr/pr/src/misc/prrng.c
   nspr/pr/src/misc/prsystem.c
   nspr/pr/src/misc/prthinfo.c
   nspr/pr/src/misc/prtime.c
   nspr/pr/src/misc/prtpool.c
   nspr/pr/src/misc/prtrace.c
   nspr/pr/src/threads/combined/prucpu.c
   nspr/pr/src/threads/combined/prucv.c
   nspr/pr/src/threads/combined/prulock.c
   nspr/pr/src/threads/combined/prustack.c
   nspr/pr/src/threads/combined/pruthr.c
   nspr/pr/src/threads/prcmon.c
   nspr/pr/src/threads/prcthr.c
   nspr/pr/src/threads/prdump.c
   nspr/pr/src/threads/prmon.c
   nspr/pr/src/threads/prrwlock.c
   nspr/pr/src/threads/prsem.c
   nspr/pr/src/threads/prtpd.c
   nspr/lib/ds/plhash.c
   nspr/lib/ds/plarena.c
   nspr/lib/libc/src/strcase.c
   nspr/lib/libc/src/strcat.c
   nspr/lib/libc/src/strcpy.c
   nspr/lib/libc/src/strlen.c
   nspr/lib/libc/src/strpbrk.c
   nspr/lib/libc/src/base64.c
   )

add_library(nss_static STATIC ${nss_static_src})
add_library(nspr_static STATIC ${nspr_static_src})

set_target_properties(nspr_static PROPERTIES COMPILE_FLAGS ${NSPR_DEFINITIONS})
set_target_properties(nss_static PROPERTIES COMPILE_FLAGS ${NSS_DEFINITIONS})
This site is hosted by Intevation GmbH (Datenschutzerklärung und Impressum | Privacy Policy and Imprint)