Permalink
Browse files

Reorganizing to reduce linking time (tested on OSX)

  • Loading branch information...
1 parent 485c7db commit 63cda0614f4835d1b0b79d36b8ccf34876b69c91 Zack Moratto committed Sep 19, 2009
View
@@ -148,10 +148,10 @@ AX_PKG_ONE_OF(LAPACK,
AX_GROUP_PKG(STANDALONE_FLAPACK_FBLAS, [STANDALONE_FLAPACK STANDALONE_FBLAS STANDALONE_F2C])])
AX_PKG(VW_CORE, [BOOST BOOST_THREAD BOOST_PROGRAM_OPTIONS BOOST_FILESYSTEM LAPACK], [-lvwCore], [vw/Core/Log.h] )
-AX_PKG(VW_IMAGE, [VW_CORE], [-lvwImage], [vw/Image/ImageView.h])
AX_PKG(VW_MATH, [VW_CORE], [-lvwMath], [vw/Math/LinearAlgebra.h])
+AX_PKG(VW_IMAGE, [VW_CORE], [-lvwImage], [vw/Image/ImageView.h])
AX_PKG(VW_FILEIO, [VW_IMAGE VW_CORE], [-lvwFileIO], [vw/FileIO/DiskImageResourceOpenEXR.h])
-AX_GROUP_PKG(VW, [VW_CORE VW_IMAGE VW_MATH VW_FILEIO])
+AX_GROUP_PKG(VW, [VW_CORE VW_MATH VW_IMAGE VW_FILEIO])
AX_PKG(VW_CAMERA, [VW BOOST_IOSTREAMS], [-lvwCamera], [vw/Camera/CAHVModel.h])
AX_PKG(VW_STEREO, [VW VW_CAMERA], [-lvwStereo], [vw/Stereo/OptimizedCorrelator.h])
@@ -230,25 +230,25 @@ AX_GROUP_PKG(BOOST_COMMON, [BOOST BOOST_PROGRAM_OPTIONS])
AX_GROUP_PKG(BOOST_ALL, [BOOST_COMMON BOOST_FILESYSTEM BOOST_SYSTEM BOOST_DATETIME BOOST_THREAD BOOST_IOSTREAMS])
AX_GROUP_PKG(VW_ALL, [VW VW_CAMERA VW_CARTOGRAPHY VW_STEREO VW_INTEREST_POINT])
-AX_MODULE(CORE, [src/asp/Core], [libaspCore.la], yes, [], [BOOST_ALL VW_ALL], [LAPACK OPENSCENEGRAPH])
-AX_MODULE(SPICEIO, [src/asp/SpiceIO], [libaspSpiceIO.la], yes, [CORE], [SPICE], [] )
-AX_MODULE(ISISIO, [src/asp/IsisIO], [libaspIsisIO.la], yes, [CORE], [ISIS VW VW_CAMERA], [] )
-AX_MODULE(SESSIONS, [src/asp/Sessions], [libaspSessions.la], yes, [ISISIO], [BOOST_COMMON], [SPICEIO ISISIO])
+AX_MODULE(CORE, [src/asp/Core], [libaspCore.la], yes, [], [BOOST_COMMON BOOST_FILESYSTEM BOOST_SYSTEM BOOST_THREAD VW_ALL], [LAPACK])
+AX_MODULE(SPICEIO, [src/asp/SpiceIO], [libaspSpiceIO.la], yes, [], [VW BOOST SPICE], [] )
+AX_MODULE(ISISIO, [src/asp/IsisIO], [libaspIsisIO.la], yes, [], [BOOST ISIS VW VW_CAMERA VW_CARTOGRAPHY], [] )
+AX_MODULE(SESSIONS, [src/asp/Sessions], [libaspSessions.la], yes, [CORE], [], [SPICEIO ISISIO])
-AX_APP(STEREO, [src/asp/Tools], yes, [BOOST_ALL VW_ALL LAPACK CORE SESSIONS], [SPICEIO ISISIO])
-AX_APP(ORTHOPROJECT, [src/asp/Tools], yes, [BOOST_ALL VW_ALL LAPACK CORE SESSIONS], [SPICEIO ISISIO])
-AX_APP(BUNDLEADJUST, [src/asp/Tools], no, [BOOST_ALL VW_ALL LAPACK CORE SESSIONS], [SPICEIO ISISIO])
-AX_APP(ORBITVIZ, [src/asp/Tools], yes, [BOOST_ALL VW_ALL LAPACK CORE SESSIONS], [SPICEIO ISISIO])
+AX_APP(STEREO, [src/asp/Tools], yes, [CORE SESSIONS])
+AX_APP(ORTHOPROJECT, [src/asp/Tools], yes, [CORE SESSIONS])
+AX_APP(BUNDLEADJUST, [src/asp/Tools], no, [CORE SESSIONS])
+AX_APP(ORBITVIZ, [src/asp/Tools], yes, [SESSIONS])
AX_APP(DISPARITYDEBUG, [src/asp/Tools], yes, [BOOST_COMMON VW VW_STEREO])
-AX_APP(POINT2MESH, [src/asp/Tools], yes, [BOOST_COMMON VW OPENSCENEGRAPH CORE])
+AX_APP(POINT2MESH, [src/asp/Tools], yes, [BOOST_COMMON VW OPENSCENEGRAPH])
AX_APP(POINT2MESH2, [src/asp/Tools], yes, [BOOST_COMMON VW OPENSCENEGRAPH])
-AX_APP(POINT2DEM, [src/asp/Tools], yes, [BOOST_COMMON VW VW_CARTOGRAPHY CORE])
-AX_APP(CTXIMAGE, [src/asp/Tools], no, [BOOST_COMMON VW VW_CARTOGRAPHY CORE])
-AX_APP(RMAX2CAHVOR, [src/asp/Tools], no, [BOOST_COMMON VW VW_CAMERA BOOST_FILESYSTEM SESSIONS])
-AX_APP(RMAXADJUST, [src/asp/Tools], no, [BOOST_ALL VW_ALL LAPACK CORE SESSIONS])
+AX_APP(POINT2DEM, [src/asp/Tools], yes, [CORE])
+AX_APP(CTXIMAGE, [src/asp/Tools], no, [CORE])
+AX_APP(RMAX2CAHVOR, [src/asp/Tools], no, [SESSIONS])
+AX_APP(RMAXADJUST, [src/asp/Tools], no, [CORE SESSIONS])
AX_APP(BUNDLEVIS, [src/asp/Tools], no, [BOOST_COMMON OPENSCENEGRAPH VW VW_CAMERA])
-AX_APP(ISISADJUST, [src/asp/Tools], yes, [BOOST_ALL VW_ALL LAPACK CORE ISISIO])
-AX_APP(RESULTS, [src/asp/Tools], yes, [BOOST_ALL VW_ALL ISISIO])
+AX_APP(ISISADJUST, [src/asp/Tools], yes, [CORE ISISIO])
+AX_APP(RESULTS, [src/asp/Tools], yes, [ISISIO])
AX_APP(RECONSTRUCT, [src/asp/Tools], no, [BOOST_ALL VW VW_CARTOGRAPHY])
View
@@ -28,20 +28,15 @@
#ifndef __ASP_CORE_H__
#define __ASP_CORE_H__
-#include <asp/Core/BaseEquation.h>
#include <asp/Core/BlobIndexThreaded.h>
#include <asp/Core/BundleAdjustUtils.h>
#include <asp/Core/CameraAdjust.h>
#include <asp/Core/ControlNetworkLoader.h>
#include <asp/Core/DiskImageResourceDDD.h>
-#include <asp/Core/Equation.h>
#include <asp/Core/InpaintView.h>
#include <asp/Core/OrthoRasterizer.h>
-#include <asp/Core/PolyEquation.h>
-#include <asp/Core/RPNEquation.h>
#include <asp/Core/SoftwareRenderer.h>
#include <asp/Core/SparseView.h>
#include <asp/Core/StereoSettings.h>
-#include <asp/Core/nff_terrain.h>
#endif//__ASP_CORE_H__
View
@@ -4,22 +4,15 @@
if MAKE_MODULE_CORE
-include_HEADERS = BaseEquation.h BlobIndexThreaded.h CameraAdjust.h \
+include_HEADERS = BlobIndexThreaded.h CameraAdjust.h StereoSettings.h \
ControlNetworkLoader.h DiskImageResourceDDD.h \
- Equation.h InpaintView.h MedianFilter.h \
- OrthoRasterizer.h PolyEquation.h RPNEquation.h \
- SoftwareRenderer.h SparseView.h StereoSettings.h
+ InpaintView.h MedianFilter.h SparseView.h \
+ OrthoRasterizer.h SoftwareRenderer.h SparseView.h
libaspCore_la_SOURCES = BlobIndexThreaded.cc BundleAdjustUtils.cc \
ControlNetworkLoader.cc DiskImageResourceDDD.cc \
- Equation.cc PolyEquation.cc RPNEquation.cc \
SoftwareRenderer.cc StereoSettings.cc
-if HAVE_PKG_OPENSCENEGRAPH
- include_HEADERS += nff_terrain.h
- libaspCore_la_SOURCES += nff_terrain.cc
-endif
-
libaspCore_la_LIBADD = @MODULE_CORE_LIBS@
lib_LTLIBRARIES = libaspCore.la
View
@@ -4,6 +4,11 @@
#include <asp/asp_config.h>
+#include <asp/IsisIO/BaseEquation.h>
+#include <asp/IsisIO/Equation.h>
+#include <asp/IsisIO/PolyEquation.h>
+#include <asp/IsisIO/RPNEquation.h>
+
#if defined(ASP_HAVE_PKG_ISIS) && ASP_HAVE_PKG_ISIS == 1
#include <asp/IsisIO/DiskImageResourceIsis.h>
#include <asp/IsisIO/IsisAdjustCameraModel.h>
File renamed without changes.
@@ -21,7 +21,7 @@
//
// __END_LICENSE__
-#include <asp/Core/Equation.h>
+#include <asp/IsisIO/Equation.h>
using namespace vw;
using namespace camera;
@@ -24,9 +24,9 @@
#ifndef __VW_CAMERA_EQUATION_H__
#define __VW_CAMERA_EQUATION_H__
-#include <asp/Core/BaseEquation.h>
-#include <asp/Core/PolyEquation.h>
-#include <asp/Core/RPNEquation.h>
+#include <asp/IsisIO/BaseEquation.h>
+#include <asp/IsisIO/PolyEquation.h>
+#include <asp/IsisIO/RPNEquation.h>
namespace vw {
namespace camera {
@@ -36,7 +36,7 @@
// ASP
#include <asp/IsisIO/IsisCameraModel.h>
-#include <asp/Core/Equation.h>
+#include <asp/IsisIO/Equation.h>
// Isis Header
#include <Cube.h>
View
@@ -4,11 +4,13 @@
if MAKE_MODULE_ISISIO
-include_HEADERS = DiskImageResourceIsis.h IsisAdjustCameraModel.h \
- IsisCameraModel.h
+include_HEADERS = BaseEquation.h Equation.h PolyEquation.h \
+ DiskImageResourceIsis.h IsisAdjustCameraModel.h \
+ IsisCameraModel.h RPNEquation.h
-libaspIsisIO_la_SOURCES = DiskImageResourceIsis.cc \
- IsisAdjustCameraModel.cc IsisCameraModel.cc
+libaspIsisIO_la_SOURCES = DiskImageResourceIsis.cc Equation.cc \
+ IsisAdjustCameraModel.cc IsisCameraModel.cc \
+ PolyEquation.cc RPNEquation.cc
libaspIsisIO_la_LIBADD = @MODULE_ISISIO_LIBS@
@@ -24,7 +24,7 @@
// STL
#include <iomanip>
// ASP
-#include <asp/Core/PolyEquation.h>
+#include <asp/IsisIO/PolyEquation.h>
// Boost
#include <boost/algorithm/string.hpp>
@@ -24,7 +24,7 @@
#ifndef __VW_CAMERA_POLY_EQUATION__
#define __VW_CAMERA_POLY_EQUATION__
-#include <asp/Core/BaseEquation.h>
+#include <asp/IsisIO/BaseEquation.h>
namespace vw {
namespace camera {
@@ -25,7 +25,7 @@
#include <iomanip>
#include <stack>
// ASP
-#include <asp/Core/RPNEquation.h>
+#include <asp/IsisIO/RPNEquation.h>
// BOOST
#include <boost/algorithm/string.hpp>
@@ -27,7 +27,7 @@
// STL
#include <vector>
// ASP
-#include <asp/Core/BaseEquation.h>
+#include <asp/IsisIO/BaseEquation.h>
namespace vw{
namespace camera{
View
@@ -28,38 +28,19 @@ bin_PROGRAMS =
if MAKE_APP_STEREO
bin_PROGRAMS += stereo
stereo_SOURCES = stereo.cc
- stereo_LDADD = $(APP_STEREO_LIBS) @PKG_CORE_LIBS@ @PKG_SESSIONS_LIBS@
-
-if HAVE_PKG_ISIS
- stereo_LDADD += @PKG_ISISIO_LIBS@
-endif
-if HAVE_PKG_SPICE
- stereo_LDADD += @PKG_SPICEIO_LIBS@
-endif
+ stereo_LDADD = $(APP_STEREO_LIBS)
endif
if MAKE_APP_BUNDLEADJUST
bin_PROGRAMS += bundle_adjust
bundle_adjust_SOURCES = bundle_adjust.cc
- bundle_adjust_LDADD = $(APP_BUNDLEADJUST_LIBS) @PKG_CORE_LIBS@ @PKG_SESSIONS_LIBS@
-if HAVE_PKG_ISIS
- bundle_adjust_LDADD += @PKG_ISISIO_LIBS@
-endif
-if HAVE_PKG_SPICE
- bundle_adjust_LDADD += @PKG_SPICEIO_LIBS@
-endif
+ bundle_adjust_LDADD = $(APP_BUNDLEADJUST_LIBS)
endif
if MAKE_APP_ORBITVIZ
bin_PROGRAMS += orbitviz
orbitviz_SOURCES = orbitviz.cc
- orbitviz_LDADD = $(APP_ORBITVIZ_LIBS) @PKG_CORE_LIBS@ @PKG_SESSIONS_LIBS@
-if HAVE_PKG_ISIS
- orbitviz_LDADD += @PKG_ISISIO_LIBS@
-endif
-if HAVE_PKG_SPICE
- orbitviz_LDADD += @PKG_SPICEIO_LIBS@
-endif
+ orbitviz_LDADD = $(APP_ORBITVIZ_LIBS)
endif
if MAKE_APP_DISPARITYDEBUG
@@ -70,38 +51,38 @@ endif
if MAKE_APP_POINT2MESH
bin_PROGRAMS += point2mesh
- point2mesh_SOURCES = point2mesh.cc
- point2mesh_LDADD = $(APP_POINT2MESH_LIBS) @PKG_CORE_LIBS@
+ point2mesh_SOURCES = point2mesh.cc nff_terrain.h nff_terrain.cc
+ point2mesh_LDADD = $(APP_POINT2MESH_LIBS)
endif
if MAKE_APP_POINT2DEM
bin_PROGRAMS += point2dem
point2dem_SOURCES = point2dem.cc
- point2dem_LDADD = $(APP_POINT2DEM_LIBS) @PKG_CORE_LIBS@
+ point2dem_LDADD = $(APP_POINT2DEM_LIBS)
endif
if MAKE_APP_CTXIMAGE
bin_PROGRAMS += ctximage
ctximage_SOURCES = ctximage.cc
- ctximage_LDADD = $(APP_CTXIMAGE_LIBS) @PKG_CORE_LIBS@
+ ctximage_LDADD = $(APP_CTXIMAGE_LIBS)
endif
if MAKE_APP_RMAX2CAHVOR
bin_PROGRAMS += rmax2cahvor
rmax2cahvor_SOURCES = rmax2cahvor.cc
- rmax2cahvor_LDADD = $(APP_RMAX2CAHVOR_LIBS) @PKG_CORE_LIBS@ @PKG_SESSIONS_LIBS@
+ rmax2cahvor_LDADD = $(APP_RMAX2CAHVOR_LIBS)
endif
if MAKE_APP_RMAXADJUST
bin_PROGRAMS += rmax_adjust
rmax_adjust_SOURCES = rmax_adjust.cc
- rmax_adjust_LDADD = $(APP_RMAXADJUST_LIBS) @PKG_CORE_LIBS@ @PKG_SESSIONS_LIBS@
+ rmax_adjust_LDADD = $(APP_RMAXADJUST_LIBS)
endif
if MAKE_APP_ISISADJUST
bin_PROGRAMS += isis_adjust
isis_adjust_SOURCES = isis_adjust.cc
- isis_adjust_LDADD = $(APP_ISISADJUST_LIBS) @PKG_CORE_LIBS@ @PKG_ISISIO_LIBS@
+ isis_adjust_LDADD = $(APP_ISISADJUST_LIBS)
endif
if MAKE_APP_BUNDLEVIS
@@ -119,13 +100,13 @@ endif
if MAKE_APP_ORTHOPROJECT
bin_PROGRAMS += orthoproject
orthoproject_SOURCES = orthoproject.cc
- orthoproject_LDADD = $(APP_ORTHOPROJECT_LIBS) @PKG_CORE_LIBS@ @PKG_SESSIONS_LIBS@
+ orthoproject_LDADD = $(APP_ORTHOPROJECT_LIBS)
endif
if MAKE_APP_RESULTS
bin_PROGRAMS +=results
results_SOURCES = results.cc
- results_LDADD = $(APP_RESULTS_LIBS) @PKG_ISISIO_LIBS@
+ results_LDADD = $(APP_RESULTS_LIBS)
endif
if MAKE_APP_RECONSTRUCT
@@ -141,4 +122,8 @@ endif
AM_CPPFLAGS = @ASP_CPPFLAGS@
AM_LDFLAGS = @ASP_LDFLAGS@
+SUBDIRS = .
+
+includedir = $(prefix)/include/asp/Tools
+
include $(top_srcdir)/config/rules.mak
@@ -50,7 +50,6 @@ using namespace vw::ip;
#include <iomanip>
// Ames Stereo Pipeline
-#include <asp/Core/Equation.h>
#include <asp/Core/ControlNetworkLoader.h>
#include <asp/IsisIO.h>
#include <asp/Sessions/StereoSession.h>
@@ -66,7 +66,7 @@
// ASP includes:
#include <asp/asp_config.h>
-#include <asp/Core/nff_terrain.h>
+#include <asp/Tools/nff_terrain.h>
// VW
#include <vw/Core/Exception.h>
File renamed without changes.
@@ -46,7 +46,6 @@ namespace po = boost::program_options;
using namespace vw;
using namespace vw::cartography;
-#include <asp/Core/nff_terrain.h>
#include <asp/Core/OrthoRasterizer.h>
// Erases a file suffix if one exists and returns the base string
@@ -44,7 +44,7 @@ namespace po = boost::program_options;
#include <vw/Math.h>
using namespace vw;
-#include <asp/Core/nff_terrain.h>
+#include <asp/Tools/nff_terrain.h>
// Erases a file suffix if one exists and returns the base string
static std::string prefix_from_pointcloud_filename(std::string const& filename) {
View
@@ -134,7 +134,7 @@ void print_usage(po::options_description const& visible_options) {
// Correlator View
template <class FilterT>
-CorrelatorView<PixelGray<float>,vw::uint8,FilterT>
+inline CorrelatorView<PixelGray<float>,vw::uint8,FilterT>
correlator_helper( DiskImageView<PixelGray<float> > & left_disk_image,
DiskImageView<PixelGray<float> > & right_disk_image,
DiskImageView<vw::uint8> & left_mask,
@@ -505,7 +505,7 @@ int main(int argc, char* argv[]) {
// OpenEXR.
DiskImageResourceOpenEXR disparity_map_rsrc(out_prefix + "-D.exr", disparity_map.format() );
disparity_map_rsrc.set_tiled_write(std::min(vw_settings().default_tile_size(),disparity_map.cols()),
- std::min(vw_settings().default_tile_size(),disparity_map.rows()));
+ std::min(vw_settings().default_tile_size(),disparity_map.rows()), true);
block_write_image( disparity_map_rsrc, disparity_map );
}

0 comments on commit 63cda06

Please sign in to comment.