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
mpim-sw
libcdi
Commits
f6ebcc5a
Commit
f6ebcc5a
authored
Jun 29, 2009
by
Uwe Schulzweida
Browse files
added gribapiLibraryVersion
parent
82c247ab
Changes
2
Hide whitespace changes
Inline
Side-by-side
config/default
View file @
f6ebcc5a
...
...
@@ -21,7 +21,7 @@ case "${HOSTNAME}" in
# i686-suse-linux
linux
|
laptop
)
./configure
--prefix
=
$HOME
/local
\
--with-jasper
=
/usr
/lib
\
--with-jasper
=
/usr
\
--with-grib_api
=
$HOME
/local
\
--with-netcdf
=
$HOME
/local
\
--with-szlib
=
$HOME
/local
\
...
...
@@ -29,6 +29,8 @@ case "${HOSTNAME}" in
;;
gata
)
./configure
--prefix
=
$HOME
/local/etch-ia32
\
--with-jasper
=
/usr
\
--with-grib_api
=
/scratch/local2/m214003/local
\
--with-netcdf
=
/client
\
--with-szlib
=
$HOME
/local/etch-ia32
\
CC
=
gcc
CFLAGS
=
"-g -O2 -Wall -W -Wfloat-equal -ansi -pedantic"
CFINT
=
-Df2cFortran
...
...
src/gribapi.c
View file @
f6ebcc5a
...
...
@@ -12,13 +12,21 @@
#define XSTRING(x) #x
#define STRING(x) XSTRING(x)
#if defined (HAVE_LIBGRIB_API)
static
const
char
gribapi_libvers
[]
=
"xxx"
;
#else
static
const
char
gribapi_libvers
[]
=
""
;
#endif
static
char
gribapi_libvers
[
64
]
=
""
;
const
char
*
gribapiLibraryVersion
(
void
)
{
#if defined (HAVE_LIBGRIB_API)
long
version
=
grib_get_api_version
();
int
major_version
,
minor_version
,
revision_version
;
major_version
=
version
/
10000
;
minor_version
=
(
version
-
major_version
*
10000
)
/
100
;
revision_version
=
(
version
-
major_version
*
10000
-
minor_version
*
100
);
sprintf
(
gribapi_libvers
,
"%d.%d.%d"
,
major_version
,
minor_version
,
revision_version
);
#endif
return
(
gribapi_libvers
);
}
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