maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Development (https://talk.maemo.org/forumdisplay.php?f=13)
-   -   Prevent usage of scratchbox built-in tools (https://talk.maemo.org/showthread.php?t=85953)

marmistrz 2012-08-08 14:20

Prevent usage of scratchbox built-in tools
 
Hi,
I compiled autoconf 2.67. Unfortunately, still the scratchbox built-in version is called
Code:

[sbox-FREMANTLE_ARMEL: ~/libtool/autoconf-2.67] > SBOX_REDIRECT_IGNORE=/usr/bin/autoconf autoconf --version
autoconf (GNU Autoconf) 2.61
Copyright (C) 2006 Free Software Foundation, Inc.
This is free software.  You may redistribute copies of it under the terms of
the GNU General Public License <http://www.gnu.org/licenses/gpl.html>.
There is NO WARRANTY, to the extent permitted by law.

Written by David J. MacKenzie and Akim Demaille.
[sbox-FREMANTLE_ARMEL: ~/libtool/autoconf-2.67] > autoconf --version
autoconf (GNU Autoconf) 2.61
Copyright (C) 2006 Free Software Foundation, Inc.
This is free software.  You may redistribute copies of it under the terms of
the GNU General Public License <http://www.gnu.org/licenses/gpl.html>.
There is NO WARRANTY, to the extent permitted by law.

Written by David J. MacKenzie and Akim Demaille.
[sbox-FREMANTLE_ARMEL: ~/libtool/autoconf-2.67] > SBOX_REDIRECT_IGNORE=/usr/bin/autoconf autoconf --version
autoconf (GNU Autoconf) 2.61
Copyright (C) 2006 Free Software Foundation, Inc.
This is free software.  You may redistribute copies of it under the terms of
the GNU General Public License <http://www.gnu.org/licenses/gpl.html>.
There is NO WARRANTY, to the extent permitted by law.

Written by David J. MacKenzie and Akim Demaille.
[sbox-FREMANTLE_ARMEL: ~/libtool/autoconf-2.67] > SBOX_REDIRECT_IGNORE=/usr/bin/autoconf /usr/bin/autoconf --version
autoconf (GNU Autoconf) 2.67
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+/Autoconf: GNU GPL version 3 or later
<http://gnu.org/licenses/gpl.html>, <http://gnu.org/licenses/exceptions.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

Written by David J. MacKenzie and Akim Demaille.
[sbox-FREMANTLE_ARMEL: ~/libtool/autoconf-2.67] >

The third call works, but this can't be really used as in many packages it's just
Code:

autoconf
called.

How can I disable the scratchbox autoconf and use the newer one only?

rash.m2k 2012-08-09 14:22

Re: Prevent usage of scratchbox built-in tools
 
rename the old autotools to something else?

marmistrz 2012-08-09 14:24

Re: Prevent usage of scratchbox built-in tools
 
Quote:

Originally Posted by rash.m2k (Post 1249548)
rename the old autotools to something else?

I can't as this should work on the autobuilder. Is there any way to disable redirection when using the non-absolute path?

gregoranderson 2012-08-09 15:19

Re: Prevent usage of scratchbox built-in tools
 
Just a quick guess, but try alias?

Code:

alias autoconf='path/to/autoconf'
Replace path to autoconf with the full path to your autoconf.

To unalias (return to the shell built-in), just do the following:

Code:

unalias autoconf

marmistrz 2012-08-09 18:20

Re: Prevent usage of scratchbox built-in tools
 
Quote:

Originally Posted by gregoranderson (Post 1249572)
Just a quick guess, but try alias?

Code:

alias autoconf='path/to/autoconf'
Replace path to autoconf with the full path to your autoconf.

To unalias (return to the shell built-in), just do the following:

Code:

unalias autoconf

It worked, thanks!

marmistrz 2012-08-10 08:35

Re: Prevent usage of scratchbox built-in tools
 
Quote:

Originally Posted by gregoranderson (Post 1249572)
Just a quick guess, but try alias?

Code:

alias autoconf='path/to/autoconf'
Replace path to autoconf with the full path to your autoconf.

To unalias (return to the shell built-in), just do the following:

Code:

unalias autoconf

Unfortunately, the aliases aren't taken in account in makefile (so in debian/rules too.) Is there any way to specify the path for Makefiles (debian/rules)?

gregoranderson 2012-08-10 08:47

Re: Prevent usage of scratchbox built-in tools
 
Quote:

Originally Posted by marmistrz (Post 1249986)
Unfortunately, the aliases aren't taken in account in makefile (so in debian/rules too.) Is there any way to specify the path for Makefiles (debian/rules)?

It was a stab in the dark :)

How about ...

Code:

SBOX_REDIRECT_BINARIES
        comma-separated list of <source>:<target> pairs which specify
        explicit binary redirection rules (for example
        "/usr/bin/make:/scratchbox/tools/bin/make,/bin/cat:/host_usr/bin/dog")


marmistrz 2012-08-10 09:22

Re: Prevent usage of scratchbox built-in tools
 
I did this
Code:

PATH:=/usr/bin/dh7:/usr/bin:$(PATH)
export PATH
SBOX_REDIRECT_IGNORE=/usr/bin/perl:/usr/bin/autoconf
export SBOX_REDIRECT_IGNORE
SBOX_REDIRECT_BINARIES:="/usr/bin/autoconf:/usr/bin/autoconf,$(SBOX_REDIRECT_BINARIES)"

but still the redirected version is used. Any other way?

rainisto 2012-08-13 08:25

Re: Prevent usage of scratchbox built-in tools
 
chroot into toolchain dir and install new autoconf in there.

marmistrz 2012-08-13 11:15

Re: Prevent usage of scratchbox built-in tools
 
Quote:

Originally Posted by rainisto (Post 1251236)
chroot into toolchain dir and install new autoconf in there.

I finally found out a solution:
http://talk.maemo.org/showthread.php...85#post1250985
and
http://harmattan-dev.nokia.com/docs/...tform_SDK.html


All times are GMT. The time now is 19:14.

vBulletin® Version 3.8.8