Commit Graph
147 Commits
Author SHA1 Message Date
Joachim Nilsson 7bf5c8d8d7 Let Travis run some tests as well.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-09-16 18:05:31 +02:00
Joachim Nilsson 1374661d4b README: Fix syntax error in example.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-09-16 18:05:04 +02:00
Joachim Nilsson 694e2b5ab9 Silence annoying warnings from GNU ar
In (very) modern versions of binutils, for instance v2.25.1 in Ubuntu
15.10, complain about VERY common `crus` argument.  This patch attempts
to silence this noise:

    $ make -j5
      CC      uev.o
      CC      io.o
      CC      timer.o
      CC      signal.o
      ARCHIVE libuev.a
      LINK    libuev.so.1
    ar: `u' modifier ignored since `D' is the default (see `U')

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-09-16 18:04:06 +02:00
Joachim Nilsson c2751af452 README: Further fixes to missing Markdown links.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-09-13 01:10:02 +02:00
Joachim Nilsson 1ce9fde395 README: Fix Markdown for code blocks.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-09-13 00:51:49 +02:00
Joachim Nilsson 7e9f8c4913 README: Fix Travis-CI and Coverity Markdown links.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-09-13 00:49:31 +02:00
Joachim Nilsson dd09c7c3a9 README: More Markdown syntax fixes.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-09-13 00:47:49 +02:00
Joachim Nilsson fe04723353 README: Markdown syntax (non-GitHub) fixes.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-09-13 00:46:20 +02:00
Joachim Nilsson 78995951ae Update ChangeLog and bump version for v1.2.2 release.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
v1.2.2
2015-08-30 18:19:22 +02:00
Joachim Nilsson 3adc7a03c0 Fix issue #6: Segfault when stopping timer before calling uev_exit()
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-08-30 18:02:47 +02:00
Joachim Nilsson 2abeb39fe8 Use dockerized build, quicker and less resource intensive for Travis-CI
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-08-22 16:06:21 +02:00
Joachim Nilsson 1480976724 Fix data ordering bug causing problems on Debian Jessie
Got very odd results on Debian Jessie when having the uev_private_t last
in uev_t.  Turns out that when uev.c set "w->active = 0;" the w->fd data
member was written to instead.

Placing the private data first in uev_t is better practise, generally a
good thing for linked lists built on the BSD sys/queue.h API, looks a
lot better, but foremost works.

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-07-19 04:40:30 +02:00
Joachim Nilsson 6ffa76c2f8 Remove STATIC ifdef, always build .a and .so files
It is non-trivial to set a separate environment variable (STATIC=1) when
descending into the libuEv subdirectory from an autoconf/automake based
project.

It is better to instead simplify the build process and always build both
.a and .so files.

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-07-12 23:13:04 +02:00
Joachim Nilsson 8a4e8c4af6 ChangeLog: Fix cut-and-paste error in Markdown link.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-07-02 13:21:21 +02:00
Joachim Nilsson 950015715d Update ChangeLog and bump version for v1.2.1 release!
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
v1.2.1
2015-07-02 13:19:32 +02:00
Joachim Nilsson fb6ac1ecac Also install queue.h, dito needed by external plugins.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-06-18 08:43:20 +02:00
Joachim Nilsson 0909decabc Make sure to also install new private.h, unfortunately necessary.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-06-18 08:37:37 +02:00
Joachim Nilsson 3452fbd381 Default to -fPIC, bloats archives slightly, but works for everyone.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-06-18 02:24:14 +02:00
Joachim Nilsson f64561b708 Cleanup: fix install/uninstall of both static and dynamic builds.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-06-18 02:14:15 +02:00
Joachim Nilsson b94023faed Reflow paragraphs to match original line breaks, no change in licensing terms!
While comparing the library layout with libite, I noticed how the
formatting of the license paragraphs in all source files had been
garbled.  This patch restores the orginal line breaks.

Note: Only whitespace changes, no change in licensing terms!

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-06-18 01:36:48 +02:00
Joachim Nilsson 6637804b80 Merge pull request #5 from vonj/master
O_CLOEXEC does not exist in Debian 6 GLIBC/EGLIBC, use EPOLL_CLOEXEC instead.
2015-06-13 19:42:27 +02:00
jakob 361b013da5 O_CLOEXEC does not exist in Debian 6, and apparently EPOLL_CLOEXEC is the correct to use anyway. 2015-06-13 19:32:34 +02:00
Joachim Nilsson 052b08e0b5 Followup to fix indentation, leading tabs, then spaces.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-06-09 15:51:07 +02:00
Joachim Nilsson ca803bb12f Move private data members and methods from uev.h to private.h
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-06-09 15:46:19 +02:00
Joachim Nilsson 6397edc2c4 Update ChangeLog and bump version for v1.2.0 release.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
v1.2.0
2015-06-09 13:18:39 +02:00
Joachim Nilsson cbd962c5b6 Fix bench.c so it actually reads from the pipe/socket, update callback API
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-06-09 13:14:49 +02:00
Joachim Nilsson 1f9558059a API change -- Remove first ctx argument and add event mask to callback
There really does not exist a good reason for us sending a `uev_ctx_t *`
pointer as the first argument to event callbacks.  If the callback needs
to reference the context, it can find the ctx pointer in the `uev_t *w`.

This patch removes the first argument from all callbacks and also fixes
a slight bug in that the event loop never returned the actual event that
triggered the callback!

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-06-09 13:10:20 +02:00
Joachim Nilsson 9e7f6865fc uev_timer_set(): Bugfix, call uev_watcher_start() even if not running yet!
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-06-09 13:05:55 +02:00
Joachim Nilsson 3b31079a1c README: Refactor API section in an attempt to make it more accessible.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-03-29 09:31:14 +02:00
Joachim Nilsson 63697e9eda Add support for building static-only libuev.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-03-06 21:33:49 +01:00
Joachim Nilsson ce3930f0cf Update .gitignore, dep files now named *.d
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-03-04 15:55:44 +01:00
Joachim Nilsson bfd046054b Slight update before release.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
v1.1.0
2015-03-04 10:54:32 +01:00
Joachim Nilsson 6a40d51d26 Bump version to v1.1.0 for release.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-03-04 10:44:39 +01:00
Joachim Nilsson f513408316 Remove clang from Travis build to avoid double Coverity runs
There currenty is no *simple* way of preventing Coverity from being run
twice, so we just remove the clang build in the meantime :-/

See: travis-ci/travis-ci#1975

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-03-04 10:41:57 +01:00
Joachim Nilsson 30b5faa318 Update ChangeLog and bump dev version to 1.1 due to the major changes
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-03-04 09:53:18 +01:00
Joachim Nilsson fe8f3f19da Massively improve error handling, check for EPOLLHUP & EPOLLERR etc.
- Make sure to listen for EPOLLRDHUP in watchers so users can be
  notified when a peer closes a connection.
- Handle EPOLLHUP and EPOLLERR gracefully.  Even handle spurious
  EPOLLHUP by means of an error counter.  If we receive too many errors
  we now restart the epoll fd and re-add all watchers.
- Return error from `epoll_ctl()` in `uev_watcher_stop()`
- Ignore any error from `uev_watcher_stop()` in `uev_watcher_set()`
- Move LIST_REMOVE() et al from io.c to core uev.c, should be
  done for timer and signal callbacks as well, of course.

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-03-04 09:41:22 +01:00
Joachim Nilsson 71208b7e21 Update ChangeLog
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-02-16 00:27:17 +01:00
Joachim Nilsson 312b8257fb Fix issue #2: 'make install' stopped working in v1.0.5
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-02-16 00:26:55 +01:00
Joachim Nilsson f29f3b7f38 Minor followup to bfcea55, add else statment.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-02-16 00:25:38 +01:00
Joachim Nilsson cd4daf0d36 README: Update API section with new _start() functions.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-02-15 18:42:56 +01:00
Joachim Nilsson 43acbadc13 Open v1.0.6-dev window.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-02-15 18:35:43 +01:00
Joachim Nilsson e316226ef1 Update ChangeLog and bump version for v1.0.5 release.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
v1.0.5
2015-02-15 18:30:30 +01:00
Joachim Nilsson 2f8c45f438 Fix TODO: Add uev_*_start() functions.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-02-15 18:13:36 +01:00
Joachim Nilsson bfcea55b1e Add slightly odd signal testing + fork() example
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-02-15 18:13:26 +01:00
Joachim Nilsson 6e7234fa4d Fix issue #1: Use local queue.h from OpenBSD, may be missing on target OS
Use OpenBSD version of queue.h since the C-library may not have it (at
all), or may come with an older (buggy) version.

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-02-15 18:13:18 +01:00
Joachim Nilsson 51a802716d Rename main.c --> uev.c
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-02-15 18:13:14 +01:00
Joachim Nilsson 5ecc6d64b4 Move test.c and joystick.c to examples/
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-02-15 18:13:09 +01:00
Joachim Nilsson d1b9fd17f3 Proposal to add uev_*_start(), for symmetry and finit ..
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-02-10 07:58:23 +01:00
Joachim Nilsson 3192923687 Add another notice to the API section, again highlighting signalfd caveats!
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-02-04 20:36:32 +01:00
Joachim Nilsson 83822a664e Fix cut-and-paste error in git tag links.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-02-01 09:00:39 +01:00