blob: 956d05c27adbf8f777bc1d5f397776493fda09ee [file] [log] [blame]
Neels Hofmeyr1804aa82017-03-29 16:45:51 +02001DESCRIPTION = "OsmoMSC, OsmoSGSN, OsmoMGCP"
2DEPENDS = "libdbi libosmocore libosmo-sccp libosmo-abis libosmo-netif openggsn libsmpp34 bcg729 libgsm libpcap c-ares libasn1c osmo-iuh"
3HOMEPAGE = "http://osmocom.org/projects/osmomsc"
4LICENSE = "AGPLv3+"
5LIC_FILES_CHKSUM = "file://COPYING;md5=73f1eb20517c55bf9493b7dd6e480788"
6
7RDEPENDS_osmo-msc = "libdbd-sqlite3"
8
9SRC_URI = "file://osmo-msc.init \
10 file://osmo-bsc_mgcp.init \
11 file://osmo-sgsn.init"
12
Daniel Willmann67d36212017-08-01 03:39:11 +020013INC_PR = "r2.${META_TELEPHONY_OSMO_INC}"
Neels Hofmeyr1804aa82017-03-29 16:45:51 +020014
15
16EXTRA_OECONF += " --enable-iu --enable-smpp --enable-mgcp-transcoding --with-g729"
17
18inherit autotools update-rc.d pkgconfig
19
20# because "${WORKDIR}/git" is not a git repo, it can't figure out the version
21do_configure_prepend() {
22 echo "${PV}" > ${S}/.tarball-version
23}
24
25do_install_append() {
26 install -d ${D}${sysconfdir}/osmocom
27 install -m 0660 ${S}/doc/examples/osmo-msc/osmo-msc.cfg ${D}${sysconfdir}/osmocom/osmo-msc.cfg
28 install -m 0660 ${S}/doc/examples/osmo-bsc_mgcp/mgcp.cfg ${D}${sysconfdir}/osmocom/osmo-bsc-mgcp.cfg
29 install -m 0660 ${S}/doc/examples/osmo-sgsn/osmo-sgsn.cfg ${D}${sysconfdir}/osmocom/osmo-sgsn.cfg
30
31 # Install sysv-init files
32 install -d ${D}${sysconfdir}/init.d
33 install -d ${D}${sysconfdir}/rc5.d
34 install -m 0775 ${WORKDIR}/osmo-msc.init ${D}${sysconfdir}/init.d/osmo-msc
35 install -m 0775 ${WORKDIR}/osmo-bsc_mgcp.init ${D}${sysconfdir}/init.d/osmo-bsc-mgcp
36 install -m 0775 ${WORKDIR}/osmo-sgsn.init ${D}${sysconfdir}/init.d/osmo-sgsn
37
38 # Install systemd files and enable on sysinit
39 install -d ${D}${systemd_unitdir}/system
Daniel Willmann67d36212017-08-01 03:39:11 +020040 install -m 0644 ${WORKDIR}/osmo-msc.service ${D}${systemd_unitdir}/system/
41 install -m 0644 ${WORKDIR}/osmo-sgsn.service ${D}${systemd_unitdir}/system/
42 install -m 0644 ${WORKDIR}/osmo-bsc-mgcp.service ${D}${systemd_unitdir}/system/
Neels Hofmeyr1804aa82017-03-29 16:45:51 +020043
44 install -d ${D}/var/lib/osmocom
45}
46
47PACKAGES =+ "osmo-msc osmo-sgsn osmo-bsc-mgcp ipaccess-utils"
48
49INITSCRIPT_PACKAGES = "osmo-msc osmo-sgsn osmo-bsc-mgcp"
50
51# Do not start any of the services by default
52SYSTEMD_AUTO_ENABLE = "disable"
53
54CONFFILES_osmo-msc = "${sysconfdir}/osmocom/osmo-msc.cfg"
55INITSCRIPT_NAME_osmo-msc = "osmo-msc"
56INITSCRIPT_PARAMS_osmo-msc = "defaults 30 30"
57FILES_osmo-msc = " ${bindir}/osmo-msc \
58 /var/lib/osmocom \
59 ${sysconfdir}/init.d/osmo-msc \
60 ${sysconfdir}/osmocom/osmo-msc.cfg \
61 ${systemd_unitdir}/system/osmo-msc.service \
62 "
63
64CONFFILES_osmo-sgsn = "${sysconfdir}/osmocom/osmo-sgsn.cfg"
65INITSCRIPT_NAME_osmo-sgsn = "osmo-sgsn"
66INITSCRIPT_PARAMS_osmo-sgsn = "defaults 30 30"
67FILES_osmo-sgsn = " ${bindir}/osmo-sgsn \
68 ${sysconfdir}/init.d/osmo-sgsn \
69 ${sysconfdir}/osmocom/osmo-sgsn.cfg \
70 ${systemd_unitdir}/system/osmo-sgsn.service \
71 "
72
73CONFFILES_osmo-bsc-mgcp = "${sysconfdir}/osmocom/osmo-bsc-mgcp.cfg"
74INITSCRIPT_NAME_osmo-bsc-mgcp = "osmo-bsc-mgcp"
75INITSCRIPT_PARAMS_osmo-bsc-mgcp = "defaults 30 30"
76FILES_osmo-bsc-mgcp = " ${bindir}/osmo-bsc_mgcp \
77 ${sysconfdir}/osmocom/osmo-bsc-mgcp.cfg \
78 ${sysconfdir}/init.d/osmo-bsc-mgcp \
79 ${systemd_unitdir}/system/osmo-bsc-mgcp.service \
80 "
81
82FILES_ipaccess-utils = " ${bindir}/ipaccess-find ${bindir}/ipaccess-config ${bindir}/ipaccess-proxy "