On Fri, Jun 24, 2011 at 12:19:34PM +0100, Christian Gagneraud wrote:
> Open Source Telephony. http://ofono.org
> 
> Signed-off-by: Christian Gagneraud <[email protected]>
> ---
>  rules/ofono.in   |   76 +++++++++++++++++++++++++++++++++++++++
>  rules/ofono.make |  103 
> ++++++++++++++++++++++++++++++++++++++++++++++++++++++
>  2 files changed, 179 insertions(+), 0 deletions(-)
>  create mode 100644 rules/ofono.in
>  create mode 100644 rules/ofono.make
> 
> diff --git a/rules/ofono.in b/rules/ofono.in
> new file mode 100644
> index 0000000..dc8551b
> --- /dev/null
> +++ b/rules/ofono.in
> @@ -0,0 +1,76 @@
> +## SECTION=networking
> +
> +menuconfig OFONO
> +     select BLUEZ if OFONO_BT_MODEM
> +     select UDEV if OFONO_UDEV

align the ifs with <tab>

> +     select MOBILE_BB_INFO
> +     tristate
> +     prompt "ofono                         "
> +     help
> +       oFono is a stack for mobile telephony devices on
> +       Linux. oFono supports speaking to telephony devices through
> +       specific drivers, or with generic AT commands.
> +
> +       oFono also includes a low-level plug-in API for integrating
> +       with other telephony stacks, cellular modems and storage
> +       back-ends. The plug-in API functionality is modeled on
> +       public standards, in particular 3GPP TS 27.007 "AT command
> +       set for User Equipment (UE)."
> +
> +       This package includes the core daemon.
> +
> +       http://ofono.org
> +
> +if OFONO
> +
> +config OFONO_UDEV
> +       bool
> +       prompt "Enable udev"
> +       default n

'n' is the default. Remove. All others too.

> +       help
> +         Enable udev integration
> +
> +config OFONO_TOOLS
> +       bool
> +       prompt "Install testing tools"
> +       default n
> +       help
> +         Install ofono testing tools
> +
> +config OFONO_AT_MODEM
> +       bool
> +       prompt "Support for AT modem"
> +       default n
> +       help
> +         Enable udev
> +
> +config OFONO_CDMA_MODEM
> +       bool
> +       prompt "Support for CDMA modem"
> +       default n
> +
> +config OFONO_PHONE_SIMU
> +       bool
> +       prompt "Support for phone simulator"
> +       default n
> +
> +config OFONO_ISI_MODEM
> +       bool
> +       prompt "Support for Phonet/ISI modem"
> +       default n
> +
> +config OFONO_BT_MODEM
> +       bool
> +       prompt "Support for bluetooth modem"
> +       default y
> +
> +config OFONO_INITSCRIPT
> +       bool
> +       prompt "Install /etc/init.d/ofono"
> +
> +config OFONO_SYSTEMD
> +       bool
> +       depends on SYSTEMD
> +       prompt "Install systemd unit files"
> +
> +endif
> diff --git a/rules/ofono.make b/rules/ofono.make
> new file mode 100644
> index 0000000..28d765d
> --- /dev/null
> +++ b/rules/ofono.make
> @@ -0,0 +1,103 @@
> +# -*-makefile-*-
> +#
> +# Copyright (C) 2009 by Christian Gagneraud <[email protected]>
> +#
> +# See CREDITS for details about who has contributed to this project.
> +#
> +# For further information about the PTXdist project and license conditions
> +# see the README file.
> +#
> +
> +#
> +# We provide this package
> +#
> +PACKAGES-$(PTXCONF_OFONO) += ofono
> +
> +#
> +# Paths and names
> +#
> +OFONO_NAME   := ofono
> +OFONO_VERSION        := 0.50
> +OFONO_MD5    := cd6e4f66809e7b2bc9e1d5c996cbfabd
> +OFONO                := $(OFONO_NAME)-$(OFONO_VERSION)
> +OFONO_SUFFIX := tar.gz
> +OFONO_URL    := 
> http://www.kernel.org/pub/linux/network/ofono/$(OFONO).$(OFONO_SUFFIX)
> +OFONO_SOURCE := $(SRCDIR)/$(OFONO).$(OFONO_SUFFIX)
> +OFONO_DIR    := $(BUILDDIR)/$(OFONO)
> +OFONO_LICENSE        := BSD
> +
> +# 
> ----------------------------------------------------------------------------
> +# Prepare
> +# 
> ----------------------------------------------------------------------------
> +
> +ifndef PTXCONF_OFONO_UDEV
> +OFONO_ENABLE_AT_MODEM = --disable-udev
> +endif
> +ifdef PTXCONF_OFONO_TOOLS
> +OFONO_ENABLE_AT_MODEM = --enable-tools
> +endif
> +ifndef PTXCONF_OFONO_AT_MODEM
> +OFONO_ENABLE_AT_MODEM = --disable-atmodem
> +endif
> +ifndef PTXCONF_OFONO_CDMA_MODEM
> +OFONO_ENABLE_AT_MODEM = --disable-cdmamodem
> +endif
> +ifndef PTXCONF_OFONO_PHONE_SIMU
> +OFONO_ENABLE_AT_MODEM = --disable-phonesim
> +endif
> +ifndef PTXCONF_OFONO_ISI_MODEM
> +OFONO_ENABLE_AT_MODEM = --disable-isimodem
> +endif
> +ifndef PTXCONF_OFONO_BT_MODEM
> +OFONO_ENABLE_AT_MODEM = --disable-bluetooth
> +endif

You're changing OFONO_ENABLE_AT_MODEM every time, this looks wrong.

> +
> +OFONO_CONF_TOOL      := autoconf
> +OFONO_CONF_OPT +=                            \
> +     $(CROSS_AUTOCONF_USR)                   \
        --$(call ptx/endis, PTXCONF_OFONO_UDEV)-udev

for all options. Unless the configure script is broken and does not accept
--enable-<option>?

> +     $(OFONO_ENABLE_UDEV)                    \
> +     $(OFONO_ENABLE_TOOLS)                   \
> +     $(OFONO_ENABLE_AT_MODEM)                \
> +     $(OFONO_ENABLE_CDMA_MODEM)              \
> +     $(OFONO_ENABLE_SIME_MODEM)              \
> +     $(OFONO_ENABLE_ISI_MODEM)               \
> +     $(OFONO_ENABLE_BT_MODEM)
> +
> +# 
> ----------------------------------------------------------------------------
> +# Install
> +# 
> ----------------------------------------------------------------------------
> +
> +$(STATEDIR)/ofono.install:
> +     @$(call targetinfo)
> +     @$(call world/install, OFONO)
> +     @$(call touch)

remove.

> +
> +# 
> ----------------------------------------------------------------------------
> +# Target-Install
> +# 
> ----------------------------------------------------------------------------
> +
> +$(STATEDIR)/ofono.targetinstall:
> +     @$(call targetinfo)
> +
> +     @$(call install_init,  ofono)
> +
> +     @$(call install_fixup, ofono,PRIORITY,optional)
> +     @$(call install_fixup, ofono,SECTION,base)
> +     @$(call install_fixup, ofono,AUTHOR,"Christian Gagneraud 
> <[email protected]>")
> +     @$(call install_fixup, ofono,DESCRIPTION,Ofono deamon)
> +
> +     @$(call install_copy, ofono, 0, 0, 0755, -, /usr/sbin/ofonod)
> +     @$(call install_copy, ofono, 0, 0, 0755, -, 
> /lib/udev/rules.d/97-ofono.rules)

0644

> +#    FIXME: sysinit script?
> +ifdef OFONO_SYSTEMD
> +     @$(call install_copy, ofono, 0, 0, 0755, -, 
> /etc/dbus-1/system.d/ofono.conf)

This should be useful without systemd.

> +     @$(call install_copy, ofono, 0, 0, 0755, -, 
> /lib/systemd/system/ofono.service)

0644

> +endif
> +ifdef OFONO_PHONE_SIMU
> +     @$(call install_copy, ofono, 0, 0, 0755, -, /etc/ofono/phonesim.conf)

0644

Michael

> +endif
> +
> +     @$(call install_finish, ofono)
> +
> +     @$(call touch)
> +
> -- 
> 1.7.4.1
> 
> 
> -- 
> ptxdist mailing list
> [email protected]
> 

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

-- 
ptxdist mailing list
[email protected]

Reply via email to