diff --git a/src/nwnss/CMakeLists.txt b/src/nwnss/CMakeLists.txt index 304f2cf..4517036 100644 --- a/src/nwnss/CMakeLists.txt +++ b/src/nwnss/CMakeLists.txt @@ -100,6 +100,7 @@ add_library(nwnss SHARED library/xCtype.c library/xString.c nsslnxlib/nwlocale.c + comn/comnVersion.c comn/common/beastHash.c comn/common/comnMacShortName.c comn/common/comnVariableData.c @@ -150,7 +151,11 @@ target_compile_definitions(nwnss MARS_NWE_NWCORE_DOS_CODEPAGE="VENDORS/MICSFT/PC/CP850" MARS_NWE_NWCORE_MAC_CODEPAGE="VENDORS/APPLE/ROMAN" MARS_NWE_NWNSS_UNICODE - MARS_NWE_VERSION_STRING="${MARS_NWE_VERSION}") + MARS_NWE_VERSION_STRING="${MARS_NWE_VERSION}" + ZMAJV=${VERSION_MAJOR} + ZMINV=${VERSION_MINOR} + ZSUBV=${VERSION_PATCH} + ZBLDN=0) target_include_directories(nwnss PUBLIC diff --git a/src/nwnss/comn/comnVersion.c b/src/nwnss/comn/comnVersion.c new file mode 100644 index 0000000..01cebaa --- /dev/null +++ b/src/nwnss/comn/comnVersion.c @@ -0,0 +1,46 @@ +/**************************************************************************** + | + | (C) Copyright 1985, 1991, 1993, 1996 Novell, Inc. + | All Rights Reserved. + | + | This program is free software; you can redistribute it and/or + | modify it under the terms of version 2 of the GNU General Public + | License as published by the Free Software Foundation. + | + | This program is distributed in the hope that it will be useful, + | but WITHOUT ANY WARRANTY; without even the implied warranty of + | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + | GNU General Public License for more details. + | + | You should have received a copy of the GNU General Public License + | along with this program; if not, contact Novell, Inc. + | + | To contact Novell about this file by physical or electronic mail, + | you may find current contact information at www.novell.com + | + |*************************************************************************** + | + | NetWare Advance File Services (PSS) module + | + |--------------------------------------------------------------------------- + | + | $Author: taysom $ + | $Date: 2004-12-31 01:10:58 +0530 (Fri, 31 Dec 2004) $ + | + | $RCSfile$ + | $Revision: 465 $ + | + |--------------------------------------------------------------------------- + | This module is used to: + | Holds build number for the given product + +-------------------------------------------------------------------------*/ +#include + +VersionInformation_s CMN_VersionInfo = +{ + ZMAJV, + ZMINV, + ZSUBV, + ZBLDN, + VERINFO_PATENT_PENDING +}; diff --git a/tests/nwnss/namespace/test_nwnss_namespace.c b/tests/nwnss/namespace/test_nwnss_namespace.c index fc4dd39..812d7fd 100644 --- a/tests/nwnss/namespace/test_nwnss_namespace.c +++ b/tests/nwnss/namespace/test_nwnss_namespace.c @@ -47,8 +47,11 @@ #include "dosNSpace.h" #include #include +#include #include +extern VersionInformation_s CMN_VersionInfo; + #define CHECK(expr) do { \ if (!(expr)) { \ fprintf(stderr, "CHECK failed: %s:%d: %s\n", __FILE__, __LINE__, #expr); \ @@ -132,6 +135,8 @@ int main(void) CHECK(sizeof(TagRequest_s) >= sizeof(void *)); CHECK(MACNS_wildMatch == MACNS_wildMatch); CHECK(UNIXNS_wildMatch == UNIXNS_wildMatch); + CHECK(CMN_VersionInfo.majorVersion >= 0); + CHECK(CMN_VersionInfo.patentInfo == VERINFO_PATENT_PENDING); memset(answer, 0, sizeof(answer)); CHECK(DOSNS_wildReplace(NULL, src_pattern, src_name, replace_pattern, answer) == zOK);