Commit 84123df9 by Maarten L. Hekkelman

changes from Debian included

parent 34bbf067
...@@ -161,7 +161,7 @@ else ...@@ -161,7 +161,7 @@ else
src/revision.hpp: src/revision.hpp:
@ echo 'const char kRevision[] = R"(' > $@ @ echo 'const char kRevision[] = R"(' > $@
@ echo libcifpp-version: $(VERSION) >> $@ @ echo libcifpp-version: $(VERSION) >> $@
@ echo Date: $$(date --iso-8601) >> $@ @ echo Date: $$(date --utc --date=@$(SOURCE_DATE_EPOCH) --iso-8601) >> $@
@ echo ')";' >> $@ @ echo ')";' >> $@
endif endif
......
...@@ -640,6 +640,8 @@ BOOST_IOSTREAMS_LIB ...@@ -640,6 +640,8 @@ BOOST_IOSTREAMS_LIB
BOOST_LDFLAGS BOOST_LDFLAGS
BOOST_CPPFLAGS BOOST_CPPFLAGS
SET_MAKE SET_MAKE
PKG_CONFIG_LIBDIR
PKG_CONFIG_PATH
PKG_CONFIG PKG_CONFIG
CCP4 CCP4
UPDATE_REVISION UPDATE_REVISION
...@@ -766,7 +768,10 @@ CC ...@@ -766,7 +768,10 @@ CC
CFLAGS CFLAGS
LT_SYS_LIBRARY_PATH LT_SYS_LIBRARY_PATH
DEBUG DEBUG
CCP4' CCP4
PKG_CONFIG
PKG_CONFIG_PATH
PKG_CONFIG_LIBDIR'
# Initialize some variables set by options. # Initialize some variables set by options.
...@@ -1444,6 +1449,11 @@ Some influential environment variables: ...@@ -1444,6 +1449,11 @@ Some influential environment variables:
User-defined run-time library search path. User-defined run-time library search path.
DEBUG Build a debug version of the library DEBUG Build a debug version of the library
CCP4 The location where CCP4 is installed CCP4 The location where CCP4 is installed
PKG_CONFIG path to pkg-config utility
PKG_CONFIG_PATH
directories to add to pkg-config's search path
PKG_CONFIG_LIBDIR
path overriding pkg-config's built-in search path
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.
...@@ -16101,8 +16111,17 @@ UPDATE_REVISION=$UPDATE_REVISION ...@@ -16101,8 +16111,17 @@ UPDATE_REVISION=$UPDATE_REVISION
# Extract the first word of "pkg-config", so it can be a program name with args.
set dummy pkg-config; ac_word=$2
if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; } $as_echo_n "checking for $ac_word... " >&6; }
if ${ac_cv_path_PKG_CONFIG+:} false; then : if ${ac_cv_path_PKG_CONFIG+:} false; then :
...@@ -16141,6 +16160,77 @@ $as_echo "no" >&6; } ...@@ -16141,6 +16160,77 @@ $as_echo "no" >&6; }
fi fi
fi
if test -z "$ac_cv_path_PKG_CONFIG"; then
ac_pt_PKG_CONFIG=$PKG_CONFIG
# Extract the first word of "pkg-config", so it can be a program name with args.
set dummy pkg-config; ac_word=$2
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
$as_echo_n "(cached) " >&6
else
case $ac_pt_PKG_CONFIG in
[\\/]* | ?:[\\/]*)
ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
;;
*)
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
IFS=$as_save_IFS
;;
esac
fi
ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
if test -n "$ac_pt_PKG_CONFIG"; then
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
$as_echo "$ac_pt_PKG_CONFIG" >&6; }
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
$as_echo "no" >&6; }
fi
if test "x$ac_pt_PKG_CONFIG" = x; then
PKG_CONFIG=""
else
case $cross_compiling:$ac_tool_warned in
yes:)
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
PKG_CONFIG=$ac_pt_PKG_CONFIG
fi
else
PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
fi
fi
if test -n "$PKG_CONFIG"; then
_pkg_min_version=0.9.0
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
$as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
$as_echo "yes" >&6; }
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
$as_echo "no" >&6; }
PKG_CONFIG=""
fi
fi
for ac_func in floor pow rint sqrt strchr strerror for ac_func in floor pow rint sqrt strchr strerror
do : do :
......
...@@ -94,7 +94,7 @@ AC_SUBST([UPDATE_REVISION], [$UPDATE_REVISION]) ...@@ -94,7 +94,7 @@ AC_SUBST([UPDATE_REVISION], [$UPDATE_REVISION])
AC_ARG_VAR([CCP4], [The location where CCP4 is installed]) AC_ARG_VAR([CCP4], [The location where CCP4 is installed])
AC_PATH_PROG([PKG_CONFIG], [pkg-config]) PKG_PROG_PKG_CONFIG
AC_CHECK_FUNCS([floor pow rint sqrt strchr strerror]) AC_CHECK_FUNCS([floor pow rint sqrt strchr strerror])
AC_CHECK_HEADERS([sys/ioctl.h]) AC_CHECK_HEADERS([sys/ioctl.h])
......
...@@ -624,7 +624,10 @@ void WriteTitle(std::ostream& pdbFile, Datablock& db) ...@@ -624,7 +624,10 @@ void WriteTitle(std::ostream& pdbFile, Datablock& db)
pdbFile << (boost::format(" %-6.6s") % (i < types.size() ? types[i] : std::string())).str(); pdbFile << (boost::format(" %-6.6s") % (i < types.size() ? types[i] : std::string())).str();
pdbFile << std::endl; pdbFile << std::endl;
types.erase(types.begin(), types.begin() + std::min(types.size(), 4UL)); if (types.size() > 4)
types.erase(types.begin(), types.begin() + 4);
else
types.clear();
} }
while (types.empty() == false); while (types.empty() == false);
} }
......
...@@ -7,9 +7,18 @@ if [ "$EUID" -ne 0 ] ...@@ -7,9 +7,18 @@ if [ "$EUID" -ne 0 ]
exit exit
fi fi
# create cache directory if it doesn't exist if [ -f /etc/libcifpp.conf ] ; then
. /etc/libcifpp.conf
fi
# check to see if we're supposed to run at all
if [ "$update" != "true" ] ; then
exit
fi
# if cache directory doesn't exist, exit.
if ! [ -d /var/cache/libcifpp ]; then if ! [ -d /var/cache/libcifpp ]; then
install -d -m755 /var/cache/libcifpp exit
fi fi
# fetch the dictionary # fetch the dictionary
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment