Closed DraTeots closed 3 years ago
Ok, there where no claims about single header. Only "header only". Sorry and thanks for the library!!!
The old Makefile
stuff works everywhere (unlike CMake), no extra stuff required.
Once it is built you can use it from you CMake files :-)
But the easy way to install is to use it via brew
> brew install thors-serializer`
But building it should be as easy as:
> ./configure
> make
> sudo make install
To use the header only version.
> git clone --single-branch --branch header-only https://github.com/Loki-Astari/ThorsSerializer.git
/PATH/TO/WHERE/I/WANT/TO/INSTALL/ThorsSerializer
g++ -I /PATH/TO/WHERE/I/WANT/TO/INSTALL/ThorsSerializer MyFile.cpp
"Once it is built you can use it from you CMake files :-)"
Do you generate thors-serializerConfig.cmake and thors-serializer.cmake files?
No. But they should be trival to do if you know CMake (which I don't).
The only things you need are:
-I<ThorHeaderDir>
-L<ThorLibraryDir>
-l<libraryName>
Default values are (unless you do something special with the ./configure command)
ThorHeaderDir => /usr/local/include
ThorLibraryDir => /usr/local/lib
libraryName => ThorSerialize17
If you build it but don't install it (i.e. you don't have root access).
THOR_ROOT => <The director where you downloaded from git>/ThorsSerializer
ThorHeaderDir => <THOR_ROOT>/build/include
ThorLibraryDir => <THOR_ROOT>/build/lib
libraryName => ThorSerialize17
If you create one I will add to the project for future developers to use.
According to this page: http://doc.aldebaran.com/qibuild/advanced/guide/cmake/writing_a_config_cmake.html
It should look like this:
clean(ThorsSerializer)
fpath(ThorsSerializer ThorSerialize/JsonThor.h)
flib(ThorsSerializer OPTIMIZED ThorSerialize17)
flib(ThorsSerializer DEBUG ThorSerialize17D)
export_lib(ThorsSerializer)
Let me know if this works.
Massively cleaned up the header only version.
Is your feature request related to a problem? Please describe. "I'm always frustrated when..." it is said there should be a single header file and I can't find it. Even more frustrating, when there is no CMake but old Makefiles (no complains to developers, just our system is CMake centric, so it is our problem, but still...)
Describe the solution you'd like Just make those header only version easy to download and attach to tags
Describe alternatives you've considered Use another library