On 11/04/2010 05:41 PM, George McCollister wrote:
> I added a new packet memcached.
> Signed-off-by: George McCollister <[email protected]>
> ---
>  patches/memcached-1.4.4/configure.diff |  102 +++++++++++++++++++++++

please don't change configure unless for a very good reason.
Better fix the problem in the configure.{in,ac} and call autoreconf.

See more comments inline. Please remove all obsolete stages. Same goes
for the other makefiles.

Please fix and resend,

cheers, Marc

>  patches/memcached-1.4.4/series         |    1 +
>  rules/memcached.in                     |   11 +++
>  rules/memcached.make                   |  143 
> ++++++++++++++++++++++++++++++++
>  4 files changed, 257 insertions(+), 0 deletions(-)
>  create mode 100644 patches/memcached-1.4.4/configure.diff
>  create mode 100644 patches/memcached-1.4.4/series
>  create mode 100644 rules/memcached.in
>  create mode 100644 rules/memcached.make
> 
> diff --git a/patches/memcached-1.4.4/configure.diff 
> b/patches/memcached-1.4.4/configure.diff
> new file mode 100644
> index 0000000..90f18f3
> --- /dev/null
> +++ b/patches/memcached-1.4.4/configure.diff
> @@ -0,0 +1,102 @@
> +diff -Naur memcached-1.4.4/configure memcached-1.4.4.new/configure
> +--- memcached-1.4.4/configure        2009-11-27 00:34:57.000000000 -0600
> ++++ memcached-1.4.4.new/configure    2010-01-27 10:04:03.000000000 -0600
> +@@ -4007,83 +4007,6 @@
> + 
> + 
> +     SUNCC="no"
> +-    { $as_echo "$as_me:$LINENO: checking for Sun cc in use" >&5
> +-$as_echo_n "checking for Sun cc in use... " >&6; }
> +-    if test "$cross_compiling" = yes; then
> +-  { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
> +-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
> +-{ { $as_echo "$as_me:$LINENO: error: cannot run test program while cross 
> compiling
> +-See \`config.log' for more details." >&5
> +-$as_echo "$as_me: error: cannot run test program while cross compiling
> +-See \`config.log' for more details." >&2;}
> +-   { (exit 1); exit 1; }; }; }
> +-else
> +-  cat >conftest.$ac_ext <<_ACEOF
> +-/* confdefs.h.  */
> +-_ACEOF
> +-cat confdefs.h >>conftest.$ac_ext
> +-cat >>conftest.$ac_ext <<_ACEOF
> +-/* end confdefs.h.  */
> +-
> +-int
> +-main ()
> +-{
> +-#ifdef __SUNPRO_C
> +-   return 0;
> +-#else
> +-   return 1;
> +-#endif
> +-
> +-  ;
> +-  return 0;
> +-}
> +-
> +-_ACEOF
> +-rm -f conftest$ac_exeext
> +-if { (ac_try="$ac_link"
> +-case "(($ac_try" in
> +-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
> +-  *) ac_try_echo=$ac_try;;
> +-esac
> +-eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
> +-$as_echo "$ac_try_echo") >&5
> +-  (eval "$ac_link") 2>&5
> +-  ac_status=$?
> +-  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
> +-  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
> +-  { (case "(($ac_try" in
> +-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
> +-  *) ac_try_echo=$ac_try;;
> +-esac
> +-eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
> +-$as_echo "$ac_try_echo") >&5
> +-  (eval "$ac_try") 2>&5
> +-  ac_status=$?
> +-  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
> +-  (exit $ac_status); }; }; then
> +-
> +-       { $as_echo "$as_me:$LINENO: result: yes" >&5
> +-$as_echo "yes" >&6; }
> +-       CFLAGS="-mt $CFLAGS"
> +-       SUNCC="yes"
> +-
> +-else
> +-  $as_echo "$as_me: program exited with status $ac_status" >&5
> +-$as_echo "$as_me: failed program was:" >&5
> +-sed 's/^/| /' conftest.$ac_ext >&5
> +-
> +-( exit $ac_status )
> +-
> +-       { $as_echo "$as_me:$LINENO: result: no" >&5
> +-$as_echo "no" >&6; }
> +-
> +-
> +-fi
> +-rm -rf conftest.dSYM
> +-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext 
> conftest.$ac_objext conftest.$ac_ext
> +-fi
> +-
> +-
> + 
> + 
> + if test "$ICC" = "no"; then
> +@@ -6626,13 +6549,7 @@
> + $as_echo_n "checking for htonll... " >&6; }
> +     have_htoll="no"
> +     if test "$cross_compiling" = yes; then
> +-  { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
> +-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
> +-{ { $as_echo "$as_me:$LINENO: error: cannot run test program while cross 
> compiling
> +-See \`config.log' for more details." >&5
> +-$as_echo "$as_me: error: cannot run test program while cross compiling
> +-See \`config.log' for more details." >&2;}
> +-   { (exit 1); exit 1; }; }; }
> ++    have_htoll="no"
> + else
> +   cat >conftest.$ac_ext <<_ACEOF
> + 
> diff --git a/patches/memcached-1.4.4/series b/patches/memcached-1.4.4/series
> new file mode 100644
> index 0000000..dbd8a0a
> --- /dev/null
> +++ b/patches/memcached-1.4.4/series
> @@ -0,0 +1 @@
> +configure.diff
> diff --git a/rules/memcached.in b/rules/memcached.in
> new file mode 100644
> index 0000000..fba71c6
> --- /dev/null
> +++ b/rules/memcached.in
> @@ -0,0 +1,11 @@
> +## SECTION=networking
> +
> +config MEMCACHED
> +     tristate
> +     select LIBEVENT
> +     prompt "memcached"
> +     help
> +       Memcached is an in-memory key-value store for small chunks of
> +       arbitrary data (strings, objects) from results of database calls,
> +       API calls, or page rendering.
> +
> diff --git a/rules/memcached.make b/rules/memcached.make
> new file mode 100644
> index 0000000..59f078f
> --- /dev/null
> +++ b/rules/memcached.make
> @@ -0,0 +1,143 @@
> +# -*-makefile-*-
> +# $Id$
     ^^^^
please remove

> +#
> +# Copyright (C) 2009 by NovaTech-LLC
> +#
> +# 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_MEMCACHED) += memcached
> +
> +#
> +# Paths and names
> +#
> +MEMCACHED_VERSION            := 1.4.4
> +MEMCACHED                    := memcached-$(MEMCACHED_VERSION)
> +MEMCACHED_SUFFIX             := tar.gz
> +MEMCACHED_URL                        := 
> http://memcached.googlecode.com/files/$(MEMCACHED).$(MEMCACHED_SUFFIX)
> +MEMCACHED_SOURCE             := $(SRCDIR)/$(MEMCACHED).$(MEMCACHED_SUFFIX)
> +MEMCACHED_DIR                := $(BUILDDIR)/$(MEMCACHED)
> +MEMCACHED_DEP                := libevent
> +
> +# 
> ----------------------------------------------------------------------------
> +# Get
> +# 
> ----------------------------------------------------------------------------
> +
> +memcached_get: $(STATEDIR)/memcached.get
> +
> +$(STATEDIR)/memcached.get: $(memcached_get_deps_default)
> +     @$(call targetinfo, $@)
> +     @$(call touch, $@)
> +
> +$(MEMCACHED_SOURCE):
> +     @$(call targetinfo, $@)
> +     @$(call get, MEMCACHED)

please remove the complete get stage, it's obsolste
> +
> +# 
> ----------------------------------------------------------------------------
> +# Extract
> +# 
> ----------------------------------------------------------------------------
> +
> +memcached_extract: $(STATEDIR)/memcached.extract
> +
> +$(STATEDIR)/memcached.extract: $(memcached_extract_deps_default)
> +     @$(call targetinfo, $@)
> +     @$(call clean, $(MEMCACHED_DIR))
> +     @$(call extract, MEMCACHED)
> +     @$(call patchin, MEMCACHED)
> +     @$(call touch, $@)

idem for the extract stage

> +
> +# 
> ----------------------------------------------------------------------------
> +# Prepare
> +# 
> ----------------------------------------------------------------------------
> +
> +memcached_prepare: $(STATEDIR)/memcached.prepare
> +
> +MEMCACHED_PATH       := PATH=$(CROSS_PATH)
> +MEMCACHED_ENV        := $(CROSS_ENV)

same goes for these three.
> +
> +MEMCACHED_ENV        += LDFLAGS+='-L$(SYSROOT)/lib 
> -Wl,-rpath-link,$(SYSROOT)/lib -L$(SYSROOT)/usr/lib 
> -Wl,-rpath-link,$(SYSROOT)/usr/lib'
> +
> +ifdef PTXCONF_ENDIAN_LITTLE
> +     MEMCACHED_ENV += ac_cv_c_endian=little
> +else
> +     MEMCACHED_ENV += ac_cv_c_endian=big
> +endif
> +MEMCACHED_ENV += ac_cv_c_alignment=need
> +
> +#
> +# autoconf
> +#
> +MEMCACHED_AUTOCONF := $(CROSS_AUTOCONF_USR)
> +
> +$(STATEDIR)/memcached.prepare: $(memcached_prepare_deps_default)
> +     @$(call targetinfo, $@)
> +     @$(call clean, $(MEMCACHED_DIR)/config.cache)
> +     cd $(MEMCACHED_DIR) && \
> +             $(MEMCACHED_PATH) $(MEMCACHED_ENV) \
> +             ./configure $(MEMCACHED_AUTOCONF)
> +     @$(call touch, $@)

prepare can go away, too.
> +
> +# 
> ----------------------------------------------------------------------------
> +# Compile
> +# 
> ----------------------------------------------------------------------------
> +
> +memcached_compile: $(STATEDIR)/memcached.compile
> +
> +$(STATEDIR)/memcached.compile: $(memcached_compile_deps_default)
> +     @$(call targetinfo, $@)
> +     cd $(MEMCACHED_DIR) && $(MEMCACHED_ENV) $(MEMCACHED_PATH) make
> +     @$(call touch, $@)

compile, too

> +# 
> ----------------------------------------------------------------------------
> +# Install
> +# 
> ----------------------------------------------------------------------------
> +
> +memcached_install: $(STATEDIR)/memcached.install
> +
> +$(STATEDIR)/memcached.install: $(memcached_install_deps_default)
> +     @$(call targetinfo, $@)
> +     @$(call install, MEMCACHED)
> +     @$(call touch, $@)

idem

> +
> +# 
> ----------------------------------------------------------------------------
> +# Target-Install
> +# 
> ----------------------------------------------------------------------------
> +
> +memcached_targetinstall: $(STATEDIR)/memcached.targetinstall

this one, too
> +
> +$(STATEDIR)/memcached.targetinstall: $(memcached_targetinstall_deps_default)
                                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
the _deps_default, too

> +     @$(call targetinfo, $@)
> +
> +     @$(call install_init, memcached)
> +     @$(call install_fixup,memcached,PACKAGE,memcached)
> +     @$(call install_fixup,memcached,PRIORITY,optional)
> +     @$(call install_fixup,memcached,VERSION,$(MEMCACHED_VERSION))
> +     @$(call install_fixup,memcached,SECTION,base)
> +     @$(call install_fixup,memcached,AUTHOR,"NovaTech-LLC")
> +     @$(call install_fixup,memcached,DEPENDS,"$(MEMCACHED_DEP)")
> +     @$(call install_fixup,memcached,DESCRIPTION,missing)
> +
> +     @$(call install_copy, memcached, 0, 0, 0755, 
> $(MEMCACHED_DIR)/memcached, /usr/bin/memcached, y)
                                                     ^^^^^^^^^^^^^^^^^^^^^^^^^^
please use a "-" here and remove, the "y"
 
> +     @$(call install_copy, memcached, 0, 0, 0700, /var/run/memcached)
> +
> +     @$(call install_finish,memcached)
> +
> +     @$(call touch, $@)

please remove the ", $@"
> +
> +# 
> ----------------------------------------------------------------------------
> +# Clean
> +# 
> ----------------------------------------------------------------------------
> +
> +memcached_clean:
> +     rm -rf $(STATEDIR)/memcached.*
> +     rm -rf $(IMAGEDIR)/memcached.*
> +     rm -rf $(MEMCACHED_DIR)
> +     rm -rf $(SYSROOT)/usr/lib/libmemcached*

please remove the clean stage
> +
> +# vim: syntax=make


-- 
Pengutronix e.K.                  | Marc Kleine-Budde           |
Industrial Linux Solutions        | Phone: +49-231-2826-924     |
Vertretung West/Dortmund          | Fax:   +49-5121-206917-5555 |
Amtsgericht Hildesheim, HRA 2686  | http://www.pengutronix.de   |

Attachment: signature.asc
Description: OpenPGP digital signature

-- 
ptxdist mailing list
[email protected]

Reply via email to