1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00
Commit Graph

2454 Commits

Author SHA1 Message Date
Leon George
533e23fab0 pkg/Makefile.http: complete Makefile-example 2014-10-01 21:53:43 +02:00
Leon George
bff3bf72c8 pkg/Makefile.{http,git}: Minor issues resolved.
The were two recipes for clean. One of them is now "dist-clean"
2014-09-28 03:26:32 +02:00
Cenk Gündoğan
710c7e6cf6 transport_layer: Splitting UDP and TCP
Currently, the tcp and udp implementations are bound to each other in a
module called *destiny*. Thus, when using only one of them then the
other one gets also compiled into the binary and initialized,
which results in unnecessary RAM usage and workload for the CPU.

The approach in this PR defines a common module named *socket_base*,
which contains functions used by the posix layer. Compiled by it's own,
those functions return negative error codes, to symbolize upper layers
that they are not supported. When also including the modules *udp* or
*tcp* respectively, functions from *socket_base* get overwritten with the
correct functionality.

Defining *udp* or *tcp* in a Makefile also includes *socket_base*.
Defining *pnet* in a Makefile also includes *socket_base*.
2014-09-11 20:07:46 +02:00
René Kijewski
a70ee0f022 make: centralize wget/curl & unzip/7z feature test
With many open PRs that could benefit from loading SDKs when needed,
instead adding vast amounts of code to RIOTs master, this PR provides
the "functions" `$(DOWNLOAD_TO_STDOUT)`, `$(DOWNLOAD_TO_FILE)`, and
`$(UNZIP_HERE)`.

The first "function" takes one argument, the URL from where to download
the content. It is then piped to stdout. To be used e.g. with `tar xz`.

The second "function" taken two arguments, the destination file name,
and the source URL. If the previous invocation was interrupted, then the
download gets continued, if possible.

The last "function" takes one argument, the source ZIP file. The file
gets extracted into the cwd, so best use this "function" with
`cd $(SOME_WHERE) &&`.

The clumsy name `$(UNZIP_HERE)` is taken because the program "unzip"
takes the environment variable `UNZIP` as the source file, even if
another file name was given on the command line. The rationale for that
is that the hackers of "unzip" hate their users. Also they sacrifice
hamsters to Satan.
2014-08-21 19:07:52 +02:00
René Kijewski
d7b4f1a5ba pkg: add USEPKG module "libfixmath"
This PR adds the USEPKG module "libfixmath".
It integrates https://code.google.com/p/libfixmath/ into RIOT, cmp. #1457.
2014-08-01 00:04:48 +02:00
Ludwig Ortmann
ccfe6d7bb7 pkg/libcoap: fix copmilation problems
Apparently all that whitespace was needed after all.
Next convert to new-style function declrations.
Also, don't prevent make from noticing a failing patch.
2014-07-15 18:56:52 +02:00
Hauke Petersen
9001e0c2fb core: removed duplicated hwtimer_arch.h 2014-07-09 21:08:13 +02:00
Oleg Hahm
810b8d4479 Merge pull request #1210 from benpicco/fix_oonf_msba2
pkg/oonf_api: fix conflicting types on msba2
2014-06-17 23:43:32 +02:00
René Kijewski
ee02a0f654 x86: fix download script for OSX
Mac OSX does not have `wget`, but `curl`.
It does not understand `tar xJ`, but `tar xj`.
2014-06-03 22:36:00 +02:00
Martin Lenders
2362623490 Fix trailing whitespaces
Fixes #1138
2014-05-26 14:54:23 +02:00
Thomas Eichinger
1e983c9670 s/PROJECT/APPLICATION/g
fixes #548
2014-05-26 13:21:09 +02:00
René Kijewski
054f9fd026 make: fix clean together with TLSF 2014-05-24 19:22:18 +02:00
René Kijewski
88e8915dfe Add TLSF (two level segregated fit) PKG
This is my second take on #669, because I was asked to separate it from #764.

This change adds a malloc implementation as a PKG, which uses *TLSF* (two
level segregated fit).

The patch file removes the 64bit capatibilities, debug functions, and the
option to have multiple "control blocks" (a control block holds multiple
memory pools). It wraps `malloc()` and friends in `disableIRQ() … restoreIRQ()`.

The implemention does not support 16bit platforms, yet, but probably only some
constants would need fixing. I limited the maximum size of a memory pool to
2**30 bytes = 1GB.

This PKG is not meant to be used by applicitions directly, but by the boards.
The board's initialition code needs to call
`int tlsf_add_pool(void *mem, size_t bytes)` for every free memory region it
has. If the board in using newlib, then this call needs to happen before the
first call to `puts`, `printf`, and friends, because newlib allocates the
control data IO streams (stdin, stdout, stderr) on the heap. Adding a small
(e.g. 1kB) pool before proper board initialization would be a possible solution.

Please read the additional information in the website of the implementator,
http://tlsf.baisoku.org/:

> TLSF (two level segregated fit) is a relatively new memory
allocator designed for embedded systems. It boasts constant
time O(1) malloc/free response time and a 4-byte block
overhead. Though it typically is slightly slower than other
allocators such as dlmalloc, it has no worst-case behavior.

> The original implementation, which comes alongside the white
paper, is distributed under the GNU GPL/LGPL. The code found
here is an original implementation, released into the public
domain, therefore is not subject to any licensing restrictions.

> Features:
 -  O(1) cost for malloc, free, realloc, memalign
 -  Extremely low overhead per allocation (4 bytes)
 -  Low overhead per pool (~3kB)
 -  Low fragmentation
 -  Compiles to only a few kB of code and data

> Caveats:
 -  Currently, assumes architecture can make 4-byte aligned accesses
 -  Not designed to be thread safe; the user must provide this

> Known Issues:
Due to the internal block structure size and the implementation
details of tlsf_memalign, there is worst-case behavior when requesting
small (<16 byte) blocks aligned to 8-byte boundaries. Overuse of memalign
will generally increase fragmentation, but this particular case will leave
lots of unusable "holes" in the heap. The solution would be to internally
align all blocks to 8 bytes, but this will require significantl changes
to the implementation. Contact me if you are interested.
2014-05-20 03:17:09 +02:00
Benjamin Valentin
1235a0f579 pkg/oonf_api: fix conflicting types on msba2 2014-05-18 22:57:03 +02:00
Thomas Eichinger
ba3088c4bd added iot-lab_M3 and temporarily dropped telosb support; split patch.txt
into separate patch files
2014-05-14 15:06:50 +02:00
Benjamin Valentin
a2dec64b67 fix buildtest with oonf_api
Don't try to checkout oonf_api if it's already present
2014-05-12 16:53:30 +02:00
Hauke Petersen
6c591c8a68 tests/pkg: fixed issues from #919 2014-03-26 15:13:23 +01:00
benpicco
69515edc47 Merge pull request #905 from benpicco/improve_Makefile.git
improve Makefile.git
2014-03-19 16:46:36 +01:00
Oleg Hahm
8c6f9b1e24 Merge pull request #903 from LudwigOrtmann/gitignore-oonf_api
pkg/oonf_api: add .gitignore
2014-03-19 16:46:07 +01:00
Ludwig Ortmann
68afd7e3fe Update PORTING 2014-03-19 16:40:33 +01:00
Benjamin Valentin
ab4d151a6a improve Makefile.git
Change the example Makefile.git as suggested in #895
  abort when a patch fails to apply
  fix build with GNU Make 4.0
  reset git to the specified version instead of checking out a detached head
2014-03-19 16:19:30 +01:00
Ludwig Ortmann
2df3808969 pkg/oonf_api: add .gitignore 2014-03-19 16:12:50 +01:00
Benjamin Valentin
633f65c062 abort on error when patching oonf_api 2014-03-18 18:53:14 +01:00
Benjamin Valentin
4dfce522df fix oonf_api build with GNU Make 4.0
fixes #884
2014-03-18 14:50:47 +01:00
Benjamin Valentin
86244410b5 remove unnecessary comments from Makefile
remove leftovers from the example Makefile, they are unnededly printed during the build
2014-03-17 21:23:46 +01:00
Benjamin Valentin
068b4746b0 silence git warning about detached head
use reset --hard to check out the desired revision
2014-03-17 21:23:46 +01:00
Benjamin Valentin
740f43cb99 remove trailing whitespaces 2014-03-17 16:14:11 +01:00
Benjamin Valentin
8856cfddb9 make: don't ignore failures in for loops
apply 9b61d95545 to oonf_api
2014-03-17 16:06:46 +01:00
Lotte Steenbrink
2755b69e58 Merge pull request #630 from benpicco/oonf_api
[RFC] add oonf_api to pkg
2014-03-13 18:18:07 +01:00
Ludwig Ortmann
9b61d95545 make: don't ignore failures in for loops
Add `|| exit 1` to all constructs like `@for i in $(DIRS) ; do "$(MAKE)" -C $$i ; done ;`, so that compilation stops on the first error.
2014-03-12 11:09:04 +01:00
Ludwig Ortmann
ac21f3c54c make: couple include path and -I
This is necessary if includes have to be filtered, such as in native
to throw out RIOTs posix includes which interfere with system
includes.
2014-02-27 08:14:33 +01:00
Martin Lenders
2cc4682716 Fix libcoap make 2014-02-26 15:40:41 +01:00
Martin Lenders
24b63bd9f0 Update libcoap 2014-02-23 20:57:17 +01:00
Benjamin Valentin
edea31a21c add oonf_api pkg 2014-02-22 01:41:17 +01:00
Christian Mehlis
cb9c5d00de repace project by application in documentation 2014-02-18 12:28:32 +01:00
René Kijewski
ee6f6830aa Apply @authmillenon's patch 2014-02-12 13:59:39 +01:00
René Kijewski
84cffaa0a0 Use include path convention for PKGs
Packages have to define a Makefile.include target in pkg/%/Makefile.
pkg/%/Makefile.include will be loaded after all other dependencies.
2014-02-12 13:59:39 +01:00
René Kijewski
5906f18a81 Add USEPKG variable for Makefiles
Currently pkg/USING says one should use
`EXTERNAL+=$(RIOTBASE)/pkg/<pkg_name>` to enable PKG modules.
Using this line the PKG will be compiled but not linked.

This change adds a USEPKG variable to be used like
`USEPKG += <pkg_name>`, which looks less clumsy and gets the PKG linked
in the binary.
2014-02-12 13:57:30 +01:00
Ludwig Ortmann
2525920426 remove trailing whitespace and newlines 2014-02-11 18:45:06 +01:00
Ludwig Ortmann
a594c57bed Merge pull request #578 from LudwigOrtmann/libcoap_makefile
fix libcoap checkout target
2014-01-31 07:21:50 -08:00
lotte steenbrink
fccd2eca5e Fixed some typos & language in pkg/PORTING 2014-01-31 11:24:35 +00:00
Ludwig Ortmann
19e1759ff4 add .gitignore for openwsn pkg 2014-01-29 10:33:02 +01:00
Ludwig Ortmann
6fcf7ec089 fix libcoap checkout target
Fixes the following error:
make[1]: Entering directory '/foo/RIOT/pkg/libcoap'
git clone http://git.code.sf.net/p/libcoap/code /foo/RIOT/pkg/libcoap/libcoap && \
	cd /foo/RIOT/pkg/libcoap/libcoap && git checkout 89acaa6775ca3a4aedea510557e6b9c0c01fa5db
fatal: destination path '/foo/RIOT/pkg/libcoap/libcoap' already exists and is not an empty directory.
Makefile:25: recipe for target '/foo/RIOT/pkg/libcoap/libcoap' failed
2014-01-28 18:52:55 +01:00
Thomas Eichinger
41fca84c09 Merge pull request #508 from thomaseichinger/openwsn-pkg
support openwsn as a pkg
2014-01-20 06:03:12 -08:00
Thomas Eichinger
b290ea0059 fix for those fancy case sensitiv filesystems 2014-01-20 13:19:07 +01:00
Thomas Eichinger
10cf348a6e fixes naming conflict with uart.(c|h) 2014-01-20 12:35:19 +01:00
Thomas Eichinger
d41b92094a fixes downloading the archive with each ``make -B`` 2014-01-20 12:34:07 +01:00
Thomas Eichinger
f25e9f1f79 fixing bug: don't reapply patch 2014-01-17 17:59:43 +01:00
Martin Lenders
55b1c27c38 Add libcoap as BSD ports-like package 2014-01-17 15:54:18 +01:00
Thomas Eichinger
923b6c09af added a README with compatibility information 2014-01-16 21:31:44 +01:00
Thomas Eichinger
5c8838ce3f make script more verbose and deal with CRLF line endings 2014-01-15 16:38:04 +01:00
Thomas Eichinger
a66846ef22 fixes to fit the new silence flag 2014-01-15 16:12:11 +01:00
Thomas Eichinger
c6de59cb28 added possibilty to import openwsn stack as external module 2014-01-15 14:02:28 +01:00
Martin Lenders
cbd3b16fe4 Add package porting infomation 2013-11-25 17:17:00 +01:00