From: Nathan H. <nj...@nj...> - 2014-07-22 04:15:22
|
I think just embed and prune it. If you note where it came from and remove all the unnecessary stuff it should be pretty lightweight - the algorithm itself is pretty simple. I presume the licences are compatible? njh On Tue, Jul 22, 2014 at 04:54:21AM +0200, Krzysztof Kosiński wrote: > Hello > > To implement a reasonably good SVG path writer, we need a function > that converts a double to the shortest string that will parse back to > the original value. g_ascii_strtod() does not do this. The > state-of-the-art library for this task is libdouble-conversion; the > sources take up around 320 kB. > > Can I use this library as dependency, or should I include its sources > in the 2Geom tree? > > By opting for the latter approach, I could make some tweaks to the > source, e.g. remove unnecessary functions, change it to work with > std::string instead of some strange one-off class and correct some > configuration mistakes; for example, the library always assumes that > 32-bit Linux suffers from double rounding, aka GCC bug 323, whereas > it's sufficient to compile with -mfpmath=sse and the problem goes > away. On the other hand, in-tree libraries are not a good practice in > general. > > Regards, Krzysztof > > ------------------------------------------------------------------------------ > Want fast and easy access to all the code in your enterprise? Index and > search up to 200,000 lines of code with a free copy of Black Duck > Code Sight - the same software that powers the world's largest code > search on Ohloh, the Black Duck Open Hub! Try it now. > http://p.sf.net/sfu/bds > _______________________________________________ > Lib2geom-devel mailing list > Lib...@li... > https://lists.sourceforge.net/lists/listinfo/lib2geom-devel |