From 3c3d9a07f94293c49e354f3c07d9c392f54aaa65 Mon Sep 17 00:00:00 2001 From: Mirko Vogt Date: Tue, 13 Jan 2009 01:03:29 +0000 Subject: [PATCH] - updated to latest git snapshot - added init-script - added dirty patch to make it compatible to other libc's than just glibc - added default config-file for the Openmoko GTA02 "Freerunner" - some other minor changes SVN-Revision: 14005 --- phone/fso/Makefile | 19 +++-- phone/fso/files/frameworkd.conf | 0 phone/fso/files/frameworkd.conf.om_gta02 | 102 +++++++++++++++++++++++ phone/fso/files/frameworkd.init | 11 +++ phone/fso/patches/001-multilibc.patch | 56 +++++++++++++ 5 files changed, 183 insertions(+), 5 deletions(-) create mode 100644 phone/fso/files/frameworkd.conf create mode 100644 phone/fso/files/frameworkd.conf.om_gta02 create mode 100644 phone/fso/files/frameworkd.init create mode 100644 phone/fso/patches/001-multilibc.patch diff --git a/phone/fso/Makefile b/phone/fso/Makefile index aea174b15..048f1f110 100644 --- a/phone/fso/Makefile +++ b/phone/fso/Makefile @@ -8,8 +8,8 @@ include $(TOPDIR)/rules.mk PKG_NAME:=fso -PKG_VERSION:=20090103 -PKG_REV:=cbddf72db7ee7f06c5863bce6d4055652e66b25b +PKG_VERSION:=20090112 +PKG_REV:=2c47aa00f530c4ec698c024b583f250373185b09 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 @@ -23,11 +23,18 @@ PKG_BUILD_DEPENDS:=cython python include $(INCLUDE_DIR)/package.mk -include $(if $(DUMP),,$(STAGING_DIR)/mk/python-package.mk) +ifeq ($(CONFIG_TARGET_s3c24xx_openmoko-gta02-graphical),y) + CONFIG=om_gta02 +endif +ifeq ($(CONFIG_TARGET_s3c24xx_openmoko-gta02-minimal),y) + CONFIG=om_gta02 +endif + define Package/fso SECTION:=phone CATEGORY:=Phone TITLE:=freesmartphone.org DBus API reference implementation - DEPENDS:=python-core +dbus + DEPENDS:=python-core +dbus-python +python-gobject +pyserial +pyyaml +gst-python URL:=http://www.freesmartphone.org endef @@ -40,16 +47,18 @@ define Build/Compile endef define Package/fso/install - $(INSTALL_DIR) $(1)$(PYTHON_PKG_DIR) $(1)/usr/bin $(1)/etc + $(INSTALL_DIR) $(1)$(PYTHON_PKG_DIR) $(1)/usr/bin $(1)/etc/init.d $(CP) \ $(PKG_INSTALL_DIR)$(PYTHON_PKG_DIR)/* \ $(1)$(PYTHON_PKG_DIR) - $(CP) \ + $(INSTALL_BIN) \ $(PKG_INSTALL_DIR)/usr/bin/* \ $(1)/usr/bin/ + $(INSTALL_BIN) ./files/frameworkd.init $(1)/etc/init.d/frameworkd $(CP) \ $(PKG_INSTALL_DIR)/etc/* \ $(1)/etc/ + $(if $(CONFIG),$(INSTALL_CONF) ./files/frameworkd.conf.$(CONFIG) $(1)/etc/frameworkd.conf,$(CP) ./files/frameworkd.conf $(1)/etc/frameworkd.conf) endef $(eval $(call BuildPackage,fso)) diff --git a/phone/fso/files/frameworkd.conf b/phone/fso/files/frameworkd.conf new file mode 100644 index 000000000..e69de29bb diff --git a/phone/fso/files/frameworkd.conf.om_gta02 b/phone/fso/files/frameworkd.conf.om_gta02 new file mode 100644 index 000000000..ba62b896b --- /dev/null +++ b/phone/fso/files/frameworkd.conf.om_gta02 @@ -0,0 +1,102 @@ +[frameworkd] +# indicates this configuration version, do not change +version = 1 +# the default log_level, if not specified per module +log_level = INFO +# the global log_destination. Uncomment to enable +log_to = stderr +#log_to = file +#log_to = syslog +# if logging to a file, specify the destination +log_destination = /tmp/frameworkd.log +# persistance format, one of "pickle", "yaml" +persist_format = pickle +rootdir = ../etc/freesmartphone:/etc/freesmartphone:/usr/etc/freesmartphone + +[odeviced] +# set log level for a subsystem or for an individual module +# available log levels are: DEBUG, INFO, WARNING, ERROR, CRITICAL +log_level = INFO + +[odeviced.kernel26] +# set 1 to disable a module +disable = 0 +# poll capacity once every 5 minutes +# (usually, you do not have to change this) +capacity_check_timeout = 300 +# set 0 to disable FB_BLANK ioctl to blank framebuffer +# (if you have problems on Openmoko GTA02) +fb_blank = 1 + +[odeviced.audio] +# set directory where the alsa audio scenarios are stored +scenario_dir = /usr/share/openmoko/scenarios +# set default scenario loaded at startup +default_scenario = stereoout + +[odeviced.idlenotifier] +# add inut nodes to ignore for idle activity +ignoreinput = 2,3,4 +# configure timeouts (in seconds) here. A value of 0 +# means 'never fall into this state' (except programatically) +idle = 10 +idle_dim = 20 +idle_prelock = 12 +lock = 2 +suspend = 0 + +[odeviced.input] +# format is ,,, +report1 = AUX,key,169,1 +report2 = POWER,key,116,1 +report3 = CHARGER,key,356,0 +report4 = HEADSET,switch,2,0 + +[odeviced.powercontrol-neo] +disable = 0 + +[ogsmd] +disable = 0 +# chose your modem type, available types are: ti_calypso, freescale_neptune, singleline, muxed4line, option, ... +modemtype = ti_calypso +# if you have a ti_calypso, you can chose the deep sleep mode. Valid values are: never, adaptive (default), always +ti_calypso_deep_sleep = adaptive +# if you have a ti_calypso, you can choose the dsp mode for audio enhancement. Valid values are: +# "short-aec": Short Echo Cancellation (max) +# "long-aec": Long Echo Cancellation (max) +# "long-aec:6db": Long Echo Cancellation (-6db) +# "long-aec:12db": Long Echo Cancellation (-12db) +# "long-aec:18db": Long Echo Cancellation (-18db) +# "nr": Noise Reduction (max) +# "nr:6db": Noise Reduction (-6db) +# "nr:12db": Noise Reduction (-12db) +# "nr:18db": Noise Reduction (-18db) +# "aec+nr": Long Echo Cancellation (max) plus Noise Reduction (max) [default] +# "none": No audio processing. +ti_calypso_dsp_mode = aec+nr +log_level = INFO + +[ogpsd] +# possible options are NMEADevice, UBXDevice, GTA02Device, EtenDevice +device = GTA02Device +# possible options are SerialChannel, GllinChannel, UDPChannel, FileChannel +channel = SerialChannel +# For UDPChannel the path defines the port to listen to +path = /dev/ttySAC1 +log_level = INFO + +[opreferencesd] +log_level = DEBUG +disable = 0 +# log_level = DEBUG + +[oeventsd] +log_level = DEBUG +disbale = 0 + +[opimd] +contacts_default_backend = CSV-Contacts +messages_default_folder = Unfiled +messages_trash_folder = Trash +sim_messages_default_folder = SMS +rootdir = ../etc/freesmartphone/opim:/etc/freesmartphone/opim:/usr/etc/freesmartphone/opim diff --git a/phone/fso/files/frameworkd.init b/phone/fso/files/frameworkd.init new file mode 100644 index 000000000..28fb4d219 --- /dev/null +++ b/phone/fso/files/frameworkd.init @@ -0,0 +1,11 @@ +#!/bin/sh /etc/rc.common +# Copyright (C) 2008 OpenWrt.org +START=80 + +start() { + /usr/bin/frameworkd & +} + +stop() { + killall frameworkd +} diff --git a/phone/fso/patches/001-multilibc.patch b/phone/fso/patches/001-multilibc.patch new file mode 100644 index 000000000..03548d646 --- /dev/null +++ b/phone/fso/patches/001-multilibc.patch @@ -0,0 +1,56 @@ +diff -ruN fso-20090103.orig/framework/cxnet/common.py fso-20090103/framework/cxnet/common.py +--- fso-20090103.orig/framework/cxnet/common.py 2009-01-05 10:09:43.000000000 +0100 ++++ fso-20090103/framework/cxnet/common.py 2009-01-07 11:10:52.000000000 +0100 +@@ -38,7 +38,14 @@ + else: + cx_int = c_uint64 + +-libc = CDLL("libc.so.6") ++from os import listdir ++from re import compile ++re = compile('^libc.so.[0-9]$') ++libs = listdir('/lib') ++for lib in libs: ++ if re.match(lib): ++ libc = CDLL(lib) ++ break + + def hdump(name,msg,size=0): + """ +diff -ruN fso-20090103.orig/framework/patterns/kobject.py fso-20090103/framework/patterns/kobject.py +--- fso-20090103.orig/framework/patterns/kobject.py 2009-01-05 10:09:43.000000000 +0100 ++++ fso-20090103/framework/patterns/kobject.py 2009-01-07 13:37:58.000000000 +0100 +@@ -88,7 +88,13 @@ + self._watchR = gobject.io_add_watch( self._socketR.fileno(), gobject.IO_IN, self._onActivityR ) + + # for rtnetlink assistance +- self._libc = ctypes.CDLL( "libc.so.6" ) ++ from re import compile ++ re = compile('^libc.so.[0-9]$') ++ libs = os.listdir('/lib') ++ for lib in libs: ++ if re.match(lib): ++ self._libc = ctypes.CDLL(lib) ++ break + self._parser = RtNetlinkParser() + + def __del__( self ): +Binary files fso-20090103.orig/framework/patterns/.kobject.py.swp and fso-20090103/framework/patterns/.kobject.py.swp differ +diff -ruN fso-20090103.orig/framework/subsystems/odeviced/pyglet/linux.py fso-20090103/framework/subsystems/odeviced/pyglet/linux.py +--- fso-20090103.orig/framework/subsystems/odeviced/pyglet/linux.py 2009-01-05 10:09:43.000000000 +0100 ++++ fso-20090103/framework/subsystems/odeviced/pyglet/linux.py 2009-01-07 12:15:13.000000000 +0100 +@@ -15,7 +15,13 @@ + import struct + import sys + +-c = ctypes.cdll.LoadLibrary('libc.so.6') ++from re import compile ++re = compile('^libc.so.[0-9]$') ++libs = os.listdir('/lib') ++for lib in libs: ++ if re.match(lib): ++ c = ctypes.cdll.LoadLibrary(lib) ++ break + + _IOC_NRBITS = 8 + _IOC_TYPEBITS = 8 -- 2.30.2