diff options
Diffstat (limited to 'recipes-core')
-rw-r--r-- | recipes-core/base-files/base-files_3.0.14.bbappend | 2 | ||||
-rw-r--r-- | recipes-core/busybox/busybox_%.bbappend (renamed from recipes-core/busybox/busybox_1.22.1.bbappend) | 2 | ||||
-rw-r--r-- | recipes-core/busybox/files/defconfig (renamed from recipes-core/busybox/busybox-1.22.1/defconfig) | 0 | ||||
-rw-r--r-- | recipes-core/eglibc/eglibc_%.bbappend.obsolete (renamed from recipes-core/eglibc/eglibc_%.bbappend) | 0 | ||||
-rw-r--r-- | recipes-core/images/mlinux-base-image.bb | 2 | ||||
-rw-r--r-- | recipes-core/images/mlinux-factory-image.bb | 11 | ||||
-rw-r--r-- | recipes-core/images/mlinux-minimal-image.bb | 2 | ||||
-rw-r--r-- | recipes-core/init-ifupdown/init-ifupdown_1.0.bbappend | 3 | ||||
-rw-r--r-- | recipes-core/initscripts/initscripts-1.0/umountfs | 11 | ||||
-rw-r--r-- | recipes-core/mlinux-scripts/mlinux-scripts-1.0.inc | 2 | ||||
-rw-r--r-- | recipes-core/multitech/reset-handler_1.0.bb | 1 | ||||
-rw-r--r-- | recipes-core/udev/eudev/cellular_radios.rules (renamed from recipes-core/udev/udev-182/cellular_radios.rules) | 0 | ||||
-rw-r--r-- | recipes-core/udev/eudev/init (renamed from recipes-core/udev/udev-182/init) | 0 | ||||
-rw-r--r-- | recipes-core/udev/eudev/mtcap/mtcap.rules (renamed from recipes-core/udev/udev-182/mtcap/mtcap.rules) | 0 | ||||
-rw-r--r-- | recipes-core/udev/eudev/mtcdt/accessory_ethernet.rules (renamed from recipes-core/udev/udev-182/mtcdt/accessory_ethernet.rules) | 0 | ||||
-rw-r--r-- | recipes-core/udev/eudev/mtcdt/mtcdt.rules (renamed from recipes-core/udev/udev-182/mtcdt/mtcdt.rules) | 0 | ||||
-rw-r--r-- | recipes-core/udev/eudev/udev-cache.default (renamed from recipes-core/udev/udev-182/udev-cache.default) | 0 | ||||
-rw-r--r-- | recipes-core/udev/eudev_%.bbappend (renamed from recipes-core/udev/udev_182.bbappend) | 1 | ||||
-rw-r--r-- | recipes-core/udev/udev-extraconf_%.bbappend (renamed from recipes-core/udev/udev-extraconf_1.0.bbappend) | 0 | ||||
-rw-r--r-- | recipes-core/useradd/useradd.bb | 57 |
20 files changed, 82 insertions, 12 deletions
diff --git a/recipes-core/base-files/base-files_3.0.14.bbappend b/recipes-core/base-files/base-files_3.0.14.bbappend index 0f0ae4f..b9a4231 100644 --- a/recipes-core/base-files/base-files_3.0.14.bbappend +++ b/recipes-core/base-files/base-files_3.0.14.bbappend @@ -1,4 +1,4 @@ -FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}" +FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:" media_card="/media/card" media_card_mtcap="" diff --git a/recipes-core/busybox/busybox_1.22.1.bbappend b/recipes-core/busybox/busybox_%.bbappend index 40094e9..4c6e752 100644 --- a/recipes-core/busybox/busybox_1.22.1.bbappend +++ b/recipes-core/busybox/busybox_%.bbappend @@ -1,6 +1,6 @@ PR .= ".mlinux1" -FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}-${PV}:${THISDIR}/files:" +FILESEXTRAPATHS_prepend := ":${THISDIR}/files:" SRC_URI += "file://udhcpd.conf.example" diff --git a/recipes-core/busybox/busybox-1.22.1/defconfig b/recipes-core/busybox/files/defconfig index aa1e514..aa1e514 100644 --- a/recipes-core/busybox/busybox-1.22.1/defconfig +++ b/recipes-core/busybox/files/defconfig diff --git a/recipes-core/eglibc/eglibc_%.bbappend b/recipes-core/eglibc/eglibc_%.bbappend.obsolete index 68af86e..68af86e 100644 --- a/recipes-core/eglibc/eglibc_%.bbappend +++ b/recipes-core/eglibc/eglibc_%.bbappend.obsolete diff --git a/recipes-core/images/mlinux-base-image.bb b/recipes-core/images/mlinux-base-image.bb index a0c460d..3ba6b2f 100644 --- a/recipes-core/images/mlinux-base-image.bb +++ b/recipes-core/images/mlinux-base-image.bb @@ -29,7 +29,7 @@ WIFI_FEATURES = " \ hostap-daemon hostap-utils \ " -BLUETOOTH_FEATURES = "bluez4" +BLUETOOTH_FEATURES = "bluez5" # Add all timezones available # ntpdate will sync time every 30 min by default via cron diff --git a/recipes-core/images/mlinux-factory-image.bb b/recipes-core/images/mlinux-factory-image.bb index c50619b..9da3040 100644 --- a/recipes-core/images/mlinux-factory-image.bb +++ b/recipes-core/images/mlinux-factory-image.bb @@ -25,8 +25,10 @@ IMAGE_INSTALL += "monit" IMAGE_INSTALL += "lora-gateway-utils lora-network-server lora-query lora-packet-forwarder-usb" # MQTT server +#IMAGE_INSTALL += "mosquitto" IMAGE_INSTALL += "mosquitto mosquitto-clients" + # Perl support IMAGE_INSTALL += "perl" IMAGE_INSTALL += "perl-module-io perl-module-fcntl" @@ -58,17 +60,18 @@ python-xml \ # Ruby support IMAGE_INSTALL += "ruby" + IMAGE_INSTALL += "ruby-sqlite3" IMAGE_INSTALL += "ruby-serialport" # OpenJDK Java runtime -IMAGE_INSTALL += "openjdk-7-jre" +# IMAGE_INSTALL += "openjdk-8" # OpenJDK with JamVM VM (Multi-Tech default) -IMAGE_INSTALL += "openjdk-7-vm-jamvm" +# IMAGE_INSTALL += "jamvm" # OpenJDK with CACAO VM (run with 'java -cacao') -IMAGE_INSTALL += "openjdk-7-vm-cacao" +# IMAGE_INSTALL += "openjdk-7-vm-cacao" # OpenJDK Zero VM (run with 'java -zero') -IMAGE_INSTALL += "openjdk-7-vm-zero" +# IMAGE_INSTALL += "openjdk-7-vm-zero" # PHP support IMAGE_INSTALL += "php php-cli php-cgi" diff --git a/recipes-core/images/mlinux-minimal-image.bb b/recipes-core/images/mlinux-minimal-image.bb index 2f2d61b..1a92e8e 100644 --- a/recipes-core/images/mlinux-minimal-image.bb +++ b/recipes-core/images/mlinux-minimal-image.bb @@ -16,8 +16,10 @@ CORE_FEATURES = "packagegroup-core-boot packagegroup-distro-base \ openssh-sftp-server \ util-linux-mount util-linux-umount \ start-stop-daemon \ + sudo \ ${CORE_IMAGE_EXTRA_INSTALL} \ mlinux-feed-configs \ + useradd \ " NETWORKING_FEATURES = "ppp curl iproute2 \ diff --git a/recipes-core/init-ifupdown/init-ifupdown_1.0.bbappend b/recipes-core/init-ifupdown/init-ifupdown_1.0.bbappend index 5249571..9d000d6 100644 --- a/recipes-core/init-ifupdown/init-ifupdown_1.0.bbappend +++ b/recipes-core/init-ifupdown/init-ifupdown_1.0.bbappend @@ -4,10 +4,9 @@ SRC_URI += "file://bonding.pre-up \ file://bonding.up \ file://bonding.post-down" -FILESEXTRAPATHS_prepend := "${THISDIR}/files" +FILESEXTRAPATHS_prepend := "${THISDIR}/files:" do_install_append () { - echo JAK workdir ${WORKDIR} sysconfdir ${D}${sysconfdir} install -m 0755 ${WORKDIR}/bonding.pre-up ${D}${sysconfdir}/network/if-pre-up.d/bonding install -m 0755 ${WORKDIR}/bonding.up ${D}${sysconfdir}/network/if-up.d/bonding install -m 0755 ${WORKDIR}/bonding.post-down ${D}${sysconfdir}/network/if-post-down.d/bonding diff --git a/recipes-core/initscripts/initscripts-1.0/umountfs b/recipes-core/initscripts/initscripts-1.0/umountfs index 8c12ebe..bfd4d47 100644 --- a/recipes-core/initscripts/initscripts-1.0/umountfs +++ b/recipes-core/initscripts/initscripts-1.0/umountfs @@ -10,6 +10,7 @@ ### END INIT INFO PATH=/sbin:/bin:/usr/sbin:/usr/bin +upgrade_fname="/var/volatile/do_flash_upgrade" umount_all() { echo "Deactivating swap..." @@ -256,9 +257,13 @@ flash_upgrade() { } # do flash on reboot if do_flash_upgrade exists -if [ -f /var/volatile/do_flash_upgrade ]; then - flash_upgrade /var/volatile - flash_upgrade /media/card +# and is owned by root +if [[ -f ${upgrade_fname} ]] ; then + owner=$(stat -c%u "${upgrade_fname}") + if ((${#owner} > 0)) && ((owner == 0)) ; then + flash_upgrade /var/volatile + flash_upgrade /media/card + fi fi umount_all diff --git a/recipes-core/mlinux-scripts/mlinux-scripts-1.0.inc b/recipes-core/mlinux-scripts/mlinux-scripts-1.0.inc index 979fc4c..0f5c136 100644 --- a/recipes-core/mlinux-scripts/mlinux-scripts-1.0.inc +++ b/recipes-core/mlinux-scripts/mlinux-scripts-1.0.inc @@ -3,6 +3,8 @@ PRIORITY = "optional" LICENSE = "MIT" LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302" +RDEPENDS_${PN} += "bash" + SRC_URI = "file://mlinux-wifi-ap \ file://mlinux-dhcpd \ file://mlinux-set-apn \ diff --git a/recipes-core/multitech/reset-handler_1.0.bb b/recipes-core/multitech/reset-handler_1.0.bb index 9ccd475..39abaab 100644 --- a/recipes-core/multitech/reset-handler_1.0.bb +++ b/recipes-core/multitech/reset-handler_1.0.bb @@ -3,6 +3,7 @@ SECTION = "base" LICENSE = "MIT" LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302" PR = "r1" +RDEPENDS_${PN} += "bash" inherit update-rc.d diff --git a/recipes-core/udev/udev-182/cellular_radios.rules b/recipes-core/udev/eudev/cellular_radios.rules index fd36bbd..fd36bbd 100644 --- a/recipes-core/udev/udev-182/cellular_radios.rules +++ b/recipes-core/udev/eudev/cellular_radios.rules diff --git a/recipes-core/udev/udev-182/init b/recipes-core/udev/eudev/init index bd716b0..bd716b0 100644 --- a/recipes-core/udev/udev-182/init +++ b/recipes-core/udev/eudev/init diff --git a/recipes-core/udev/udev-182/mtcap/mtcap.rules b/recipes-core/udev/eudev/mtcap/mtcap.rules index a0dc9fb..a0dc9fb 100644 --- a/recipes-core/udev/udev-182/mtcap/mtcap.rules +++ b/recipes-core/udev/eudev/mtcap/mtcap.rules diff --git a/recipes-core/udev/udev-182/mtcdt/accessory_ethernet.rules b/recipes-core/udev/eudev/mtcdt/accessory_ethernet.rules index 376486b..376486b 100644 --- a/recipes-core/udev/udev-182/mtcdt/accessory_ethernet.rules +++ b/recipes-core/udev/eudev/mtcdt/accessory_ethernet.rules diff --git a/recipes-core/udev/udev-182/mtcdt/mtcdt.rules b/recipes-core/udev/eudev/mtcdt/mtcdt.rules index 5d528e6..5d528e6 100644 --- a/recipes-core/udev/udev-182/mtcdt/mtcdt.rules +++ b/recipes-core/udev/eudev/mtcdt/mtcdt.rules diff --git a/recipes-core/udev/udev-182/udev-cache.default b/recipes-core/udev/eudev/udev-cache.default index b1aa63f..b1aa63f 100644 --- a/recipes-core/udev/udev-182/udev-cache.default +++ b/recipes-core/udev/eudev/udev-cache.default diff --git a/recipes-core/udev/udev_182.bbappend b/recipes-core/udev/eudev_%.bbappend index e793d1d..2a15734 100644 --- a/recipes-core/udev/udev_182.bbappend +++ b/recipes-core/udev/eudev_%.bbappend @@ -6,6 +6,7 @@ PR .= ".mlinux2" SRC_URI += " file://cellular_radios.rules \ file://${MACHINE}.rules \ " +FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:" SRC_URI_append_mtcdt = " file://accessory_ethernet.rules \ " diff --git a/recipes-core/udev/udev-extraconf_1.0.bbappend b/recipes-core/udev/udev-extraconf_%.bbappend index 6d4804d..6d4804d 100644 --- a/recipes-core/udev/udev-extraconf_1.0.bbappend +++ b/recipes-core/udev/udev-extraconf_%.bbappend diff --git a/recipes-core/useradd/useradd.bb b/recipes-core/useradd/useradd.bb new file mode 100644 index 0000000..458facf --- /dev/null +++ b/recipes-core/useradd/useradd.bb @@ -0,0 +1,57 @@ +SUMMARY = "Add mtadm user" +DESCRIPTION = "Add mtadm user for security purposes" +SECTION = "mtadm" +PR = "r1" +LICENSE = "MIT" +LIC_FILES_CHKSUM = "file://${COREBASE}/LICENSE;md5=4d92cd373abda3937c2bc47fbc49d690 \ + file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420" + +S = "${WORKDIR}" + +inherit useradd + +# You must set USERADD_PACKAGES when you inherit useradd. This +# lists which output packages will include the user/group +# creation code. +#USERADD_PACKAGES = "${PN} ${PN}-user3" +USERADD_PACKAGES = "${PN}" + +# You must also set USERADD_PARAM and/or GROUPADD_PARAM when +# you inherit useradd. + +# GROUPADD_PARAM works the same way, which you set to the options +# you'd normally pass to the groupadd command. This will create +# groups group1 and group2: +GROUPADD_PARAM_${PN} = "-r -g 27 sudo" + +# USERADD_PARAM specifies command line options to pass to the +# useradd command. Multiple users can be created by separating +# the commands with a semicolon. Here we'll create two users, +# user1 and user2: +USERADD_PARAM_${PN} = "-u 50 -G sudo -m -r -s /bin/bash mtadm" + +do_install () { + # If the recipe doesn't have a file, the ipk + # is deleted, and it does nothing. + # Create a .ssh directory for mtadm. + install -d 0700 ${D}/home/mtadm/.ssh + chown mtadm:mtadm ${D}/home/mtadm + chown mtadm:mtadm ${D}/home/mtadm/.ssh +} + +FILES_${PN} = "/home/mtadm/.ssh" + +# Prevents do_package failures with: +# debugsources.list: No such file or directory: +INHIBIT_PACKAGE_DEBUG_SPLIT = "1" + +pkg_postinst_${PN} () { + profile=/home/mtadm/.profile + if ! grep 'sbin' ${profile} ; then + Sub='${PA' + Sub=${Sub}'TH}:/sbin:/usr/sbin' + echo 'PATH='${Sub} >>/home/mtadm/.profile + echo 'export PATH' >>/home/mtadm/.profile + fi +} + |