GCC was complaining about functions "declared inline after being
called". This commit suppresses all inline declarations (-O2 inlines
automatically small functions anyway).
The new option -V displays the compilation-time options. In the future,
it should display the version number.
When the user calls the program either with -h or the new option -V, we
do not try any more to open and parse the configuration file (which was
useless since -h, and now -V, exit the program).
Move code related to sending requests into the new library
libowlps-client. This library will also be used by the listener to send
autocalibration requests.
Currently, it is statically linked because a dynamic linking should be
useless (because client and listener aren't normally on the same
machine).
Fix Makefiles to use -D to activate the use of pthreads and libconfuse.
Comment out #defines in owlps-listener.h.
Fix lib order (needed for the static target).
Makefile_atheros:
- Add target 'static' to compile fully statically. (Note: does not
work in the OpenWRT 8.09 cross-compilation suite, since it does not
provide libiw.a)
- Add target 'semistatic', that compiles with static libowlps and
dynamic libiw and libpcap.
Fix (mostly) endianess issues:
- le32toh() is defined only in glibc >= 2.9, so owlps-listener did not
compile with older glibc or other libc (such as uClibc that we use to
cross-compile to OpenWRT).
We now define le32toh() manually, if needed.
- Additionally, the PLATFORM_ATHEROS define is removed. We should now
test the value of __BYTE_ORDER if needed.
listener + libowlps : nettoyage, amélioration de la qualité du code,
tests sur le type du paquet capturé.
git-svn-id: https://pif.pu-pm.univ-fcomte.fr/svn/loc@108 785a6c6c-259e-4ff1-8b91-dc31627914f0
owlps-listener :
* Détail des erreurs d'ouverture / parcours du fichier de configuration.
* Ajout des option -v et -q permettant de choisir si le programme doit
être verbeux ou silencieux.
* Modification des en-têtes de capture() et read_packet() pour utiliser
la structure de configuration plutôt que des passages d'arguments.
Note : peut-être serait-il bien de déplacer read_packet() dans
capture() (à la place de got_packet) pour éviter le passage incessant
des arguments sockfd et server.
* Ajout de l'option -m permettant de choisir le mode (actif, passif,
mixte).
* Préparation de l'implantation du mode passif (dans read_packet).
git-svn-id: https://pif.pu-pm.univ-fcomte.fr/svn/loc@106 785a6c6c-259e-4ff1-8b91-dc31627914f0
client :
* Ajout de l'option -l permettant d'activer ou non l'attente d'une
réponse après l'envoi d'une demande, et éventuellement de spécifier un
port alternatif.
* Ajout de l'option -p permettant de spécifier le port d'envoi des
demandes.
git-svn-id: https://pif.pu-pm.univ-fcomte.fr/svn/loc@100 785a6c6c-259e-4ff1-8b91-dc31627914f0