Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
L
libcifpp
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
open
libcifpp
Commits
8f997658
Unverified
Commit
8f997658
authored
Feb 17, 2021
by
Maarten L. Hekkelman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update configure to configure data directories
parent
50693163
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
36 additions
and
25 deletions
+36
-25
.gitignore
+1
-0
GNUmakefile.in
+2
-2
configure
+19
-2
configure.ac
+11
-1
libcifpp.pc.in
+1
-0
src/PDB2Cif.cpp
+0
-18
tools/update-dictionary-script.in
+2
-2
No files found.
.gitignore
View file @
8f997658
...
@@ -18,3 +18,4 @@ src/Config.hpp.in~
...
@@ -18,3 +18,4 @@ src/Config.hpp.in~
src/Config.hpp
src/Config.hpp
aclocal.m4
aclocal.m4
version-info-*.txt
version-info-*.txt
tools/update-dictionary-script
GNUmakefile.in
View file @
8f997658
...
@@ -47,8 +47,8 @@ pkgconfigdir = $(libdir)/pkgconfig
...
@@ -47,8 +47,8 @@ pkgconfigdir = $(libdir)/pkgconfig
CCP4DIR
=
@CCP4@
CCP4DIR
=
@CCP4@
CLIBD
=
$
(
CCP4DIR:%
=
%/lib/data
)
CLIBD
=
$
(
CCP4DIR:%
=
%/lib/data
)
CACHE_DIR
=
$(DESTDIR)
/var/cache/libcifpp
CACHE_DIR
=
$(DESTDIR)
@DATA_CACHE_DIR@
DATA_DIR
=
$(datadir)
/libcifpp
DATA_DIR
=
@DATA_LIB_DIR@
CRON_DIR
=
$(DESTDIR)
/etc/cron.weekly
CRON_DIR
=
$(DESTDIR)
/etc/cron.weekly
DEFINES
+=
CACHE_DIR
=
'"
$(CACHE_DIR)
"'
DATA_DIR
=
'"
$(DATA_DIR)
"'
DEFINES
+=
CACHE_DIR
=
'"
$(CACHE_DIR)
"'
DATA_DIR
=
'"
$(DATA_DIR)
"'
...
...
configure
View file @
8f997658
...
@@ -635,6 +635,8 @@ ac_includes_default="\
...
@@ -635,6 +635,8 @@ ac_includes_default="\
ac_subst_vars
=
'LTLIBOBJS
ac_subst_vars
=
'LTLIBOBJS
LIBOBJS
LIBOBJS
DATA_CACHE_DIR
DATA_LIB_DIR
BOOST_REGEX_LIB
BOOST_REGEX_LIB
BOOST_DATE_TIME_LIB
BOOST_DATE_TIME_LIB
BOOST_IOSTREAMS_LIB
BOOST_IOSTREAMS_LIB
...
@@ -779,7 +781,9 @@ DEBUG
...
@@ -779,7 +781,9 @@ DEBUG
CCP4
CCP4
PKG_CONFIG
PKG_CONFIG
PKG_CONFIG_PATH
PKG_CONFIG_PATH
PKG_CONFIG_LIBDIR'
PKG_CONFIG_LIBDIR
DATA_LIB_DIR
DATA_CACHE_DIR'
# Initialize some variables set by options.
# Initialize some variables set by options.
...
@@ -1467,6 +1471,10 @@ Some influential environment variables:
...
@@ -1467,6 +1471,10 @@ Some influential environment variables:
directories to add to pkg-config's search path
directories to add to pkg-config's search path
PKG_CONFIG_LIBDIR
PKG_CONFIG_LIBDIR
path overriding pkg-config's built-in search path
path overriding pkg-config's built-in search path
DATA_LIB_DIR
The location where to store packaged dictionary files
DATA_CACHE_DIR
The location where to store cached dictionary files
Use these variables to override the choices made by `configure' or to help
Use these variables to override the choices made by `configure' or to help
it to find libraries and programs with nonstandard names/locations.
it to find libraries and programs with nonstandard names/locations.
...
@@ -18364,7 +18372,15 @@ _ACEOF
...
@@ -18364,7 +18372,15 @@ _ACEOF
fi
fi
ac_config_files
=
"
$ac_config_files
GNUmakefile libcifpp.pc"
DATA_LIB_DIR
=
$datadir
/libcifpp
DATA_CACHE_DIR
=
/var/cache/libcifpp
ac_config_files
=
"
$ac_config_files
GNUmakefile libcifpp.pc tools/update-dictionary-script"
cat
>
confcache
<<
\
_ACEOF
cat
>
confcache
<<
\
_ACEOF
# This file is a shell script that caches the results of configure
# This file is a shell script that caches the results of configure
...
@@ -19450,6 +19466,7 @@ do
...
@@ -19450,6 +19466,7 @@ do
"libtool") CONFIG_COMMANDS="
$CONFIG_COMMANDS
libtool" ;;
"libtool") CONFIG_COMMANDS="
$CONFIG_COMMANDS
libtool" ;;
"GNUmakefile") CONFIG_FILES="
$CONFIG_FILES
GNUmakefile" ;;
"GNUmakefile") CONFIG_FILES="
$CONFIG_FILES
GNUmakefile" ;;
"libcifpp.pc") CONFIG_FILES="
$CONFIG_FILES
libcifpp.pc" ;;
"libcifpp.pc") CONFIG_FILES="
$CONFIG_FILES
libcifpp.pc" ;;
"tools/update-dictionary-script") CONFIG_FILES="
$CONFIG_FILES
tools/update-dictionary-script" ;;
*) as_fn_error
$?
"invalid argument: \`
$ac_config_target
'" "
$LINENO
" 5;;
*) as_fn_error
$?
"invalid argument: \`
$ac_config_target
'" "
$LINENO
" 5;;
esac
esac
...
...
configure.ac
View file @
8f997658
...
@@ -114,5 +114,15 @@ AX_BOOST_REGEX
...
@@ -114,5 +114,15 @@ AX_BOOST_REGEX
AC_CHECK_LIB([atomic], [atomic_flag_clear])
AC_CHECK_LIB([atomic], [atomic_flag_clear])
dnl Set output variables for the various directories
AC_ARG_VAR([DATA_LIB_DIR], [The location where to store packaged dictionary files])
AC_SUBST([DATA_LIB_DIR])
DATA_LIB_DIR=$datadir/libcifpp
AC_ARG_VAR([DATA_CACHE_DIR], [The location where to store cached dictionary files])
AC_SUBST([DATA_CACHE_DIR])
DATA_CACHE_DIR=/var/cache/libcifpp
AC_OUTPUT([GNUmakefile
AC_OUTPUT([GNUmakefile
libcifpp.pc])
libcifpp.pc
tools/update-dictionary-script])
libcifpp.pc.in
View file @
8f997658
...
@@ -2,6 +2,7 @@ prefix=@prefix@
...
@@ -2,6 +2,7 @@ prefix=@prefix@
exec_prefix=
@exec_prefix@
exec_prefix=
@exec_prefix@
libdir=
@libdir@
libdir=
@libdir@
includedir=
@includedir@
includedir=
@includedir@
datalibdir=
@datarootdir@/libcifpp
Name:
libcifpp
Name:
libcifpp
Description:
C++
library
for
the
manipulation
of
mmCIF
files
.
Description:
C++
library
for
the
manipulation
of
mmCIF
files
.
...
...
src/PDB2Cif.cpp
View file @
8f997658
...
@@ -5778,24 +5778,6 @@ void PDBFileParser::Parse(std::istream& is, cif::File& result)
...
@@ -5778,24 +5778,6 @@ void PDBFileParser::Parse(std::istream& is, cif::File& result)
auto
&
atom_site
=
*
getCategory
(
"atom_site"
);
auto
&
atom_site
=
*
getCategory
(
"atom_site"
);
// for (const auto& [asym1, seq1, atom1, asym2, seq2, atom2]: getCategory("struct_conn")
// ->find<std::string,std::string,std::string,std::string,std::string,std::string>(
// "pdbx_dist_value"_key == 0 or "pdbx_dist_value"_key == Null,
// { "ptnr1_label_asym_id", "ptnr1_label_seq_id", "ptnr1_label_atom_id",
// "ptnr2_label_asym_id", "ptnr2_label_seq_id", "ptnr2_label_atom_id" }))
// {
// auto a1 = atom_site.find1("label_asym_id"_key == asym1 and "label_seq_id"_key == seq1 and "label_atom_id"_key == atom1);
// auto a2 = atom_site.find1("label_asym_id"_key == asym2 and "label_seq_id"_key == seq2 and "label_atom_id"_key == atom2);
// const auto& [x1, y1, z1] = a1.get<float,float,float>({"cartn_x", "cartn_y", "cartn_z"});
// const auto& [x2, y2, z2] = a2.get<float,float,float>({"cartn_x", "cartn_y", "cartn_z"});
// float distance = mmcif::Distance(mmcif::Point{x1, y1, z1}, mmcif::Point{x2, y2, z2});
// std::cerr << "Distance for link: " << distance << std::endl;
// }
for
(
auto
r
:
getCategory
(
"struct_conn"
)
->
find
(
"pdbx_dist_value"
_key
==
0
or
"pdbx_dist_value"
_key
==
Null
))
for
(
auto
r
:
getCategory
(
"struct_conn"
)
->
find
(
"pdbx_dist_value"
_key
==
0
or
"pdbx_dist_value"
_key
==
Null
))
{
{
const
auto
&
[
asym1
,
seq1
,
atom1
,
symm1
,
asym2
,
seq2
,
atom2
,
symm2
]
=
r
.
get
<
std
::
string
,
std
::
string
,
std
::
string
,
std
::
string
,
std
::
string
,
std
::
string
,
std
::
string
,
std
::
string
>
(
const
auto
&
[
asym1
,
seq1
,
atom1
,
symm1
,
asym2
,
seq2
,
atom2
,
symm2
]
=
r
.
get
<
std
::
string
,
std
::
string
,
std
::
string
,
std
::
string
,
std
::
string
,
std
::
string
,
std
::
string
,
std
::
string
>
(
...
...
tools/update-dictionary-script
→
tools/update-dictionary-script
.in
View file @
8f997658
...
@@ -17,13 +17,13 @@ if [ "$update" != "true" ] ; then
...
@@ -17,13 +17,13 @@ if [ "$update" != "true" ] ; then
fi
fi
# if cache directory doesn't exist, exit.
# if cache directory doesn't exist, exit.
if
!
[
-d
/var/cache/libcifpp
]
;
then
if
!
[
-d
@DATA_CACHE_DIR@
]
;
then
exit
exit
fi
fi
# fetch the dictionary
# fetch the dictionary
dict
=
/var/cache/libcifpp
/mmcif_pdbx_v50.dic
dict
=
@DATA_CACHE_DIR@
/mmcif_pdbx_v50.dic
source
=
https://mmcif.wwpdb.org/dictionaries/ascii/mmcif_pdbx_v50.dic.gz
source
=
https://mmcif.wwpdb.org/dictionaries/ascii/mmcif_pdbx_v50.dic.gz
wget
-O
${
dict
}
.gz
${
source
}
wget
-O
${
dict
}
.gz
${
source
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a 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