Skip to content
Browse files

meta-woce: Give birth to the layer

Signed-off-by: Khem Raj <raj.khem@gmail.com>
  • Loading branch information...
0 parents commit ec5a9212bc5d9fd28258d97e675844c0a81e61f1 @kraj committed Mar 31, 2012
17 COPYING.MIT
@@ -0,0 +1,17 @@
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
18 README
@@ -0,0 +1,18 @@
+This layer depends on:
+
+URI: git://git.openembedded.org/openembedded-core
+branch: master
+revision: HEAD
+
+URI: git://git.openembedded.org/meta-openembedded
+branch: master
+revision: HEAD
+
+URI: git://github.com/kraj/meta-slugos.git
+branch: master
+revision: HEAD
+
+Send pull requests to openembedded-devel@lists.openembedded.org
+
+Layer maintainers: Khem Raj <raj.khem@gmail.com>
+ Mike Westerhof <mike@mwester.net>
30 conf/distro/include/arm-thumb.inc
@@ -0,0 +1,30 @@
+#tune file for thumb instructions
+
+ARM_INSTRUCTION_SET ?= "arm"
+# "arm" "thumb"
+# The instruction set the compiler should use when generating application
+# code. The kernel is always compiled with arm code at present. arm code
+# is the original 32 bit ARM instruction set, thumb code is the 16 bit
+# encoded RISC sub-set. Thumb code is smaller (maybe 70% of the ARM size)
+# but requires more instructions (140% for 70% smaller code) so may be
+# slower.
+
+THUMB_INTERWORK ?= "no"
+# "yes" "no"
+# Whether to compile with code to allow interworking between the two
+# instruction sets. This allows thumb code to be executed on a primarily
+# arm system and vice versa. It is strongly recommended that DISTROs not
+# turn this off - the actual cost is very small.
+
+OVERRIDE_THUMB = "${@['', 'thumb:'][bb.data.getVar('ARM_INSTRUCTION_SET', d, 1) == 'thumb']}"
+OVERRIDE_INTERWORK = "${@['', 'thumb-interwork:'][bb.data.getVar('THUMB_INTERWORK', d, 1) == 'yes']}"
+OVERRIDES_prepend_arm =. "${OVERRIDE_THUMB}${OVERRIDE_INTERWORK}"
+
+# Compiler and linker options for application code and kernel code. These
+# options ensure that the compiler has the correct settings for the selected
+# instruction set and interworking.
+ARM_INTERWORK_M_OPT = "${@['-mno-thumb-interwork', '-mthumb-interwork'][bb.data.getVar('THUMB_INTERWORK', d, 1) == 'yes']}"
+ARM_THUMB_M_OPT = "${@['-mno-thumb', '-mthumb'][bb.data.getVar('ARM_INSTRUCTION_SET', d, 1) == 'thumb']}"
+
+TARGET_CC_ARCH_append_arm =. " ${ARM_INTERWORK_M_OPT} ${ARM_THUMB_M_OPT}"
+TARGET_CC_KERNEL_ARCH_append_arm =. " -mno-thumb-interwork -mno-thumb"
0 conf/distro/include/woce-eglibc.inc
No changes.
3 conf/distro/include/woce-uclibc.inc
@@ -0,0 +1,3 @@
+ARM_INSTRUCTION_SET = "thumb"
+IMAGE_DEV_MANAGER = "busybox-mdev"
+PREFERRED_PROVIDER_virtual/libintl = "proxy-libintl"
186 conf/distro/include/woce.inc
@@ -0,0 +1,186 @@
+#@TYPE: Distribution
+#@NAME: WebOS
+#@DESCRIPTION: WebOS Linux Distribution
+
+# WARNING: this file should not be used directly, use one of
+# the supported WOCE derived distributions instead.
+
+#----------------------------------------------------------------------------------
+# STANDARD SLUGOS DEFINITIONS
+#----------------------------------------------------------------------------------
+# The following must be set in the top level distro file:
+#
+#DISTRO_NAME
+#DISTRO_TYPE
+#ARM_INSTRUCTION_SET "arm" or "thumb"
+#TARGET_OS "linux" or "linux-uclibc"
+
+# The following may be overridden to make sub-versions
+WOCE_VERSION = "1.0"
+DISTRO_REVISION ?= ""
+DISTRO_VERSION ?= "${WOCE_VERSION}${DISTRO_REVISION}-${DISTRO_TYPE}"
+# For release (only):
+# DISTRO_FEED ?= "${SLUGOS_VERSION}-${DISTRO_TYPE}"
+DISTRO_FEED ?= "unstable"
+
+THUMB_INTERWORK = "yes"
+# "yes" "no"
+# Whether to compile with code to allow interworking between the two
+# instruction sets. This allows thumb code to be executed on a primarily
+# arm system and vice versa. It is strongly recommended that DISTROs not
+# turn this off - the actual cost is very small.
+# We want images supporting the following features (for task-base)
+DISTRO_FEATURES = "largefile ipv4 ipv6 nfs smbfs wifi ppp alsa bluetooth ext2 vfat irda pcmcia usbhost pci eabi xattr ${DISTRO_FEATURES_LIBC}"
+# We may also wish to enable raid support at some point (space permitting)
+#DISTRO_FEATURES += " raid"
+
+# Add thumb-interwork to feature list if selected machine supports it.
+DISTRO_FEATURES += ' ${@["", "thumb-interwork"][bb.data.getVar('THUMB_INTERWORK', d, 1) == "yes"]}'
+
+DISTRO_FEATURES += "${DISTRO_FEATURES_LIBC}"
+
+IMAGE_BASENAME = "woce-${TCLIBC}"
+
+# The following need not be set, the defaults should be adequate
+#USE_NLS = "no" or "yes"
+USE_NLS ?= "no"
+
+# To make errors easier to identify:
+DISTRO_NAME ?= "INVALID-${TCLIBC}"
+DISTRO_TYPE ?= "INVALID"
+
+# The following must not be changed.
+TARGET_FPU = "soft"
+
+# so we get armv5teb etc into overrides, uclibc configs depend on it
+# to choose proper config
+
+MACHINEOVERRIDES .= ":${@bb.data.getVar('TUNE_PKGARCH', d,1).replace('all','noarch')}"
+
+# glib-2.0 builds require USE_NLS to be overridden
+USE_NLS_glib-2.0 = "yes"
+USE_NLS_glib-2.0-native = "yes"
+USE_NLS_gcc-cross = "no"
+
+# FULL_OPTIMIZATION
+# Optimization settings. Os works fine and is significantly better than O2.
+FULL_OPTIMIZATION = "-g -Os"
+
+# We need to keep OABI compat for things like madwifi-ng.
+ARM_KEEP_OABI = "1"
+
+CXXFLAGS += "-fvisibility-inlines-hidden"
+
+# There is a problem of sorts with Perl. This needs a better home eventually,
+# but for now put it in this file.
+FULL_OPTIMIZATION_pn-perl = "-O1"
+BUILD_OPTIMIZATION_pn-perl = "-O1"
+
+#----------------------------------------------------------------------------------
+# FEEDS
+# The FEED_URIS lines define where on the internet SlugOS looks for packages
+# when downloading new packages or updating existing packages. Additional feeds
+# (such as a local feed) can be defined in local.conf
+#----------------------------------------------------------------------------------
+#
+FEED_URIS_append += "cross##http://ipkg.webosinternals.org/feeds/${IMAGE_BASENAME}/cross/${DISTRO_FEED}"
+#FEED_URIS_append += "native##http://ipkg.nslu2-linux.org/feeds/${IMAGE_BASENAME}/native/${DISTRO_FEED}"
+
+#----------------------------------------------------------------------------------
+# FIRMWARE CONFIGURATION
+#----------------------------------------------------------------------------------
+# IMAGE BUILD OPTIONS
+# -------------------
+# CMDLINE* macros define the kernel command line. CMDLINE_DEBUG is provided
+# to enable/disable debugging in the distro. Here noirqdebug is used to
+# remove the messages about unhandled interrupts - people debugging interrupt
+# issues in the kernel need to cancel this (set CMDLINE_DEBUG empty in local.conf)
+CMDLINE_ROOT = "root=/dev/mtdblock4 rootfstype=jffs2 rootflags=noatime rw init=/linuxrc"
+CMDLINE_DEBUG = "noirqdebug"
+
+# EXTRA PACKAGES
+# --------------
+# SlugOS builds an image with no extra packages - to add packages to the
+# firmware include this file in a new 'distro' configuration file) and set
+# the definition below to include the requirements.
+# NOTE: as built this system will *not* be able to boot off anything other than
+# the flash file system ('turnup' will not work). You need to add the filesystem
+# modules for your chosen root file system (and any others which will be used).
+#
+# Everything in this list gets added to the flash image, along with any RDEPENDS
+# it has itself!
+DISTRO_EXTRA_DEPENDS ?= ""
+DISTRO_EXTRA_RDEPENDS ?= ""
+DISTRO_EXTRA_RRECOMMENDS ?= ""
+
+SOURCE_MIRROR_URL ?= "http://sources.openembedded.org/sources/"
+
+MIRRORS += " \
+ftp://.*/.* http://mirrors.openembedded.org/ \n \
+https?$://.*/.* http://mirrors.openembedded.org/ \n \
+ftp://.*/.* http://sources.openembedded.org/ \n \
+https?$://.*/.* http://sources.openembedded.org/ \n \
+"
+USER_CLASSES = "own-mirrors buildhistory"
+PACKAGE_CLASSES = "package_ipk"
+INHERIT_INSANE = "insane"
+INHERIT_DISTRO = "debian devshell sstate license"
+
+BUILDHISTORY_COMMIT = "1"
+
+#FIXME: HACK: REMOVE THIS
+IGNORE_STRIP_ERRORS = ""
+
+#----------------------------------------------------------------------------------
+# PACKAGE VERSION CONTROL
+#----------------------------------------------------------------------------------
+# Define how to bootstrap the system - we need cross compilers. It is also
+# necessary to define which gets generated first, glibc or the kernel, and
+# this is done by selecting the provider of libc (in this case it needs the
+# kernel, so there has to be a non-libc gcc to build the kernel!)
+
+# Virtuals:
+
+# Select the appropriate x11 library provider. The diet-x11 libraries are
+# much smaller, but may not be as current as the standard x11 libraries; by
+# default we will select the standard libraries and permit the use of an
+# override if the user wishes (and has the correct PREFERRED_VERSIONs set).
+PREFERRED_PROVIDER_virtual/libx11 ?= "libx11"
+PREFERRED_PROVIDER_virtual/libx11-native ?= "libx11-native"
+
+# Ensure consistency across all SlugOS builds for the provider of a relational
+# database - use the latest version of the SleepyCat Berkeley database
+PREFERRED_PROVIDER_virtual/db = "db"
+PREFERRED_PROVIDER_virtual/db-native = "db-native"
+
+SRCDATE_irssi ?= "20050930"
+
+# we don't ship gtk-directfb by default
+PREFERRED_PROVIDER_gtk+ ?= "gtk+"
+PREFERRED_PROVIDER_gdk-pixbuf-loader-ani ?= "gtk+"
+PREFERRED_PROVIDER_gdk-pixbuf-loader-bmpg ?= "gtk+"
+PREFERRED_PROVIDER_gdk-pixbuf-loader-gif ?= "gtk+"
+PREFERRED_PROVIDER_gdk-pixbuf-loader-ico ?= "gtk+"
+PREFERRED_PROVIDER_gdk-pixbuf-loader-jpeg ?= "gtk+"
+PREFERRED_PROVIDER_gdk-pixbuf-loader-pcx ?= "gtk+"
+PREFERRED_PROVIDER_gdk-pixbuf-loader-png ?= "gtk+"
+PREFERRED_PROVIDER_gdk-pixbuf-loader-pnm ?= "gtk+"
+PREFERRED_PROVIDER_gdk-pixbuf-loader-ras ?= "gtk+"
+PREFERRED_PROVIDER_gdk-pixbuf-loader-tga ?= "gtk+"
+PREFERRED_PROVIDER_gdk-pixbuf-loader-wbmp ?= "gtk+"
+PREFERRED_PROVIDER_gdk-pixbuf-loader-xbm ?= "gtk+"
+PREFERRED_PROVIDER_gdk-pixbuf-loader-xpm ?= "gtk+"
+
+PREFERRED_PROVIDER_avahi ?= "avahi"
+PREFERRED_PROVIDER_ifupdown ?= "ifupdown"
+PREFERRED_PROVIDER_gconf ?= "gconf"
+PREFERRED_PROVIDER_virtual/libqte2 ?= "qte"
+PREFERRED_PROVIDER_virtual/libusb0 ?= "libusb-compat"
+
+# we use bluez4 instead of the older bluez3
+DISTRO_BLUETOOTH_MANAGER = "bluez4"
+PREFERRED_PROVIDER_bluez-utils-dbus = "bluez4"
+PREFERRED_PROVIDER_bluez-libs = "bluez4"
+PREFERRED_PROVIDER_bluez-utils = "bluez4"
+
+# Include any package preferred versions and srcrevs:
33 conf/distro/woce.conf
@@ -0,0 +1,33 @@
+#@TYPE: Distribution
+#@NAME: WOCE
+#@DESCRIPTION: WebOS Community Edition Linux Distribution
+
+DISTRO_NAME = "WOCE"
+DISTRO_TYPE = "alpha"
+
+ARM_INSTRUCTION_SET = "thumb"
+
+PREFERRED_PROVIDER_opkg ?= "opkg"
+PREFERRED_PROVIDER_opkg-native ?= "opkg-native"
+PREFERRED_PROVIDER_virtual/update-alternatives-native ?= "opkg-native"
+PREFERRED_PROVIDER_virtual/update-alternatives ?= "opkg"
+PREFERRED_PROVIDER_opkg-nativesdk ?= "opkg-nativesdk"
+VIRTUAL-RUNTIME_update-alternatives = "opkg"
+IMAGE_DEV_MANAGER = "udev"
+# Disable installing ldconfig
+USE_LDCONFIG = "0"
+
+TARGET_VENDOR = "-oe"
+SDK_VENDOR = "-oesdk"
+TARGET_FPU_arm ?= "soft"
+TARGET_FPU_armeb ?= "soft"
+
+EGLIBCVERSION ?= "2.15"
+UCLIBCVERSION = "0.9.32+0.9.33%"
+TCMODE ?= "default"
+
+TCLIBC ?= "eglibc"
+require conf/distro/include/default-distrovars.inc
+require conf/distro/include/woce-${TCLIBC}.inc
+require conf/distro/include/woce.inc
+require conf/distro/include/arm-thumb.inc
9 conf/layer.conf
@@ -0,0 +1,9 @@
+# We have a conf and classes directory, append to BBPATH
+BBPATH .= ":${LAYERDIR}"
+
+# We have a recipes directory, add to BBFILES
+BBFILES += "${LAYERDIR}/recipes*/*/*.bb ${LAYERDIR}/recipes*/*/*.bbappend"
+
+BBFILE_COLLECTIONS += "woce-layer"
+BBFILE_PATTERN_slugos-layer := "^${LAYERDIR}/"
+BBFILE_PRIORITY_slugos-layer = "7"

0 comments on commit ec5a921

Please sign in to comment.
Something went wrong with that request. Please try again.