Commit Graph

3988 Commits

Author SHA1 Message Date
iphydf
a205b788ad
Disable -Wunused-but-set-variable compiler warning flag.
This warning is triggered in `av_test.c`, where we have an open issue.
Silencing the warning locally would make the issue less visible. This
way, we will see the warning when we start removing the `-Wno-*` flags.
2016-11-11 23:31:13 +00:00
endoffile78
8899b69b40
Add DHT_create_packet 2016-11-11 15:53:04 -06:00
iphydf
fe1fea82c3
Add decode/encode PlainText test support.
These are implemented in terms of decode/encode CipherText. They do the
exact same thing, since they are both simple length-prefixed byte arrays.
2016-11-11 00:00:37 +00:00
iphydf
b2dd50f9fc
Work around Travis issue that causes build failures.
Travis seems to no longer set $TERM, which breaks opam. We now manually
set it to some hopefully sane value.
2016-11-10 23:45:48 +00:00
iphydf
aed24408db
Remove new_nonce function in favour of random_nonce.
`new_nonce` has been an alias for `random_nonce` for a while now. Having
two names for the same operation is confusing. `random_nonce` better
expresses the intent. The documentation for `new_nonce` talks about
guaranteeing that the nonce is different from previous ones, which is
incorrect, it's just quite likely to be different.
2016-11-09 22:30:49 +00:00
iphydf
42dfdf73c1
Add spectest to the cmake test suite.
This allows for easier development. It is not used on travis (yet).
2016-11-08 21:58:26 +00:00
iphydf
dd5e69b3bf
Disable some gcc-specific warnings.
Also, disable -pedantic on C++, because it's not really useful there,
and causes a lot of warnings on `enum FOO { BAR, };` (comma at end of
enumerator list).
2016-11-08 12:03:20 +00:00
iphydf
2a7bc19004
Release v0.0.3. 2016-11-07 00:56:59 +00:00
iphydf
82515f92ee
Move log callback to options.
Previously, all log messages generated by tox_new (which is quite a lot)
were dropped, because client code had no chance to register a logging
callback, yet. This change allows setting the log callback from the
beginning and removes the ability to unset it.

Since the log callback is forever special, since it can't be stateless,
we don't necessarily need to treat it uniformly (with `event`).
2016-11-06 20:35:09 +00:00
iphydf
fcc8ad943e
Rename log levels to remove the extra "LOG" prefix.
`TOX_LOG_LEVEL_LOG_TRACE` => `TOX_LOG_LEVEL_TRACE`.
2016-11-06 19:54:34 +00:00
iphydf
5019a5aaf9
Change packet kind enum to use hex constants.
Hex constants make it clearer that you can only use 2 nibbles (the two
digits of the number, displayed as two columns in the source code), i.e.
1 byte, for the packet kind. It also makes the bit representation easier
to see.
2016-11-06 15:46:27 +00:00
endoffile78
3f53090c1d
Remove assoc 2016-11-06 09:14:53 -06:00
iphydf
7b6b47a610
Enable address sanitizer on the cmake build. 2016-11-06 12:19:34 +00:00
iphydf
cf94537266
Enable all possible C compiler warning flags.
We disable the ones that fire, so we can use -Werror. We can then
investigate each warning individually and see whether to fix it or to
keep silencing it.
2016-11-06 01:32:10 +00:00
Gregory Mullen (grayhatter)
ee3121c3f6
Convert series of NET_PACKET_* defines into a typedef enum
fixup! TravisCI shorten IRC message
2016-11-05 15:12:04 -07:00
iphydf
64870b6fd2
Move packing and unpacking DHT request packets to DHT module.
These definitely don't belong in a module called "crypto core". The DHT
module seems like the best place to put them, since they are sent to DHT
nodes.
2016-11-03 11:56:29 +00:00
iphydf
96c672aef5
Compile as C++ for windows builds.
Compiling as C++ changes nothing semantically, but ensures that we don't
break C++ compatibility while also retaining C compatibility.

C++ compatibility is useful for tooling and additional diagnostics and
analyses.
2016-11-02 18:50:41 +00:00
iphydf
e2d63e0497
Remove unimplemented "time delta" parameter.
In the future, we may want to revisit this parameter, but right now, it
serves no purpose and only confuses tools.
2016-11-02 15:30:40 +00:00
Gregory Mullen (grayhatter)
fba3bfa7a4 TravisCI shorten IRC message 2016-10-30 21:04:54 +00:00
Gregory Mullen (grayhatter)
60e15f165e
Version Patch v0.0.2 2016-10-30 11:16:16 -07:00
iphydf
a1af74fb7a
Rename some internal "group chat" things to "conference".
This is to allow new group chats to coexist with old group chats. We do
not rename everything in group.[ch] to conference, yet, because it's not
currently necessary, and a general internal API overhaul is due at some
point anyway.
2016-10-29 22:37:03 +01:00
Dmytro Vorobiov
59d27e6d94 toxav renaming: group.{h,c} -> groupav.{h,c}
toxav file for "group" conflicts with toxcore "group" file. While this
works fine in almost all cases, Xcode on macOS is confused with that.
2016-10-28 22:11:48 +02:00
iphydf
de966cdf90
Error if format_test can't be executed.
This ensures that on Travis, format_test will always be executed, or the
build fails.
2016-10-26 13:34:29 +01:00
iphydf
09c8575a7d
Merge remote-tracking branch 'zetok/docs-install' 2016-10-26 13:07:26 +01:00
Zetok Zalbavar
f4446ec979
docs: correct instructions for cloning & harden agains repo name changes 2016-10-25 09:36:59 +01:00
Corey Sheldon
0a0e595b67 Corrected libsodium tag
-tags/1.0.3 
+tags/1.0.11

Also expanded the @"Rpm Development Tools"  bit for clarity and sanity across the instructions.
2016-10-25 08:08:18 +00:00
Gregory Mullen (grayhatter)
405dd9bcec
Update readme, moved the roadmap to a higher position 2016-10-17 11:26:17 -07:00
iphydf
6d0c8060c1
Remove duplicate tests: split tests part 2. 2016-10-11 21:29:58 +02:00
iphydf
1ce4c3fe13
Install libraries with RPATH.
This makes deployment easier, as the install libpath is used to look up
dependent libraries.
2016-10-11 14:05:41 +02:00
iphydf
d9f37e4c33
Duplicate tox_test to 4 other files.
In a next step, we will remove tests from each file to have a per-binary
split of tests. This will help identify which tests fail most often on
Travis CI.

In another future step, we will split the large one_test into several
auto tests, which will make testing quite a bit slower (adding about 10
seconds setup time to each), but hopefully a lot more stable ("Tox went
offline" should not happen as much anymore).
2016-10-06 16:46:35 +01:00
iphydf
0fb79c54b8
Set log level for DEBUG=ON to LOG_DEBUG.
We use TRACE=ON (cmake flag) to enable LOG_TRACE. This way, a regular
build can enable DEBUG while not paying the price of TRACE. This is
particularly important for FFI bindings (especially Python), where
invoking callbacks can be an expensive operation.
2016-10-06 15:15:42 +01:00
iphydf
25697990d5
Use socklen_t instead of unsigned int in call to accept.
Not all platforms define `socklen_t` as `unsigned int`. E.g. Android
defines it as `int`.
2016-10-06 11:53:53 +01:00
Maxim Biro
02e9cd38f1 Add option to build tox-bootstrapd
When cross-compiling to <target> from Linux, cmake might find native Linux
libconfig and decide to build tox-bootstrapd. If the target is Windows, this
will fail, as tox-bootstrapd can't be built for Windows in the first place. If
the target is Linux of some other architecture, then using host native
libconfig will fail too. Thus an option is needed to guard against this.
2016-10-05 23:47:39 -04:00
Maxim Biro
90123c803a Align things nicer 2016-10-04 15:44:46 -04:00
Maxim Biro
bf42872bb3 Use TEST_TIMEOUT_SECONDS cmake flag on Travis 2016-10-04 15:32:38 -04:00
Maxim Biro
ac8fb636a1 Add option to set test timeout
Some tests take 20 or more minutes to run before they timeout, this allows
to limit their runtime if needed.
2016-10-04 12:48:24 -04:00
iphydf
b8b9789a69
Rebuild apidsl'd headers in cmake.
- Moved apidsl headers next to their generated versions. In the future,
  perhaps all (or most) headers will be apidsl-generated, so the sources
  should stay together.
- Try to find apidsl/apigen binary and astyle binary and use it for the
  format test. Don't run the format test if these can't be found.
2016-10-02 23:54:03 +01:00
iphydf
66e1bb4510
Remove the _test suffix in auto_test calls.
All tests must end in `_test` so we can use this convention to slightly
shorten the names in `auto_test` calls. This also enforces the
convention so future tests obey it.
2016-10-02 15:14:19 +01:00
iphydf
6d2b85ed06
Minor documentation fixes.
- Fixed incorrect parameter names (documented name didn't match code
  name).
- Removed `@return` from functions that return `void`.
- Make sure every parameter is documented. This required moving the
  planes and strides documentation to the function docs.
2016-10-01 11:17:57 +01:00
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
1977d56caa
Remove return after no-return situation (and other cleanups).
Cleanups:
- Fix header guards to not use reserved names.
- Avoid name shadowing.
- Removed an unused variable found by avoiding name shadowing.
2016-09-30 19:06:44 +01:00
iphydf
949ef785a4
Add the 'Tox' context object to the logger.
We don't currently support callbacks without context object.
2016-09-30 11:39:37 +01:00
Zetok Zalbavar
48ddb11599
docs(INSTALL): update compiling instructions for Linux
Also change links from irungentoo/toxcore to TokTok/toxcore
2016-09-30 08:23:22 +01:00
iphydf
30e86c5eb0
Merge branch 'master' of https://github.com/irungentoo/toxcore 2016-09-29 09:54:53 +01:00
iphydf
36f40f1a4f
Add version-sync script to update all places with versions.
This will update tox.in.h only. Currently, you will still need to
manually update tox.h. An upcoming PR (#154) will update tox.h as
part of the build.
2016-09-28 23:29:36 +01:00
irungentoo
dcf2aaa530
Merge branch 'ghost-avswitch' 2016-09-28 15:14:33 -04:00
derive
403f5a22e0 Added astyled toxav.h to match toxav.in.h 2016-09-28 15:13:21 -04:00
nobody
a4630e91ee Updated to match current toxav.h 2016-09-28 15:13:21 -04:00
Gregory Mullen (grayhatter)
51139a080c
v0.0.0 => v0.0.1 2016-09-28 12:12:39 -07:00
irungentoo
496af600ca
Merge branch 'distcheck' of https://github.com/felix-salfelder/toxcore 2016-09-28 15:09:44 -04:00