diff options
author | yuta.256 <yuta.256@b7c3aa3b-274f-0410-ae0b-edc9d07c929d> | 2008-07-03 11:34:07 +0000 |
---|---|---|
committer | yuta.256 <yuta.256@b7c3aa3b-274f-0410-ae0b-edc9d07c929d> | 2008-07-03 11:34:07 +0000 |
commit | 0b0d08bc414f9152b0f7afac36b56b4b30e2679f (patch) | |
tree | e16f192f3e8cfab1a5443b6b62cbd4711fba965b /lib | |
parent | 176b6c50446b4f7ae1e284ae2287f8b1c62811fd (diff) | |
download | platform_external_libdivsufsort-0b0d08bc414f9152b0f7afac36b56b4b30e2679f.tar.gz platform_external_libdivsufsort-0b0d08bc414f9152b0f7afac36b56b4b30e2679f.tar.bz2 platform_external_libdivsufsort-0b0d08bc414f9152b0f7afac36b56b4b30e2679f.zip |
The build system was changed to CMake. (http://www.cmake.org/)
Diffstat (limited to 'lib')
-rw-r--r-- | lib/CMakeLists.txt | 14 | ||||
-rw-r--r-- | lib/Makefile.am | 9 | ||||
-rw-r--r-- | lib/divsufsort.c | 2 | ||||
-rw-r--r-- | lib/libdivsufsort.sym | 8 | ||||
-rw-r--r-- | lib/substringsort.c | 16 | ||||
-rw-r--r-- | lib/trsort.c | 10 |
6 files changed, 28 insertions, 31 deletions
diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt new file mode 100644 index 0000000..e8c5295 --- /dev/null +++ b/lib/CMakeLists.txt @@ -0,0 +1,14 @@ +include_directories("${CMAKE_CURRENT_SOURCE_DIR}/../include" + "${CMAKE_CURRENT_BINARY_DIR}/../include") + +## libdivsufsort ## +add_library(divsufsort divsufsort.c substringsort.c trsort.c utils.c) +install(TARGETS divsufsort + RUNTIME DESTINATION bin + LIBRARY DESTINATION lib + ARCHIVE DESTINATION lib) +set_target_properties(divsufsort PROPERTIES + VERSION "${LIBRARY_VERSION_FULL}" + SOVERSION "${LIBRARY_VERSION_MAJOR}" + DEFINE_SYMBOL DIVSUFSORT_BUILD_DLL + RUNTIME_OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../examples") diff --git a/lib/Makefile.am b/lib/Makefile.am deleted file mode 100644 index cf34c43..0000000 --- a/lib/Makefile.am +++ /dev/null @@ -1,9 +0,0 @@ -# Makefile.am for libdivsufsort - -lib_LTLIBRARIES = libdivsufsort.la -libdivsufsort_la_SOURCES = divsufsort.c substringsort.c trsort.c utils.c -libdivsufsort_la_LDFLAGS = -version-info @LT_CURRENT@:@LT_REVISION@:@LT_AGE@ @LT_NOUNDEF@ -export-symbols libdivsufsort.sym - -AM_CFLAGS = @A_CFLAGS@ - -EXTRA_DIST = libdivsufsort.sym diff --git a/lib/divsufsort.c b/lib/divsufsort.c index 8615246..ac14ea3 100644 --- a/lib/divsufsort.c +++ b/lib/divsufsort.c @@ -358,5 +358,5 @@ divbwt(const sauchar_t *T, sauchar_t *U, saidx_t *A, saidx_t n) { const char * divsufsort_version(void) { - return PACKAGE_VERSION; + return PROJECT_VERSION_FULL; } diff --git a/lib/libdivsufsort.sym b/lib/libdivsufsort.sym deleted file mode 100644 index 2dcda95..0000000 --- a/lib/libdivsufsort.sym +++ /dev/null @@ -1,8 +0,0 @@ -divsufsort -divbwt -divsufsort_version -bw_transform -inverse_bw_transform -sufcheck -sa_search -sa_simplesearch diff --git a/lib/substringsort.c b/lib/substringsort.c index e628f94..d97ebb0 100644 --- a/lib/substringsort.c +++ b/lib/substringsort.c @@ -30,7 +30,7 @@ /*- Private Functions -*/ /* Compares two suffixes. */ -static inline +static INLINE saint_t _compare(const sauchar_t *T, const saidx_t *p1, const saidx_t *p2, @@ -75,7 +75,7 @@ _insertionsort(const sauchar_t *T, const saidx_t *PA, /*---------------------------------------------------------------------------*/ -static inline +static INLINE void _fixdown(const sauchar_t *Td, const saidx_t *PA, saidx_t *SA, saidx_t i, saidx_t size) { @@ -123,7 +123,7 @@ _heapsort(const sauchar_t *Td, const saidx_t *PA, saidx_t *SA, saidx_t size) { /*---------------------------------------------------------------------------*/ /* Returns the median of three elements. */ -static inline +static INLINE saidx_t * _median3(const sauchar_t *Td, const saidx_t *PA, saidx_t *v1, saidx_t *v2, saidx_t *v3) { @@ -137,7 +137,7 @@ _median3(const sauchar_t *Td, const saidx_t *PA, } /* Returns the median of five elements. */ -static inline +static INLINE saidx_t * _median5(const sauchar_t *Td, const saidx_t *PA, saidx_t *v1, saidx_t *v2, saidx_t *v3, saidx_t *v4, saidx_t *v5) { @@ -152,7 +152,7 @@ _median5(const sauchar_t *Td, const saidx_t *PA, } /* Returns the pivot element. */ -static inline +static INLINE saidx_t * _pivot(const sauchar_t *Td, const saidx_t *PA, saidx_t *first, saidx_t *last) { saidx_t *middle; @@ -181,7 +181,7 @@ _pivot(const sauchar_t *Td, const saidx_t *PA, saidx_t *first, saidx_t *last) { /*---------------------------------------------------------------------------*/ -static inline +static INLINE saidx_t _lg(saidx_t n) { static const int log2table[256]= { @@ -212,7 +212,7 @@ static const int log2table[256]= { } /* Binary partition for substrings. */ -static inline +static INLINE saidx_t * _substring_partition(const saidx_t *PA, saidx_t *first, saidx_t *last, saidx_t depth) { @@ -366,7 +366,7 @@ _multikey_introsort(const sauchar_t *T, const saidx_t *PA, /*---------------------------------------------------------------------------*/ /* Block swapping */ -static inline +static INLINE void _block_swap(saidx_t *first1, saidx_t *first2, saidx_t size) { saidx_t *a, *b; diff --git a/lib/trsort.c b/lib/trsort.c index 9e5670e..6f646f1 100644 --- a/lib/trsort.c +++ b/lib/trsort.c @@ -29,7 +29,7 @@ /*- Private Functions -*/ -static inline +static INLINE void _fixdown(const saidx_t *ISAd, saidx_t *SA, saidx_t i, saidx_t size) { saidx_t j, k; @@ -93,7 +93,7 @@ _insertionsort(const saidx_t *ISAd, saidx_t *first, saidx_t *last) { } } -static inline +static INLINE saidx_t _lg(saidx_t n) { static const int log2table[256]= { @@ -126,7 +126,7 @@ static const int log2table[256]= { /*---------------------------------------------------------------------------*/ /* Returns the median of three elements. */ -static inline +static INLINE saidx_t * _median3(const saidx_t *ISAd, saidx_t *v1, saidx_t *v2, saidx_t *v3) { saidx_t *t; @@ -139,7 +139,7 @@ _median3(const saidx_t *ISAd, saidx_t *v1, saidx_t *v2, saidx_t *v3) { } /* Returns the median of five elements. */ -static inline +static INLINE saidx_t * _median5(const saidx_t *ISAd, saidx_t *v1, saidx_t *v2, saidx_t *v3, saidx_t *v4, saidx_t *v5) { @@ -154,7 +154,7 @@ _median5(const saidx_t *ISAd, } /* Returns the pivot element. */ -static inline +static INLINE saidx_t * _pivot(const saidx_t *ISAd, saidx_t *first, saidx_t *last) { saidx_t *middle; |