Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
To: buildroot@busybox.net
Subject: [Buildroot] eaccelerator
Date: Thu, 20 Sep 2012 20:44:17 +0200	[thread overview]
Message-ID: <20120920204417.784829de@skate> (raw)
In-Reply-To: <CAE9DZUSLuiDgK0fPGoSE=bBQLinvDRKFLBq6ifzPxJwpMBD-zQ@mail.gmail.com>

Dear Dallas Clement,

You should send such contributions to the Buildroot list and not just
to me. Also, your contribution should be a proper Git patch, see
http://elinux.org/Buildroot_how_to_contribute.

On Thu, 20 Sep 2012 11:34:54 -0500, Dallas Clement wrote:
> #############################################################
> #
> # eaccelerator
> #
> #############################################################
> EACCELERATOR_VERSION = 0.9.6.1
> EACCELERATOR_SITE = http://eaccelerator.net/
> EACCELERATOR_SOURCE = eaccelerator-$(EACCELERATOR_VERSION).tar.bz2
> EACCELERATOR_UNZIP = bzcat

Line useless.

> EACCELERATOR_DEPENDENCIES = php
> EACCELERATOR_DIR = $(BUILD_DIR)/eaccelerator-$(EACCELERATOR_VERSION)

Line useless.

> EACCELERATOR_CONF_OPT = --prefix=/usr --enable-eaccelerator=shared \
>   --with-php-config=$(STAGING_DIR)/usr/bin/php-config

The --prefix=/usr is useless, this is already passed by default.

> STAGING_INCLUDE_DIR = $(STAGING_DIR)/usr/include
> EACCELERATOR_CONF_ENV = CPPFLAGS="$(TARGET_CFLAGS) -DMM_SEM_IPC
> -DMM_SHM_IPC -I$(STAGING_INCLUDE_DIR)/php
> -I$(STAGING_INCLUDE_DIR)/php/main -I$(STAGING_INCLUDE_DIR)/php/Zend
> -I$(STAGING_INCLUDE_DIR)/php/TSRM"

This big sequence of -I looks strange. Doesn't the configure script
figures those one out?

> EACCELERATOR_MAKE_ENV = INSTALL_ROOT="$(TARGET_DIR)"
> 
> EACCELERATOR_CONFFILES = /etc/php/cgi-php5/ext/eaccelerator.ini

Is this used somewhere?

> 
> define PHPIZE_HOOK
> 	cd $(EACCELERATOR_DIR) && phpize
> endef

The hook should have a name starting with EACCELERATOR, to avoid
clashing with other packages.

EACCELERATOR_DIR should be replaced by $(@D).

> define FIXUP_HOOK
> 	sed -i 's/mm_shm_mmap_anon=no/mm_shm_mmap_anon=yes\n
> mm_sem_pthread=yes/' $(EACCELERATOR_DIR)/config.m4
> endef

EACCELERATOR_DIR should be replaced by $(@D). A comment is needed to
explain what you are doing.

> EACCELERATOR_PRE_CONFIGURE_HOOKS += FIXUP_HOOK
> EACCELERATOR_PRE_CONFIGURE_HOOKS += PHPIZE_HOOK

Then you could probably do both things within a single hook.

> $(eval $(autotools-package))

There is a bit of rework to do, but it is good start. Keep posting
updated versions that take into account the comments!

Thanks,

Thomas
-- 
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com

  parent reply	other threads:[~2012-09-20 18:44 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-09-19 15:34 [Buildroot] eaccelerator Dallas Clement
2012-09-19 20:10 ` Thomas Petazzoni
2012-09-19 20:36   ` Dallas Clement
2012-09-20  9:10     ` Thomas Petazzoni
2012-09-20 16:37       ` Dallas Clement
     [not found]       ` <CAE9DZUSLuiDgK0fPGoSE=bBQLinvDRKFLBq6ifzPxJwpMBD-zQ@mail.gmail.com>
2012-09-20 18:44         ` Thomas Petazzoni [this message]
2012-09-20 23:02           ` Dallas Clement

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20120920204417.784829de@skate \
    --to=thomas.petazzoni@free-electrons.com \
    --cc=buildroot@busybox.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox