Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Gustavo Zacarias <gustavo@zacarias.com.ar>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH] net-snmp: fixup paths in net-snmp-config
Date: Mon, 02 May 2011 16:05:38 -0300	[thread overview]
Message-ID: <4DBF0082.6070200@zacarias.com.ar> (raw)
In-Reply-To: <201105021502.45233.vapier@gentoo.org>

On 05/02/11 16:02, Mike Frysinger wrote:

> On Monday, May 02, 2011 11:36:05 Gustavo Zacarias wrote:
>> Exposed by commit 7e3e8ec040b06d6e2fb69e55c004f1ebc02c76d0
>> net-snmp-config goes for -L/usr/lib thus things break since this wins
>> over the sysroot if we have a host net-snmp library around when we build
>> packages that link against net-snmp.
>>
>> --- a/package/netsnmp/netsnmp.mk
>> +++ b/package/netsnmp/netsnmp.mk
>> @@ -68,4 +68,14 @@ define NETSNMP_UNINSTALL_TARGET_CMDS
>>  	rm -f $(TARGET_DIR)/usr/lib/libnetsnmp*
>>  endef
>>
>> +define NETSNMP_STAGING_NETSNMP_CONFIG_FIXUP
>> +	$(SED) "s,^prefix=.*,prefix=\'$(STAGING_DIR)/usr\',g" \
>> +		-e "s,^exec_prefix=.*,exec_prefix=\'$(STAGING_DIR)/usr\',g" \
>> +		-e "s,^includedir=.*,includedir=\'$(STAGING_DIR)/usr/include\',g" \
>> +		-e "s,^libdir=.*,libdir=\'$(STAGING_DIR)/usr/lib\',g" \
>> +		$(STAGING_DIR)/usr/bin/net-snmp-config
>> +endef
> 
> this should really be a common bit of logic instead of net-snmp specific.  
> just about every -config script can be fixed in this way.
> -mike

Agreed, into package infrastructure, something like:

NETSNMP_CONFIG_FILE = net-snmp-config

or some wiser variable name to trigger the necessary fixup in the
appropiate file(s).
Regards.

      reply	other threads:[~2011-05-02 19:05 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-05-02 15:36 [Buildroot] [PATCH] net-snmp: fixup paths in net-snmp-config Gustavo Zacarias
2011-05-02 15:45 ` Peter Korsgaard
2011-05-02 19:02 ` Mike Frysinger
2011-05-02 19:05   ` Gustavo Zacarias [this message]

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=4DBF0082.6070200@zacarias.com.ar \
    --to=gustavo@zacarias.com.ar \
    --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