summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJan-Marek Glogowski <glogow@fbihome.de>2020-05-05 12:29:44 +0000
committerJan-Marek Glogowski <glogow@fbihome.de>2020-05-05 12:29:44 +0000
commit7170a8c9f0b568bf5642cda06b31ad78f5eee541 (patch)
treea1aba042253d3c2f551f0251139e1238d4615bef
parent80f07d6746e572c508082b4da92c08b56953092e (diff)
downloadnss-hg-7170a8c9f0b568bf5642cda06b31ad78f5eee541.tar.gz
Bug 1629553 Prefix pk11wrap (SHLIB|LIBRARY)_VERSION with NSS_ r=rrelyea
In the manifest.mn the LIBRARY_VERSION is normally used to define the major version of the build shared library. This ust works for the pk11wrap case, because pk11wrap is a static library. But it's still very confusing when reading the manifest.mn. Also the referenced define in the code is just named SHLIB_VERSION. So this prefixes the defines and the variables with NSS_, because it tries to load the NSS library, just as the SOFTOKEN_.*_VERSION is used to load the versioned softokn library. Differential Revision: https://phabricator.services.mozilla.com/D70689
-rw-r--r--lib/pk11wrap/manifest.mn4
-rw-r--r--lib/pk11wrap/pk11load.c2
-rw-r--r--lib/pk11wrap/pk11wrap.gyp2
3 files changed, 4 insertions, 4 deletions
diff --git a/lib/pk11wrap/manifest.mn b/lib/pk11wrap/manifest.mn
index 1df7e09bf..64ec3083c 100644
--- a/lib/pk11wrap/manifest.mn
+++ b/lib/pk11wrap/manifest.mn
@@ -49,10 +49,10 @@ CSRCS = \
LIBRARY_NAME = pk11wrap
-LIBRARY_VERSION = 3
+NSS_LIBRARY_VERSION = 3
SOFTOKEN_LIBRARY_VERSION = 3
DEFINES += -DSHLIB_SUFFIX=\"$(DLL_SUFFIX)\" -DSHLIB_PREFIX=\"$(DLL_PREFIX)\" \
- -DSHLIB_VERSION=\"$(LIBRARY_VERSION)\" \
+ -DNSS_SHLIB_VERSION=\"$(NSS_LIBRARY_VERSION)\" \
-DSOFTOKEN_SHLIB_VERSION=\"$(SOFTOKEN_LIBRARY_VERSION)\"
# only add module debugging in opt builds if DEBUG_PKCS11 is set
diff --git a/lib/pk11wrap/pk11load.c b/lib/pk11wrap/pk11load.c
index 9b941f963..9e7a0a546 100644
--- a/lib/pk11wrap/pk11load.c
+++ b/lib/pk11wrap/pk11load.c
@@ -355,7 +355,7 @@ SECMOD_SetRootCerts(PK11SlotInfo *slot, SECMODModule *mod)
#ifndef NSS_STATIC_SOFTOKEN
static const char *my_shlib_name =
- SHLIB_PREFIX "nss" SHLIB_VERSION "." SHLIB_SUFFIX;
+ SHLIB_PREFIX "nss" NSS_SHLIB_VERSION "." SHLIB_SUFFIX;
static const char *softoken_shlib_name =
SHLIB_PREFIX "softokn" SOFTOKEN_SHLIB_VERSION "." SHLIB_SUFFIX;
static const PRCallOnceType pristineCallOnce;
diff --git a/lib/pk11wrap/pk11wrap.gyp b/lib/pk11wrap/pk11wrap.gyp
index 17de8add4..65d690f89 100644
--- a/lib/pk11wrap/pk11wrap.gyp
+++ b/lib/pk11wrap/pk11wrap.gyp
@@ -60,7 +60,7 @@
'defines': [
'SHLIB_SUFFIX=\"<(dll_suffix)\"',
'SHLIB_PREFIX=\"<(dll_prefix)\"',
- 'SHLIB_VERSION=\"3\"',
+ 'NSS_SHLIB_VERSION=\"3\"',
'SOFTOKEN_SHLIB_VERSION=\"3\"'
]
},