This commit fixes several warnings like this one:
In file included from ../../../src/libsmpp34/test_apps/smpp.c:40:
test_apps/smpp.c: In function ‘do_smpp_send_message2’:
test_apps/esme.h:32:16: warning: implicit declaration of function ‘strtol’;
did you mean ‘strtok’? [-Wimplicit-function-declaration]
32 | dst = strtol((char*)clave, NULL, 10);\
| ^~~~~~
test_apps/smpp.c:223:5: note: in expansion of macro ‘GET_PROP_INT’
223 | GET_PROP_INT( req.source_addr_ton, p, "source_addr_ton" );
| ^~~~~~~~~~~~
Change-Id: I16d9e0171d4c26f721c300e22c78b77f6db4895c
Parallel build has been fixed [1] and re-enabled [2] back in 2018.
Executing $MAKE without $PARALLEL_MAKE builds the project with -j1.
Executing $MAKE with $PARALLEL_MAKE after that makes no sense,
because everything is already compiled and there is nothing to do.
Change-Id: Iff7e7acfac0b827ce3b1086cea376a438b5af334
Related: [1] I5a9d7dbd7b992d322ed0d852ebf8ca2252b51a12
Related: [2] Id41fbcb5a96093eb6c3dc00bcacbd379111ada70
* aclocal: warning: couldn't open directory 'm4': No such file or directory
* libtoolize: Consider adding 'AC_CONFIG_MACRO_DIRS([m4])' to configure.ac
* libtoolize: Consider adding '-I m4' to ACLOCAL_AMFLAGS in Makefile.am
* configure.ac:9: warning: 'AM_CONFIG_HEADER': this macro is obsolete
configure.ac:9: You should use the 'AC_CONFIG_HEADERS' macro instead
* configure.ac:22: warning: The macro `AC_PROG_LIBTOOL' is obsolete
* configure.ac:86: warning: AC_OUTPUT should be used without arguments
Change-Id: I3199e7de0a04b4df89d01277cdb305d33902fcc2
Remove OpenSUSE bug report link, set version to @VERSION@, make it build with
CentOS 8 etc.
Related: OS#4550
Change-Id: If771c1298c84868a9ab0b0aba8d26325c3d810e8
As pointed out at https://github.com/libexpat/libexpat/issues/312
libtool does not play nice with clang sanitizer builds at all.
For those builds LD shoud be set to clang too (and LDFLAGS needs the
sanitizer flags as well), because the clang compiler driver knows how
linking to the sanitizer libs works, but then at a later stage libtool
fails to actually produce the shared libraries and the build fails. This
is fixed by this patch.
Addtionally LD_LIBRARY_PATH has no effect on conftest runs during
configure time, so the rpath needs to be set to the asan library path to
ensure the configure run does not fail due to a missing asan library,
i.e.:
SANS='-fsanitize=memory -fsanitize-recover=all -shared-libsan'
export CC=clang-10
ASANPATH=$(dirname `$CC -print-file-name=libclang_rt.asan-x86_64.so`)
export LDFLAGS="-Wl,-rpath,$ASANPATH $SANS $LDFLAGS"
Change-Id: Iae420759fbf3846221f94af4403f6273536ea00b
The constant 0x34 clearly hints that this should be written to
interface_version...
Closes: CID#135235
Change-Id: I89e16746da5c9f77b721294149a1bce5be5a1eae
Let's introduce a mechanism by which libsmpp34-using applications can
override the memory allocator functions. This allows us e.g. in the
Osmocom context to use talloc which aids us in debugging memory leaks.
Closes: OS#3913
Change-Id: I3656117115e89638c093bfbcbc4369ce302f7a94
Properly initialize sockaddr 'name' used by tcp test, and remove
a redundant re-declaration of this variable in a nested scope.
Change-Id: Id6e488308a72be96cca6aa661f088d2c3c67a6a3
Related: CID#188848
The .tarball-version file should contain the *source version* uniquely
identifying the git commit, and not the Debian package name.
With https://gerrit.osmocom.org/#/c/osmo-ci/+/10343/ there is a correct
.tarball-version file in the .tar.xz of the nightly source packages.
Related: OS#3449
Change-Id: I30714578bc7fb3cfe333eebec89dc06eb1bbc9fe
Provide a sane means of adding the -Werror compiler flag.
Currently, some of our jenkins.sh add -Werror by passing 'CFLAGS="-Werror"',
but that actually *overwrites* all the other CFLAGS we might want to have set.
Maintain these exceptions from -Werror:
a) deprecation (allow upstream to mark deprecation without breaking builds);
b) "#warning" pragmas (allow to remind ourselves of errors without breaking
builds)
As a last configure step before generating the output files, print the complete
CFLAGS and CPPFLAGS by means of AC_MSG_RESULT.
Change-Id: I5280a692eaf8f626523e0fd929d1febaa2859104
Assume that cat-testlogs.sh from osmo-ci is installed in
$HOME/osmo-ci/scripts, and call from jenkins.sh upon
'make check' failure.
Change-Id: I73527117283a3a251591af48e2841c9f452f461d
This change fixes a parallel building problem, when
submit_multi_resp_test
was being compiled before its libsmpp34 dependency:
make[2]: *** No rule to make target '../binaries/libsmpp34.la',
needed by 'submit_multi_resp_test'. Stop.
make[2]: *** Waiting for unfinished jobs....
For some reason, automake ignores a dependency if the full
path is provided:
$(top_builddir)/binaries/libsmpp34.la
while the relative path solves the problem:
libsmpp34.la
Change-Id: I5a9d7dbd7b992d322ed0d852ebf8ca2252b51a12
See osmo-ci change I2409b2928b4d7ebbd6c005097d4ad7337307dd93 for rationale.
Depends: I2409b2928b4d7ebbd6c005097d4ad7337307dd93
Change-Id: I0030c8662fa87fb589582a3f6bde6ed53e8e3ef9
Commit 1648066f16 introduced
osmocom-style git-version-gen, .version, etc. - but failed
to include .version in the EXTRA_DIST list of files.
Change-Id: If191e82677d851ca486ec78da6643958d05eb5f6
The code in OCTET8 implementation assumes the len is placed inside the
byte preceding the memory buffer, which is true for the defined cases.
However, it creates a compilation warning. Better pass the value
directly from the struct field rather than playing addr games. this way
we also assert we require to explicitly pass the len.
Fixes lots of warning like the one below:
/home/pespin/dev/sysmocom/bin/../git/libsmpp34/src/smpp34_unpack.c: In function ‘smpp34_u
npack’:
/home/pespin/dev/sysmocom/bin/../git/libsmpp34/src/smpp34_unpack.c:147:14: warning: array
subscript is above array bounds [-Warray-bounds]
lenval = *((inst par) - 1);\
^~~~~~~~~~~~~~~~~
/home/pespin/dev/sysmocom/bin/../git/libsmpp34/def_frame/submit_sm.frame:18:2: note: in e
xpansion of macro ‘OCTET8’
OCTET8( instancia, short_message, 254 );
^~~~~~
Change-Id: Id110f4e977c3becdb44cf5492c372e530ea51551
/home/pespin/dev/sysmocom/bin/../git/libsmpp34/test_pdu/bind_receiver_resp_test.c: In function ‘main’:
/home/pespin/dev/sysmocom/bin/../git/libsmpp34/test_pdu/bind_receiver_resp_test.c:55:58: warning: ‘snprintf’ output
truncated before the last format character [-Wformat-truncation=]
snprintf((char*)b.system_id, sizeof(b.system_id), "%s", "1234567890123456");
^
/home/pespin/dev/sysmocom/bin/../git/libsmpp34/test_pdu/bind_receiver_resp_test.c:55:5: note: ‘snprintf’ output 17
bytes into a destination of size 16
snprintf((char*)b.system_id, sizeof(b.system_id), "%s", "1234567890123456");
Change-Id: I4ec682a5e2ee4d02008a9c86a0a5507792667d0e
Fixes compilation warning below:
/home/pespin/dev/sysmocom/bin/../git/libsmpp34/src/smpp34_unpack.c: In function ‘smpp34_unpack’:
/home/pespin/dev/sysmocom/bin/../git/libsmpp34/src/smpp34_unpack.c:232:18: warning: variable ‘l’ set but not used [
-Wunused-but-set-variable]
uint32_t l;
Change-Id: I75baa65b575deec1cc040490f2e76ebb54e46ca7
Fixes compilation warning below:
%s’ directive output may be truncated writing between 8 and 33 bytes into a regio
n of size 30 [-Wformat-truncation=]
snprintf(buff, SMALL_BUFF, "%s",
^~
/home/pespin/dev/sysmocom/bin/../git/libsmpp34/src/smpp34_params.c:136:5: note: ‘
snprintf’ output between 9 and 34 bytes into a destination of size 30
snprintf(buff, SMALL_BUFF, "%s",
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#define OPERACION( p_tlv_id ) (tlv_id == p_tlv_id)?#p_tlv_id:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#include "def_list/tlv_id.list"
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
"Reserved"
~~~~~~~~~~
#undef OPERACION
~~~~~~~~~~~~~~~~
);
Change-Id: Ie2ba6182eb0cdd98cadb8317aef49141244aa92d
Fixes compilation warning below:
smpp34_dumpBuf.c:52:9: warning: variable ‘lefterror’ set but not used [-Wunused-but-set-variable]
int lefterror = 0;
Change-Id: Iea8ff80d3e4d16aaca6e37d64593b50fa27c8cfb