Commit Graph

22 Commits

Author SHA1 Message Date
iphydf
c037100747
Import the hstox SUT interface from hstox.
We'll maintain it in the c-toxcore repo, where it belongs.
2016-10-01 02:13:34 +01:00
iphydf
e59fd26d49
Add OSX and Windows build to travis config.
Tests for Windows are disabled for now, until we figure out which tests
can successfully run on wine and select only those.
2016-09-20 13:52:33 +01:00
iphydf
67ac9138ab
Add STRICT_ABI cmake flag to generate export lists.
Enabling this flag will generate and use an LD version script. It
ensures that the dynamic libraries (libtoxcore.so, libtoxav.so) only
export the symbols that are defined in their public API (tox.h and
toxav.h, respectively).
2016-09-19 19:42:12 +01:00
iphydf
37c041f815
Clean up Travis build a bit in preparation for osx/win. 2016-09-16 11:22:23 +01:00
iphydf
c0d84ab489
Remove format-source from travis script.
This test is already performed by `make test` later on. We originally
had it in the Travis script to make it fail fast when the format is
wrong, but there is also some value in running all tests despite format
errors.

Fixes #83. There are no more relevant phases that would benefit from the
padding lines proposed.
2016-09-16 11:05:54 +01:00
iphydf
2db31d95fd
Use "phase" script for travis build phases.
This is the first step towards unifying travis configs for toxcore,
hstox, and qtox.
2016-09-11 22:13:47 +01:00
iphydf
6683a4b284
Use TokTok's apidsl instead of the iphydf one. 2016-09-11 21:09:41 +01:00
iphydf
254feb0acd
Add address sanitizer option to cmake file. 2016-09-08 10:13:40 +01:00
iphydf
13ae9e9a93
Move logging to a callback.
This removes the global logger (which by the way was deleted when the first tox
was killed, so other toxes would then stop logging). Various bits of the code
now carry a logger or pass it around. It's a bit less transparent now, but now
there is no need to have a global logger, and clients can decide what to log and
where.
2016-08-27 01:16:14 +01:00
iphydf
7075c3648a
Add cmake test for apidsl. 2016-08-24 09:41:40 +01:00
iphydf
f9c83c1084
Build assoc DHT code on travis. 2016-08-20 00:59:22 +01:00
iphydf
c597f67012
Add format-source script.
This is easier to use from a precommit hook, so it can be used to ensure that
all formatting is correct before committing code.
2016-08-20 00:39:18 +01:00
iphydf
a5e35180c7
Make tox_callback_friend_name stateless.
See #27 and #40 for details.
2016-08-18 00:01:53 +01:00
iphydf
db22522741
Add missing DHT_bootstrap to CMakeLists.txt.
- This PR also adds a DEBUG cmake option that enables -DTOX_DEBUG.
- We also remove `-Wall`, because there are too many warnings, and nobody really
  looks at them at the moment. We'll see about fixing them soon. We'll also want
  to enable `-Werror` at some point.
- Finally, this PR enables `-O3` to make sure toxcore still works correctly
  under heavy compiler optimisations.
2016-08-17 22:12:39 +01:00
iphydf
2fc5449870
Try searching for libsodium with pkg-config in ./configure.
If libsodium can't be found with PKG_CHECK_MODULES, try AC_CHECK_LIB. If that
also fails, abort configure. If a user passes --with-libsodium-libs explicitly,
that overrides the pkg-config found location.
2016-08-17 21:28:44 +01:00
iphydf
cebf64a588
Split toxcore into layers.
This allows us to more clearly define interfaces between modules, and have the
linker help us ensure that module boundaries are respected.

The onion/tcp/net_crypto layer is a bit too large. This is due to a cyclic
dependency (onion -> net_crypto -> TCP -> onion). We may or may not want to
break that cycle in the future to allow the onion library to exist on its own
without net_crypto.
2016-08-16 17:36:18 +01:00
iphydf
35932b5381
Add "make install" step to Travis build. 2016-08-12 20:49:50 +02:00
iphydf
f7324f997b
Only report coverage on clang, not on the GCC build. 2016-08-12 01:54:42 +01:00
iphydf
b5cfd33340
Add and use CMake build script
Also, fix the hstox build that was taking half an hour. It now takes 5 minutes.
Also, perform distcheck on travis to ensure that make dist works. It's not
actually failing the build at the moment due to broken tests.
2016-08-12 01:13:11 +01:00
iphydf
459f8f2013
Check code formatting on Travis.
We run astyle on Travis and check if there is a diff. The build terminates if
git finds a difference.
2016-08-12 01:00:00 +01:00
iphydf
8339e3449f
Run hstox test suite against toxcore on Travis. 2016-08-12 00:22:09 +01:00
iphydf
50921070ce
Move toxcore travis build scripts out of .travis.yml.
This is in preparation for having multiple types of build. One of the future
builds will be a hstox build, another may be frama-c or some other static
analyser. It makes sense to split these up into multiple builds, because each of
them can take a while, and running them in parallel will speed things up. Also,
the hstox test coverage should be reported separately from the toxcore auto_test
coverage.
2016-08-12 00:07:05 +01:00