]> git.llucax.com Git - software/posixx.git/log
software/posixx.git
8 years agoAdd Boost License master
Leandro Lucarella [Wed, 9 Mar 2016 18:43:13 +0000 (15:43 -0300)]
Add Boost License

14 years agoAvoid a warning about uninitialized variable in the tests
Leandro Lucarella [Thu, 4 Feb 2010 14:31:23 +0000 (11:31 -0300)]
Avoid a warning about uninitialized variable in the tests

14 years agoAdd missing include in the tests
Leandro Lucarella [Thu, 4 Feb 2010 14:31:51 +0000 (11:31 -0300)]
Add missing include in the tests

15 years agoUpdate Makeit.mak
Leandro Lucarella [Thu, 29 Oct 2009 21:57:14 +0000 (18:57 -0300)]
Update Makeit.mak

Apply this commit:
7913e54 Allow compiling from directories named "build"

15 years agoUpdate Makeit.mak
Leandro Lucarella [Wed, 7 Oct 2009 13:41:09 +0000 (10:41 -0300)]
Update Makeit.mak

8192daf: Add coloring to commands output
fbe7854: Make "last" symlink point to the last build flavor
fe0b513: Add color to flags change warning

15 years agoUse makeit build system
Leandro Lucarella [Mon, 28 Sep 2009 15:49:00 +0000 (12:49 -0300)]
Use makeit build system

Makeit is a simple yet powerful and flexible build system based in GNU
Make. It doesn't generate the makefiles but greately simplify writing them,
using a single-file GNU Make library and some conventions.

15 years agoUse explicit targets when invoking sub-Makefiles
Leandro Lucarella [Thu, 30 Apr 2009 21:32:00 +0000 (18:32 -0300)]
Use explicit targets when invoking sub-Makefiles

This makes intentions clearer and avoids bugs.

15 years agoMove type_t and scope_t out from tipc::sockaddr
Leandro Lucarella [Fri, 27 Feb 2009 19:04:49 +0000 (17:04 -0200)]
Move type_t and scope_t out from tipc::sockaddr

Having nested constant definitions makes their use a little annoying.

15 years agoImprove test suite coverage
Leandro Lucarella [Fri, 27 Feb 2009 18:40:58 +0000 (16:40 -0200)]
Improve test suite coverage

15 years agoImprove/complete tipc printing
Leandro Lucarella [Fri, 27 Feb 2009 18:32:38 +0000 (16:32 -0200)]
Improve/complete tipc printing

Now all objects have the operator << implemented for std::ostreams.

15 years agoUse own constants in tipc::sockaddr constructor
Leandro Lucarella [Fri, 27 Feb 2009 18:28:18 +0000 (16:28 -0200)]
Use own constants in tipc::sockaddr constructor

15 years agoClean the tipc::sockaddr in the default constructor
Leandro Lucarella [Fri, 27 Feb 2009 18:27:30 +0000 (16:27 -0200)]
Clean the tipc::sockaddr in the default constructor

The TIPC's sockaddr default constructor now sets the family to AF_TIPC and
set all the other values to 0.

15 years agoFix tipc::sockaddr::operator == ()
Leandro Lucarella [Fri, 27 Feb 2009 18:15:33 +0000 (16:15 -0200)]
Fix tipc::sockaddr::operator == ()

Since sockaddr_tipc has an union, a memcmp() is not enough for comparison,
because a currently unused chunk of memory could be different but the
addresses are conceptually the same.

15 years agoAdd accessors with reference semantics to objects
Leandro Lucarella [Fri, 27 Feb 2009 18:22:30 +0000 (16:22 -0200)]
Add accessors with reference semantics to objects

New accessor methods are added to composed objects to access to the object
members using the struct. For example, you can access to a sockaddr tipc
portid via sockaddr.port_id() method, and mutate the original sockaddr:

sockaddr sa(portid(1, addr(1, 1, 1));
sa.port_id().ref = 5;

Now sa.addr.id.ref value is 5.

15 years agoImplement operator == for all tipc objects
Leandro Lucarella [Fri, 27 Feb 2009 18:10:53 +0000 (16:10 -0200)]
Implement operator == for all tipc objects

Is often useful to be able to compare for equality, specially when
testing ;)

15 years agoImprove tipc::subscr construction
Leandro Lucarella [Fri, 27 Feb 2009 17:50:00 +0000 (15:50 -0200)]
Improve tipc::subscr construction

Now subscr has 2 constructors, depending on how you want to handle the
user "handle" (arbitrary string). One constructor treats the user handle
as plain binary data, and copies that data without regarding its contents
(you must provide the size of the data to copy).

The other constructor treats the user handle as a C string (NULL
terminated string). You don't have to provide a size for the string, at
most N bytes are copied, being N the capacity of user handle field.

15 years agoAdd SUB_CANCEL to tipc::subscr_t
Leandro Lucarella [Fri, 27 Feb 2009 17:42:42 +0000 (15:42 -0200)]
Add SUB_CANCEL to tipc::subscr_t

This is supported in TIPC 1.7+ according to TIPC documentation.

15 years agoImprove code spacing
Leandro Lucarella [Fri, 27 Feb 2009 17:41:48 +0000 (15:41 -0200)]
Improve code spacing

Add some spaces in declarations to make them more readable.

15 years agoRename tipc::event to tipc::subscr_event
Leandro Lucarella [Fri, 27 Feb 2009 17:34:56 +0000 (15:34 -0200)]
Rename tipc::event to tipc::subscr_event

This will prevent problems because tipc_event has an "event" member that
will clash with the struct name.

15 years agoMove tipc::event::type_t to tipc::event_t
Leandro Lucarella [Fri, 27 Feb 2009 17:30:26 +0000 (15:30 -0200)]
Move tipc::event::type_t to tipc::event_t

Having nested constant definitions makes their use a little annoying.

15 years agoRename linux::tipc::subscription(_t) to subscr(_t)
Leandro Lucarella [Fri, 27 Feb 2009 17:24:02 +0000 (15:24 -0200)]
Rename linux::tipc::subscription(_t) to subscr(_t)

This is the name used by TIPC and it's a little shorter.

15 years agoRemove posixx::linux::tipc::multicast
Leandro Lucarella [Fri, 27 Feb 2009 17:12:33 +0000 (15:12 -0200)]
Remove posixx::linux::tipc::multicast

This is just an alias for nameseq, and it seems it's deprecated.

15 years agoAdd a new suppression to valgrind for Boost Test
Leandro Lucarella [Wed, 25 Feb 2009 19:00:34 +0000 (17:00 -0200)]
Add a new suppression to valgrind for Boost Test

Version 1.37 of Boost Testing Framework is shipped with new memory errors
that disturbs valgrind when doing make memcheck.

15 years agoUse Boost Unit Test Framework MT library
Leandro Lucarella [Wed, 25 Feb 2009 19:00:19 +0000 (17:00 -0200)]
Use Boost Unit Test Framework MT library

There is no reason for doing this except that Debian doesn't ship the not
MT version any more.

15 years agoImprove internet addresses (inet::sockaddr)
Leandro Lucarella [Thu, 22 Jan 2009 19:51:53 +0000 (17:51 -0200)]
Improve internet addresses (inet::sockaddr)

This patch improves the internet addresses. It adds a new constructor (to
create an address from a string), setters and getters to handle byte
ordering better and a couple of address constants (any and broadcast).

New test cases are created too.

16 years agoGeneralize basic_buffer's value_type
Leandro Lucarella [Mon, 1 Dec 2008 19:01:55 +0000 (17:01 -0200)]
Generalize basic_buffer's value_type

Now the basic_buffer has a new template parameter to choose the type to
use as value_type (i.e. the type of the elements stored in the array).

Note that only POD types are supported, since no constructors or
destructors get called.

16 years agoAdd reverse iteration to basic_buffer
Leandro Lucarella [Mon, 1 Dec 2008 18:51:27 +0000 (16:51 -0200)]
Add reverse iteration to basic_buffer

Reverse iteration was broken in basic_buffer, and thus commented out. Now
the reverse iterators are defined properly and all seems to work fine
according to the added test cases for reverse iteration.

16 years agoAdd a commit-check rule to the Makefile
Leandro Lucarella [Mon, 1 Dec 2008 18:48:30 +0000 (16:48 -0200)]
Add a commit-check rule to the Makefile

commit-check is a special make rule to run all sort of time-consuming
checks before committing (like building the documentation and run the test
cases). This is ideal for a git pre-commit hook, to avoid committing
broken stuff.

Now make all (and default) does nothing, because is a source-only library.

16 years agoUse std namespace for size_t and ptrdiff_t
Leandro Lucarella [Mon, 1 Dec 2008 18:45:55 +0000 (16:45 -0200)]
Use std namespace for size_t and ptrdiff_t

16 years agoAdd a new valgrind suppression
Alberto Bertogli [Fri, 14 Nov 2008 19:02:55 +0000 (17:02 -0200)]
Add a new valgrind suppression

To cover from this boost-related valgrind warning we can do nothing about
(and seems relatively harmless):

==25072== Syscall param sigaltstack(ss) points to uninitialised byte(s)
==25072==    at 0x585ABF7: sigaltstack (in /lib/libc-2.8.90.so)
==25072==    by 0x4E44D35: boost::detail::signal_handler::~signal_handler() (in /usr/lib/libboost_unit_test_framework.so.1.35.0)
==25072==    by 0x4E45560: boost::execution_monitor::catch_signals(boost::unit_test::callback0<int> const&) (in /usr/lib/libboost_unit_test_framework.so.1.35.0)
==25072==    by 0x4E4564B: boost::execution_monitor::execute(boost::unit_test::callback0<int> const&) (in /usr/lib/libboost_unit_test_framework.so.1.35.0)
==25072==    by 0x4E4C052: boost::unit_test::framework::run(unsigned long, bool) (in /usr/lib/libboost_unit_test_framework.so.1.35.0)
==25072==    by 0x4E5B023: boost::unit_test::unit_test_main(bool (*)(), int, char**) (in /usr/lib/libboost_unit_test_framework.so.1.35.0)
==25072==    by 0x41AFC3: main (in /home/alb/devel/integratech/switchit/mios/posixx/test/test_suite)
==25072==  Address 0x7feffea50 is on thread 1's stack
==25072==

16 years agoGeneralize valgrind suppressions wrt. glibc
Alberto Bertogli [Fri, 14 Nov 2008 19:01:57 +0000 (17:01 -0200)]
Generalize valgrind suppressions wrt. glibc

The suppresions are valid for any glibc/ld version, there's no need to be
so specific.

16 years agoAdd pkg-config support
Leandro Lucarella [Wed, 12 Nov 2008 17:21:51 +0000 (15:21 -0200)]
Add pkg-config support

Generate and install a pkg-config .pc definition file to ease compilation
and linking of programs depending on posixx.

16 years agoAdd socket addresses ostream formatting
Leandro Lucarella [Mon, 10 Nov 2008 16:03:04 +0000 (14:03 -0200)]
Add socket addresses ostream formatting

16 years agoFix indentation
Leandro Lucarella [Thu, 6 Nov 2008 21:50:06 +0000 (19:50 -0200)]
Fix indentation

Don't use spaces for indentation, use tabs instead.

16 years agoAdd posix::basic_buffer template and posix::buffer class
Leandro Lucarella [Wed, 8 Oct 2008 16:40:50 +0000 (13:40 -0300)]
Add posix::basic_buffer template and posix::buffer class

posixx::basic_buffer provides easy to use, STL-container-lke and
exception-safe class to manipulate buffers. It's a pseudo-static array
(you can resize it but you can't append or insert/remove arbitrary
elements). It's parametrized to support different kinds of allocators (not
in the STL-sense, it uses a realloc-like function).

posix::buffer is just a posix::basic_buffer< &realloc >.

16 years agoUse -I instead of -isystem when including our own headers for testing
Leandro Lucarella [Fri, 3 Oct 2008 18:16:56 +0000 (15:16 -0300)]
Use -I instead of -isystem when including our own headers for testing

Use -isystem makes GCC emulate that our own headers are system headers,
giving them the lowest priority when it search for a particular header
included with <>. This could be problematic in certain building
environments.

16 years agoFix typo in Makefiles RELEASE option
Leandro Lucarella [Tue, 30 Sep 2008 21:06:21 +0000 (18:06 -0300)]
Fix typo in Makefiles RELEASE option

16 years agoGenerate reference documentation from headers only
Leandro Lucarella [Tue, 30 Sep 2008 15:51:20 +0000 (12:51 -0300)]
Generate reference documentation from headers only

16 years agoAdd missing default "prefix" to Makefile
Leandro Lucarella [Mon, 29 Sep 2008 18:01:43 +0000 (15:01 -0300)]
Add missing default "prefix" to Makefile

16 years agoMove basic_socket.hpp to the socket directory
Leandro Lucarella [Mon, 29 Sep 2008 18:01:03 +0000 (15:01 -0300)]
Move basic_socket.hpp to the socket directory

Since everything defined by basic_socket.hpp is in the posixx::socket
namespace, it's more natural to place it in the socket directory.

16 years agoAvoid rebuilding of doc, (mem)test and install targets
Leandro Lucarella [Mon, 22 Sep 2008 18:05:51 +0000 (15:05 -0300)]
Avoid rebuilding of doc, (mem)test and install targets

This patch improves the Makefiles to avoid unnecessary rebuilding of some
targets, like doc/test/memtest/install, which only need to be "rebuilt"
when the sources has changed.

This is implemented using empty target files to record events, as
described in the GNU make manual[1].

[1] http://www.gnu.org/software/make/manual/make.html#Empty-Targets

16 years agoUse a separated .gitignore per top-level directory
Leandro Lucarella [Mon, 22 Sep 2008 18:03:36 +0000 (15:03 -0300)]
Use a separated .gitignore per top-level directory

16 years agoImprove handling of CFLAGS and LDFLAGS make variables
Leandro Lucarella [Thu, 18 Sep 2008 23:01:36 +0000 (20:01 -0300)]
Improve handling of CFLAGS and LDFLAGS make variables

The Makefile now uses 3 flavors of C/LDFLAGS variables: LOCAL_*, LI_* and
the plain ones.

LOCAL_* are used for mandatory local flags, like -std=C++98 and such,
LI_* are reserved for special "local-install" flags (set by the
super-repository). Plain C/LDFLAGS can be set by the user at make-time as
usual.

16 years agoUse open() instead of close() for testing posixx::error
Leandro Lucarella [Thu, 18 Sep 2008 22:43:15 +0000 (19:43 -0300)]
Use open() instead of close() for testing posixx::error

Closing an invalid file descriptor triggers a valgrind error and makes
'make memtest' fail.

16 years agoRemove extra comma at the end of enum values
Leandro Lucarella [Thu, 18 Sep 2008 22:41:55 +0000 (19:41 -0300)]
Remove extra comma at the end of enum values

ISO C++ 98 doesn't allow trailing commas.

16 years agoPreserve installed headers timestamps
Leandro Lucarella [Thu, 18 Sep 2008 22:41:15 +0000 (19:41 -0300)]
Preserve installed headers timestamps

If timestamps are not preserved, other programs using this headers will be
rebuilt even when the headers didn't change.

16 years agoFix 80 column limit violation
Leandro Lucarella [Wed, 17 Sep 2008 18:51:48 +0000 (15:51 -0300)]
Fix 80 column limit violation

16 years agoAdd some help on adding suppressions to valgrind.
Leandro Lucarella [Tue, 16 Sep 2008 14:59:45 +0000 (11:59 -0300)]
Add some help on adding suppressions to valgrind.

16 years agoAdd documentation about dependencies
Leandro Lucarella [Tue, 16 Sep 2008 13:49:35 +0000 (10:49 -0300)]
Add documentation about dependencies

16 years agoMake documentation when using make all
Leandro Lucarella [Tue, 16 Sep 2008 13:48:30 +0000 (10:48 -0300)]
Make documentation when using make all

16 years agoTell git to ignore tests log files
Leandro Lucarella [Tue, 16 Sep 2008 13:22:41 +0000 (10:22 -0300)]
Tell git to ignore tests log files

16 years agoLog test results when non-verbose make (mem)test is used
Leandro Lucarella [Tue, 16 Sep 2008 13:22:07 +0000 (10:22 -0300)]
Log test results when non-verbose make (mem)test is used

16 years agoMake make memtest fail if valgrind found errors
Leandro Lucarella [Tue, 16 Sep 2008 13:18:18 +0000 (10:18 -0300)]
Make make memtest fail if valgrind found errors

16 years agoAdd a boost.Test valgrind suppression
Leandro Lucarella [Tue, 16 Sep 2008 13:17:57 +0000 (10:17 -0300)]
Add a boost.Test valgrind suppression

16 years agoAvoid valgrind error about send()ing uninitialized data
Leandro Lucarella [Tue, 16 Sep 2008 13:17:35 +0000 (10:17 -0300)]
Avoid valgrind error about send()ing uninitialized data

16 years agoRemove circular dependency
Leandro Lucarella [Tue, 16 Sep 2008 13:16:59 +0000 (10:16 -0300)]
Remove circular dependency

16 years agoInitial import of the POSIX thin wrapper for C++
Leandro Lucarella [Mon, 15 Sep 2008 21:24:33 +0000 (18:24 -0300)]
Initial import of the POSIX thin wrapper for C++