mirror of
https://github.com/gnss-sdr/gnss-sdr
synced 2025-11-13 21:57:14 +00:00
Now GNSS-SDR also builds on Mac OS X 10.9 Mavericks using clang++ and libc++. Updated cmake scripts, some modification of code not accepted by clang. Updated README with instructions for Mavericks. Fixed file length computation in 64-bit architectures.
git-svn-id: https://svn.code.sf.net/p/gnss-sdr/code/trunk@435 64b25241-fba3-4117-9849-534c7e92360d
This commit is contained in:
@@ -90,5 +90,9 @@ include_directories(
|
||||
${Boost_INCLUDE_DIRS}
|
||||
)
|
||||
|
||||
if(ARCH_64BITS)
|
||||
add_definitions(-DARCH_64BITS=1)
|
||||
endif(ARCH_64BITS)
|
||||
|
||||
add_library(signal_source_adapters ${SIGNAL_SOURCE_ADAPTER_SOURCES})
|
||||
target_link_libraries(signal_source_adapters signal_source_gr_blocks ${Boost_LIBRARIES} ${GNURADIO_PMT_LIBRARIES} ${GNURADIO_BLOCKS_LIBRARIES} ${UHD_LIBRARIES} ${GNURADIO_UHD_LIBRARIES} ${OPT_LIBRARIES} gnss_sp_libs)
|
||||
|
||||
@@ -142,13 +142,16 @@ FileSignalSource::FileSignalSource(ConfigurationInterface* configuration,
|
||||
|
||||
if (size > 0)
|
||||
{
|
||||
samples_ = floor((double)size / (double)item_size() - ceil(0.002 * (double)sampling_frequency_)); //process all the samples available in the file excluding the last 2 ms
|
||||
samples_ = floor((double)size / (double)item_size() - ceil(0.002 * (double)sampling_frequency_)); //process all the samples available in the file excluding at least the last 1 ms
|
||||
}
|
||||
}
|
||||
|
||||
CHECK(samples_ > 0) << "File does not contain enough samples to process.";
|
||||
double signal_duration_s;
|
||||
signal_duration_s = (double)samples_ * ( 1 /(double)sampling_frequency_);
|
||||
#ifdef ARCH_64BITS
|
||||
signal_duration_s /= 2;
|
||||
#endif
|
||||
DLOG(INFO) << "Total number samples to be processed= " << samples_ << " GNSS signal duration= " << signal_duration_s << " [s]";
|
||||
std::cout << "GNSS signal recorded time to be processed: " << signal_duration_s << " [s]" << std::endl;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user