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