[package] name = "cld2-sys" version = "1.0.2" authors = ["Eric Kidd "] links = "cld2" build = "build.rs" description = "Unsafe, low-level wrapper for cld2 language detection library" license = "Unlicense/Apache-2.0" documentation = "http://docs.rs/cld2-sys/" repository = "https://github.com/emk/rust-cld2" # We need to strip the cld2 source tree down dramatically to fit it in a # 10MB Rust package. We start upstream, by remove a large unit-test data # file and stripping line comments out of the generated files. Then we # strip out the docs directory, our own table-stripping script, plus a list # of source files that we're not actually building. Last, we strip out all # compiled code (*_chrome_* and *.o files). # # The command used to generate the list of unused *.cc files below looked # something like this: # # diff <(cat ../../built_sources.txt | sort) \ # <(ls *.cc | sort) | grep '>' | sed 's/^> //' # # If we were feeling ambitious, we could modify build.rs to parse this # list using a toml parser, compare it against the source directly, and # generate a list of files to compile. exclude = [ "*.o", "*_chrome_*", "cld2/docs/**", "cld2/strip_tables.sh", "cld2/internal/cld2_do_score.cc", "cld2/internal/cld2_dynamic_data.cc", "cld2/internal/cld2_dynamic_data_extractor.cc", "cld2/internal/cld2_dynamic_data_loader.cc", "cld2/internal/cld2_dynamic_data_tool.cc", "cld2/internal/cld2_generated_deltaocta0527.cc", "cld2/internal/cld2_generated_deltaoctachrome.cc", "cld2/internal/cld2_generated_distinctocta0527.cc", "cld2/internal/cld2_generated_distinctoctachrome.cc", "cld2/internal/cld2_generated_octa2_dummy.cc", "cld2/internal/cld2_generated_quad0720.cc", "cld2/internal/cld2_generated_quadchrome_16.cc", "cld2/internal/cld2_generated_quadchrome_2.cc", "cld2/internal/cld2_unittest.cc", "cld2/internal/cld2_unittest_full.cc", "cld2/internal/cld_generated_cjk_delta_bi_4.cc", "cld2/internal/cld_generated_score_quad_octa_0122_2.cc", "cld2/internal/cld_generated_score_quad_octa_1024_256.cc", "cld2/internal/cld_generated_score_quad_octa_2.cc", "cld2/internal/cldutil_offline.cc", "cld2/internal/compact_lang_det_test.cc", "cld2/internal/debug_empty.cc", "cld2/internal/scoreutf8text.cc" ] [badges] maintenance = { status = "deprecated" } [dependencies] libc = "0.2.2" [build-dependencies] gcc = "0.3.38" toml = "0.1.23" regex = "0.1.41"