Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
argo
aml
Commits
d2195303
Commit
d2195303
authored
Mar 21, 2019
by
Nicolas Denoyelle
Browse files
Include all information needed for version checking
parent
41667393
Pipeline
#6711
failed with stage
in 18 minutes and 42 seconds
Changes
4
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
README.markdown
View file @
d2195303
...
...
@@ -34,3 +34,11 @@ High-level building blocks use the low-level ones to provide fancier memory
management facilities, including:
-
*dmas:*
moving data across areas
-
*scratchpads:*
using an area as an explicitly managed cache of another one
# Version Management
AML versionning is similar to
[
semantic versionning
](
https://semver.org/
)
.
AML version is a string composed of 3 integers separated by a dot: "0.1.0"
The first integer is the major version and all versions with the same
major version are supposed ABI compatible except for major version 0 which is
considered unstable.
configure.ac
View file @
d2195303
# see semver.org for version info
AC_INIT([aml],[0.0.
1
],[swann@anl.gov])
AC_INIT([aml],[0.0.
2
],[swann@anl.gov])
# are we in the right source dir ?
AC_CONFIG_SRCDIR([include/aml.h])
...
...
@@ -67,7 +67,7 @@ ac_configure_args="$ac_configure_args \
'--with-install-suffix=-aml'"
AC_CONFIG_SUBDIRS([jemalloc])
AC_CONFIG_HEADERS([
src
/config.h])
AC_CONFIG_HEADERS([
include
/config.h])
AC_CONFIG_FILES([Makefile
src/Makefile
...
...
include/aml.h
View file @
d2195303
...
...
@@ -32,6 +32,33 @@
#include
<aml/utils/bitmap.h>
#include
<aml/utils/vector.h>
/*
* If AML_ABI_VERSION != aml_major_version,
* the header is not the same version as linked library.
*/
#define AML_ABI_VERSION (0)
extern
const
char
*
aml_version_string
;
extern
int
aml_major_version
;
extern
int
aml_minor_version
;
extern
int
aml_patch_version
;
/*******************************************************************************
* General functions:
* Initialize internal structures, cleanup everything at the end.
******************************************************************************/
/*
* Initializes the library.
* "argc": pointer to the main()'s argc argument; contents can get modified.
* "argv": pointer to the main()'s argv argument; contents can get modified.
* Returns 0 if successful; an error code otherwise.
*/
int
aml_init
(
int
*
argc
,
char
**
argv
[]);
/*
* Terminates the library.
* Returns 0 if successful; an error code otherwise.
*/
int
aml_finalize
(
void
);
/*******************************************************************************
* Forward Declarations:
...
...
@@ -1305,22 +1332,4 @@ void* aml_scratch_baseptr(const struct aml_scratch *scratch);
*/
int
aml_scratch_release
(
struct
aml_scratch
*
scratch
,
int
scratchid
);
/*******************************************************************************
* General functions:
* Initialize internal structures, cleanup everything at the end.
******************************************************************************/
/*
* Initializes the library.
* "argc": pointer to the main()'s argc argument; contents can get modified.
* "argv": pointer to the main()'s argv argument; contents can get modified.
* Returns 0 if successful; an error code otherwise.
*/
int
aml_init
(
int
*
argc
,
char
**
argv
[]);
/*
* Terminates the library.
* Returns 0 if successful; an error code otherwise.
*/
int
aml_finalize
(
void
);
#endif
src/aml.c
View file @
d2195303
...
...
@@ -10,9 +10,19 @@
#include
"config.h"
#include
"aml.h"
#include
<string.h>
const
char
*
aml_version_string
=
VERSION
;
int
aml_major_version
=
-
1
;
int
aml_minor_version
=
-
1
;
int
aml_patch_version
=
-
1
;
int
aml_init
(
int
*
argc
,
char
**
argv
[])
{
char
*
version
=
VERSION
;
aml_major_version
=
atoi
(
strtok
(
version
,
"."
));
aml_minor_version
=
atoi
(
strtok
(
NULL
,
"."
));
aml_patch_version
=
atoi
(
strtok
(
NULL
,
"."
));
return
0
;
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment