r7930: fixes for backproject and pjrec
authorKevin M. Rosenberg <kevin@rosenberg.net>
Tue, 30 Sep 2003 18:36:28 +0000 (18:36 +0000)
committerKevin M. Rosenberg <kevin@rosenberg.net>
Tue, 30 Sep 2003 18:36:28 +0000 (18:36 +0000)
Makefile.in
configure
configure.ac
debian/changelog
libctsim/backprojectors.cpp
tools/pjrec.cpp

index 4d72d32f89a3e55f281544c9056658e851cf5353..c6a9269f67f52ed01ef95af6817ddd1a8ec991da 100644 (file)
@@ -160,8 +160,8 @@ webenabled = @webenabled@
 wxcflags = @wxcflags@
 wxconfig = @wxconfig@
 wxlibs = @wxlibs@
-@INCLUDED_GETOPT_LONG_TRUE@EXTRA_DIRS1 = getopt
 @INCLUDED_GETOPT_LONG_FALSE@EXTRA_DIRS1 = 
+@INCLUDED_GETOPT_LONG_TRUE@EXTRA_DIRS1 = getopt
 
 @HAVE_SGP_TRUE@EXTRA_DIRS2 = libctgraphics
 @HAVE_SGP_FALSE@EXTRA_DIRS2 = 
index fc903ac365fc309e98482658ae1dc2b4287aa8c4..353929bf03a449359a48d2f179a5bf0654b0e816 100755 (executable)
--- a/configure
+++ b/configure
@@ -308,7 +308,7 @@ ac_includes_default="\
 # include <unistd.h>
 #endif"
 
-ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS MAINTAINER_MODE_TRUE MAINTAINER_MODE_FALSE MAINT INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA CYGPATH_W PACKAGE VERSION ACLOCAL AUTOCONF AUTOMAKE AUTOHEADER MAKEINFO AMTAR install_sh STRIP ac_ct_STRIP INSTALL_STRIP_PROGRAM AWK SET_MAKE am__leading_dot RANLIB ac_ct_RANLIB CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT DEPDIR am__include am__quote AMDEP_TRUE AMDEP_FALSE AMDEPBACKSLASH CCDEPMODE am__fastdepCC_TRUE am__fastdepCC_FALSE CXX CXXFLAGS ac_ct_CXX CXXDEPMODE am__fastdepCXX_TRUE am__fastdepCXX_FALSE wxconfig build build_cpu build_vendor build_os host host_cpu host_vendor host_os CPP EGREP INCLUDED_GETOPT_LONG_TRUE INCLUDED_GETOPT_LONG_FALSE DEBUG_TRUE DEBUG_FALSE lamdir mpienable cgibindir cgibinurl webdatadir webdataurl htmldir cgiprograms htmldata USE_HTML_TRUE USE_HTML_FALSE webenabled USE_LAM_TRUE USE_LAM_FALSE X_CFLAGS X_PRE_LIBS X_LIBS X_EXTRA_LIBS X_TOOLKIT_LIBS X_BASIC_LIBS NO_X_TRUE NO_X_FALSE my_includes HAVE_SGP_TRUE HAVE_SGP_FALSE HAVE_WXWINDOWS_TRUE HAVE_WXWINDOWS_FALSE wxcflags wxlibs ctlibs lamprograms lamdefs LIBOBJS LTLIBOBJS'
+ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS MAINTAINER_MODE_TRUE MAINTAINER_MODE_FALSE MAINT INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA CYGPATH_W PACKAGE VERSION ACLOCAL AUTOCONF AUTOMAKE AUTOHEADER MAKEINFO AMTAR install_sh STRIP ac_ct_STRIP INSTALL_STRIP_PROGRAM AWK SET_MAKE am__leading_dot RANLIB ac_ct_RANLIB CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT DEPDIR am__include am__quote AMDEP_TRUE AMDEP_FALSE AMDEPBACKSLASH CCDEPMODE am__fastdepCC_TRUE am__fastdepCC_FALSE CXX CXXFLAGS ac_ct_CXX CXXDEPMODE am__fastdepCXX_TRUE am__fastdepCXX_FALSE wxconfig build build_cpu build_vendor build_os host host_cpu host_vendor host_os CPP EGREP INCLUDED_GETOPT_LONG_TRUE INCLUDED_GETOPT_LONG_FALSE DEBUG_TRUE DEBUG_FALSE lamdir mpienable cgibindir cgibinurl webdatadir webdataurl htmldir cgiprograms htmldata USE_HTML_TRUE USE_HTML_FALSE webenabled USE_LAM_TRUE USE_LAM_FALSE X_CFLAGS X_PRE_LIBS X_LIBS X_EXTRA_LIBS X_TOOLKIT_LIBS X_BASIC_LIBS NO_X_TRUE NO_X_FALSE my_includes HAVE_SGP_TRUE HAVE_SGP_FALSE wxcflags wxlibs HAVE_WXWINDOWS_TRUE HAVE_WXWINDOWS_FALSE ctlibs lamprograms lamdefs LIBOBJS LTLIBOBJS'
 ac_subst_files=''
 
 # Initialize some variables set by options.
@@ -1600,7 +1600,7 @@ fi
 
 # Define the identity of the package.
  PACKAGE=ctsim
- VERSION=4.2.6
+ VERSION=4.2.7
 
 
 cat >>confdefs.h <<_ACEOF
@@ -8076,7 +8076,7 @@ _ACEOF
 fi
 
 
-if test $GETOPTLONG==1; then
+if test "$GETOPTLONG"="1"; then
   INCLUDED_GETOPT_LONG_TRUE=
   INCLUDED_GETOPT_LONG_FALSE='#'
 else
@@ -9741,9 +9741,15 @@ cat >>confdefs.h <<\_ACEOF
 #define HAVE_SGP 1
 _ACEOF
 
+  fi
+else
+  echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
+fi
+
 
 
-if test 1==1; then
+if test "$wxwin" = "true"; then
   HAVE_SGP_TRUE=
   HAVE_SGP_FALSE='#'
 else
@@ -9751,11 +9757,6 @@ else
   HAVE_SGP_FALSE=
 fi
 
-  fi
-else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
-fi
 
 if test "$png" = "true" ; then
   ctlibs_tools="$ctlibs_tools -lpng"
@@ -9956,9 +9957,12 @@ if test "$wxwin" = "true" ; then
   fi
   CFLAGS="$CFLAGS -I../include $wxcflags"
   ctlib_graphics="$ctlib_graphics $wxlibs"
+fi
+
+
 
 
-if test 1==1 ; then
+if test "$wxwin"="true"; then
   HAVE_WXWINDOWS_TRUE=
   HAVE_WXWINDOWS_FALSE='#'
 else
@@ -9966,9 +9970,6 @@ else
   HAVE_WXWINDOWS_FALSE=
 fi
 
-fi
-
-
 
 LDFLAGS="$LDFLAGS -L../libctsupport -L../libctsim"
 ctlibs="$ctlibs_base -lctsim $ctlib_graphics -lctsupport $ctlibs_tools"
@@ -10787,10 +10788,10 @@ s,@NO_X_FALSE@,$NO_X_FALSE,;t t
 s,@my_includes@,$my_includes,;t t
 s,@HAVE_SGP_TRUE@,$HAVE_SGP_TRUE,;t t
 s,@HAVE_SGP_FALSE@,$HAVE_SGP_FALSE,;t t
-s,@HAVE_WXWINDOWS_TRUE@,$HAVE_WXWINDOWS_TRUE,;t t
-s,@HAVE_WXWINDOWS_FALSE@,$HAVE_WXWINDOWS_FALSE,;t t
 s,@wxcflags@,$wxcflags,;t t
 s,@wxlibs@,$wxlibs,;t t
+s,@HAVE_WXWINDOWS_TRUE@,$HAVE_WXWINDOWS_TRUE,;t t
+s,@HAVE_WXWINDOWS_FALSE@,$HAVE_WXWINDOWS_FALSE,;t t
 s,@ctlibs@,$ctlibs,;t t
 s,@lamprograms@,$lamprograms,;t t
 s,@lamdefs@,$lamdefs,;t t
index e9f4c40389fa97e3115bb88eedd10303a38062fc..c684ec16aae13b32d4dfe035a2a15ed338d6964a 100644 (file)
@@ -6,7 +6,7 @@ dnl CDPATH=
 AC_INIT
 AC_CONFIG_SRCDIR([src/ctsim.cpp])
 AM_MAINTAINER_MODE
-AM_INIT_AUTOMAKE(ctsim,4.2.6)
+AM_INIT_AUTOMAKE(ctsim,4.2.7)
 AM_CONFIG_HEADER(config.h)
 
 dnl Checks for programs.
@@ -84,7 +84,7 @@ if test "${getopt_long}" = "false" ; then
   LDFLAGS="$LDFLAGS -L../getopt"
   GETOPTLONG=1
 fi
-AM_CONDITIONAL(INCLUDED_GETOPT_LONG, test $GETOPTLONG==1)
+AM_CONDITIONAL(INCLUDED_GETOPT_LONG, test "$GETOPTLONG"="1")
 
 if test "${readline}" = "true" ; then
   ctlibs_base="$ctlibs_base -lreadline"
@@ -364,12 +364,13 @@ if test "$no_x" != "yes" ; then
   fi
   if test "$wxwin" = "true" ; then
     AC_DEFINE(HAVE_SGP,1,[use sgp library])
-    AM_CONDITIONAL(HAVE_SGP, test 1==1)
   fi
 else
   AC_MSG_RESULT(no)
 fi
 
+AM_CONDITIONAL(HAVE_SGP, test "$wxwin" = "true")
+
 if test "$png" = "true" ; then
   ctlibs_tools="$ctlibs_tools -lpng"
 fi
@@ -439,10 +440,10 @@ if test "$wxwin" = "true" ; then
   fi
   CFLAGS="$CFLAGS -I../include $wxcflags"
   ctlib_graphics="$ctlib_graphics $wxlibs"
-  AM_CONDITIONAL(HAVE_WXWINDOWS, test 1==1 )
 fi
 AC_SUBST(wxcflags)
 AC_SUBST(wxlibs)
+AM_CONDITIONAL(HAVE_WXWINDOWS, test "$wxwin"="true")
 
 dnl Setting projet libraries and includes
 LDFLAGS="$LDFLAGS -L../libctsupport -L../libctsim" 
index c977612f3dc4f51e1b2c910cbc04dbf92ec66a8a..ecf4c9ea6be56cc235d8a67ac0f5a69af24319e7 100644 (file)
@@ -1,3 +1,9 @@
+ctsim (4.2.7-1) unstable; urgency=low
+
+  * Fix conditional AM_CONDITIONAL
+
+ -- Kevin M. Rosenberg <kmr@debian.org>  Mon, 29 Sep 2003 19:47:47 -0600
+
 ctsim (4.2.6-1) unstable; urgency=low
 
   * Update missing file from automake-1.7
index d38b7189f6b6c878b09ec0549dca5daf242ce24e..581b7ff0fccae2c4762723da08331f0f2d6d8b9a 100644 (file)
@@ -588,7 +588,7 @@ BackprojectIntDiff::BackprojectView (const double* const filteredProj, const dou
 #elif SIZEOF_LONG == 8
   static const int scaleShift = 32;
 #endif
-  static const long scale = (1 << scaleShift);
+  static const long scale = (1L << scaleShift);
   static const long scaleBitmask = scale - 1;
   static const long halfScale = scale / 2;
   static const double dInvScale = 1. / scale;
index ea230489c36429778cb9f133499624885a7d49d8..974d62e88b8408225c8859fe62588ce4459ca2fd 100644 (file)
@@ -100,9 +100,7 @@ pjrec_usage (const char *program)
   std::cout << "    trig        Trigometric functions at every point" << std::endl;
   std::cout << "    table       Trigometric functions with precalculated table" << std::endl;
   std::cout << "    diff        Difference method" << std::endl;
-  std::cout << "    diff2       Optimized difference method (default)" << std::endl;
-  std::cout << "    idiff2      Optimized difference method with integer math" << std::endl;
-  std::cout << "    idiff3      Highly-optimized difference method with integer math" << std::endl;
+  std::cout << "    idiff       Difference method with integer math [default]" << std::endl;
   std::cout << "  --filter-param Alpha level for Hamming filter" << std::endl;
   std::cout << "  --trace        Set tracing to level" << std::endl;
   std::cout << "     none        No tracing (default)" << std::endl;
@@ -310,7 +308,12 @@ pjrec_main (int argc, char * const argv[])
 
   imLocal = new ImageFile (nx, ny);
 #else
-  projGlobal.read (pszFilenameProj);
+
+  if (! projGlobal.read (pszFilenameProj)) {
+    fprintf(stderr, "Unable to read projectfile file %s\n", pszFilenameProj);
+    exit(1);
+  }
+
   if (bOptVerbose) {
     std::ostringstream os;
     projGlobal.printScanInfo(os);