Commit Graph

17 Commits

Author SHA1 Message Date
Oliver Smith 2e0e624060 regen_makefile.sh: files/flags in separate lines
Make all regen_makefile.sh more readable and diff friendly by moving
each entry in FILES and CPPFLAGS_TTCN3 into separate lines. Order
entries alphabetically.

Related: OS#5252
Change-Id: I6b6866eb9f6ec6232e4ae434517457a4c8c1c050
2021-10-12 16:35:01 +02:00
Oliver Smith 1cdbf1b51e regen-makefile.sh: remove titan < 6.5.1 code path
Prepare to make osmo-ttcn3-hacks.git work with eclipse-titan 8.0.0,
where "ttcn3_makefilegen -v" does not have a "Product number" anymore.

Fix for:
../regen-makefile.sh: 54: ../regen-makefile.sh: arithmetic expression: expecting primary: " >= 65"

Related: OS#5252
Related: If9fef29ce243be112d3735f0236335197f8f140f
Change-Id: Iec26eafc1ddfa19bc1224f6f2abb7fb35cfc188d
2021-10-11 18:21:25 +02:00
Harald Welte 18ed23cda5 regen-makefile.sh: Put libraries in LINUX_LIBS, not LDFLAGS
Additional libraries to be linked should be in LINUX_LIBS (appended at
the end of the linker command), not part of LDFLAGS (prepended to
the beginning of the linker command).

On binutils 2.35.1 / Debian unstable, without this patch, I get

/usr/bin/ld: IPL4asp_PT.so: undefined reference to `sctp_bindx'
/usr/bin/ld: IPL4asp_PT.so: undefined reference to `sctp_connectx'

which is resolved by this patch

Change-Id: I8a339076f445e3c650e407ae982c7c2dc4a760b2
2020-10-04 21:09:11 +02:00
Pau Espin 1f2da16614 Enable Titan SCTP multi-homing feature support
Reference: titan.TestPorts.IPL4asp/doc/IPL4asp_Description.adoc

Change-Id: Icf3af8c6386419374b655cf6b40dd3e6ddcef8c5
2020-08-21 14:03:51 +02:00
Harald Welte 9d09c4d3fd ttcn3_makefilegen: Generate gnu make files (we use Linux...)
Change-Id: I21de4dd375139ad24c742c12a948f7ba0b0ade76
2020-03-02 14:25:47 +01:00
Harald Welte 0cdf071e8a Put build / run scripts under Apache 2.0 license
The license of the build or execution scripts doesn't affect the license
of the actual program, and we want to explicitly state that these scripts may
be used in any kind of context.

Change-Id: I553925cd88b05903aab52ae1afb093aa9ab9d035
2019-06-21 09:34:09 +00:00
Harald Welte 01e72d56e8 regen-makefile: Use '-U 5' to split C++ files in multiple chunks
Particularly the C++ files generated for the rather comprehensive
3GPP asn.1 specified protocols like MAP, RANAP, ... result in very
large source files and subsequently g++ processes that consume well
into the multiple gigabyte range of memory.

Let's use the '-U 5' option to ask the ttcn3_compiler to split all
c++ files into 5 chunks, resulting in more files to compile, but
smaller individual files.

I also tested '-U type' before, but it was still grinding my 16GB RAM
laptop to unusable deep-swapping state when running 'make -j8' for
the IuCS extended MSC test suite.

Change-Id: I013b623e98d58a39dd7bb2b0db4a911725028535
2019-04-30 19:07:47 +02:00
Daniel Willmann f6c5da90f0 Fix compilation on eclipse-titan 6.5.1
Newer eclipse-titan makefilegen already sets CPPFLAGS like this:

CPPFLAGS = -D$(PLATFORM) -I$(TTCN3_DIR)/include$(TTCN3_SUBDIR)

where TTCN3_SUBDIR expands to '/titan' and TTCN3_DIR to '/usr'

If we add /titan after include we end up with
-I/usr/include/titan/titan/ which will cause the compile to fail due to
a missing TTCN3.hh include.

Check the titan version so we retain backwards compatibility.

Change-Id: If9fef29ce243be112d3735f0236335197f8f140f
Related: OS#3179
Sponsored-by: On-Waves ehf.
2019-02-15 07:49:54 +00:00
Max 8b9e69f291 Remove -Wall for autogenerated code
There seems to be no option for ttcn3_makefilegen to disable generated
code warnings so the only way to clear output from useless warnings
about indentation and such is to manually strip -Wall using sed.

Change-Id: I7ef141f7f3370a1bf909845ce8a4eb650b33fa81
2018-12-18 10:25:47 +00:00
Max 00fcc49278 regen-makefile.sh: add link to related Debian bug in comment
This makes it easier to track when this workaround can be disabled once
Debian/upstream (hopefully) resolve the issue.

Change-Id: I3c4ed0ae5c1145f162b2745f4a46705b51874b5b
2018-12-11 12:33:37 +01:00
Harald Welte af5bce4f97 Add SGsAP_CodecPort + SGsAP_Emulation module
Change-Id: I530f8f444d1c7ea0bf11d510da7b97f64a2039f5
2018-10-28 09:52:34 +00:00
Stefan Sperling 526895e7d4 support ccache to speed up ttcn3 test compilation
By default, if ccache is found in PATH when regen-makefile.sh runs,
use cached compiled C++ object files during the build (or populate
the cache in case an object is not cached yet). Objects are cached
in ccache's default cache directory (~/.ccache) unless overriden by
the CCACHE_DIR environment variable.

The USE_CCACHE environment variable overrides auto-detection
in regen-makefile.sh and disables (USE_CCACHE=0) or enables
(USE_CCACHE=1) use of ccache.

Rebuilding the test suite from scratch with a populated cache
is an order of magnitude faster than doing an initial build.
ccache only speeds up C++ (.cc) to object file (.o) compilation.
Linking object (.o) files into shared object (.so) files is still
performed by the real compiler during every build.

Change-Id: Ibb538f602206535c06980f88191c1dabe3c4cd82
2018-04-06 16:58:46 +00:00
Harald Welte df277258f1 IPA_Emulation: Make dependencies to RSL/MGCP/SCCP/GSUP conditional
Let's use the preprocessor to avoid IPA_Emulation pulling *all*
dependencies into each and any of our projects.  The code readability
suffers a bit from the many #ifdefs, but compilation speed increases
if we don't have to pull in all those (recursive) dependencies.

After all, a BTS test case will never need SCCP, GSUP or MGCP.

Change-Id: Ic0231adbd2171214de133d26b3fbf36130ee8aa0
2018-02-20 16:17:17 +01:00
Pau Espin ef85dfa942 regen-makefile.sh: Exit with clear error if ttcn3 bin not found
Change-Id: I866a758ec472968f368866e3b3b24dc6f14ac7cb
2018-01-29 11:51:52 +01:00
Pau Espin 5c9d99f735 regen-makefile.sh: Support Archlinux install paths
Archlinux (titan-git AUR package) installs everything (includes, libs
and bin) into /usr/ttcn/ prefix.

Change-Id: I545f2f04890310e98233b04b44c4614df34f2f17
2018-01-29 11:51:52 +01:00
Max dbf15f8eab Avoid gcc version check
By default the build fails on Debian due to gcc version check in
/usr/include/titan/cversion.h - instead of asking users to manually
change this file let's add workaround to our makefile fixer which
disables this check automatically.

The corresponding Debian bug:
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=879816

Change-Id: I71c765d5d8e182a198e2c5d2886ebce3b86e6328
2017-12-13 18:08:25 +01:00
Harald Welte 20a58c6d6f generalize shared code from regen_makefile.sh into shared helper script
Change-Id: I86a738420851a7d9e3bdb2671f6862c3d505a4ba
2017-12-13 01:04:42 +01:00