-
Notifications
You must be signed in to change notification settings - Fork 56
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Set version number in CMakeLists.txt Version number gets sent to C code through preprocessor symbols and to doxygen through environmental variables. Also cleaned up printing of doxygen documentation to show only major.minor at top of page but major.minor.patch in a note on the main page. Also did a bit more cleaning up of doxygen docs. Users don't have access to version numbers now, because we are basing them on CMake variables at our compile time, rather than hard coding them in the header. What I think will make more sense is to templatize the version.h file to actually paste those numbers in there based on the values CMake is holding. * Go back to hard coded version numbers in version.h - Removed add_compile_definitions which needs a minimum of CMake 3.12 - Users have access to version numbers again, but we need to store them in two places * Auto generate version.h with the correct version numbers This does almost everything we need with version numbers in both C and Doxygen code, except for one thing: version.h is not yet being properly installed on make install * Make newly generated version.h file get installed properly Also cleaned up some cruft in CMakeLists.txt * bugfix: public version.h cannot depend on private/config.h Reversed the order of the dependency and kept user agent string stuff entirely in private header file. Public version string no longer contains git repo info, but user agent string still does. * clang formatting * Move user agent string stuff to separate private header file Also remove version unit test that wasn't really a unit test * style check fix
- Loading branch information
1 parent
9210dd1
commit c9c158d
Showing
7 changed files
with
78 additions
and
50 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
/* | ||
* Copyright 2018 Amazon.com, Inc. or its affiliates. All Rights Reserved. | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"). You may not use | ||
* this file except in compliance with the License. A copy of the License is | ||
* located at | ||
* | ||
* http://aws.amazon.com/apache2.0/ | ||
* | ||
* or in the "license" file accompanying this file. This file is distributed on an | ||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or | ||
* implied. See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
#ifndef AWS_CRYPTOSDK_PRIVATE_USER_AGENT_H | ||
#define AWS_CRYPTOSDK_PRIVATE_USER_AGENT_H | ||
|
||
#include <aws/cryptosdk/private/config.h> | ||
#include <aws/cryptosdk/version.h> | ||
|
||
// A string constant containing version information in a human-readable form, with git repo info. | ||
#define AWS_CRYPTOSDK_PRIVATE_VERSION_STR \ | ||
AWS_CRYPTOSDK_PRIVATE_EXPANDQUOTE(AWS_CRYPTOSDK_VERSION_MAJOR) \ | ||
"." AWS_CRYPTOSDK_PRIVATE_EXPANDQUOTE(AWS_CRYPTOSDK_VERSION_MINOR) "." AWS_CRYPTOSDK_PRIVATE_EXPANDQUOTE( \ | ||
AWS_CRYPTOSDK_VERSION_PATCH) AWS_CRYPTOSDK_PRIVATE_GITVERSION | ||
|
||
// A string constant containing version information in a form suitable for a user-agent string. | ||
#define AWS_CRYPTOSDK_PRIVATE_VERSION_UA "aws-encryption-sdk-c/" AWS_CRYPTOSDK_PRIVATE_VERSION_STR | ||
|
||
#endif // AWS_CRYPTOSDK_PRIVATE_USER_AGENT_H |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters