forums.ps2dev.org Forum Index forums.ps2dev.org
Homebrew PS2, PSP & PS3 Development Discussions
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Sudo make install pspsdk problem

 
Post new topic   Reply to topic    forums.ps2dev.org Forum Index -> PSP Development
View previous topic :: View next topic  
Author Message
someone
Idiot


Joined: 13 Sep 2005
Posts: 74

PostPosted: Sun Nov 22, 2009 11:47 am    Post subject: Sudo make install pspsdk problem Reply with quote

When I do sudo make install I get this output: (it's translated)

Making install in src
make[1]: enter to directory `/home/user/pspsdk/src'
Making install in asfparser
make[2]: enter to directory `/home/user/pspsdk/src/asfparser'
make[3]: enter to directory `/home/user/pspsdk/src/asfparser'
test -z "/usr/local/pspdev/psp/sdk/lib" || /bin/mkdir -p "/usr/local/pspdev/psp/sdk/lib"
/usr/bin/install -c -m 644 libpspasfparser.a '/usr/local/pspdev/psp/sdk/lib'
( cd '/usr/local/pspdev/psp/sdk/lib' && psp-ranlib libpspasfparser.a )
/bin/bash: line 5: psp-ranlib: command not found
make[3]: *** [install-libLIBRARIES] Error 127
make[3]: quit from directory `/home/user/pspsdk/src/asfparser'
make[2]: *** [install-am] Error 2
make[2]: quit from directory `/home/user/pspsdk/src/asfparser'
make[1]: *** [install-recursive] Error 1
make[1]: quit from directory `/home/user/pspsdk/src'
make: *** [install-recursive] Error 1
Back to top
View user's profile Send private message
m0skit0



Joined: 02 Jun 2009
Posts: 226

PostPosted: Sun Nov 22, 2009 1:50 pm    Post subject: Reply with quote

http://ps2dev.org/psp/Tools/Toolchain
_________________
The Incredible Bill Gates wrote:
The obvious mathematical breakthrough would be development of an easy way to factor large prime numbers.
Back to top
View user's profile Send private message
someone
Idiot


Joined: 13 Sep 2005
Posts: 74

PostPosted: Sun Nov 22, 2009 9:00 pm    Post subject: Reply with quote

Before installing pspsdk I installed psptoolchain without problems. I used the lasts svn versions of both.
Back to top
View user's profile Send private message
jojojoris



Joined: 30 Mar 2008
Posts: 261

PostPosted: Sun Nov 22, 2009 11:28 pm    Post subject: Reply with quote

First isntall the psptoolchain. If it runs without any probles you have the pspsdk.

Did you add the directories in your PATH?
_________________
Code:
int main(){
     SetupCallbacks();
     makeNiceGame();
     sceKernelExitGame();
}
Back to top
View user's profile Send private message
someone
Idiot


Joined: 13 Sep 2005
Posts: 74

PostPosted: Mon Nov 23, 2009 2:08 am    Post subject: Reply with quote

Yes
Back to top
View user's profile Send private message
jimparis



Joined: 10 Jun 2005
Posts: 1179
Location: Boston

PostPosted: Mon Nov 23, 2009 4:37 am    Post subject: Reply with quote

If you don't have the file "psp-ranlib" anywhere on your system, the toolchain was not built or installed properly. If you do have "psp-ranlib", then your PATH is not set up correctly to point to it.
Back to top
View user's profile Send private message
someone
Idiot


Joined: 13 Sep 2005
Posts: 74

PostPosted: Mon Nov 23, 2009 9:21 am    Post subject: Reply with quote

In ~/.bashrc at the end of file I have:

export PSPDEV="/usr/local/pspdev"
export PSPSDK="$PSPDEV/psp/sdk"
export PATH="$PATH:$PSPDEV/bin:$PSPSDK/bin"

psp-ranlib is in /usr/local/pspdev/bin and libpspasfparser.a in /usr/local/pspdev/psp/sdk/lib
Back to top
View user's profile Send private message
jsharrad



Joined: 20 Oct 2005
Posts: 102

PostPosted: Mon Nov 23, 2009 10:53 am    Post subject: Reply with quote

sudo doesn't keep your user environment variables though unless you tell it to
Back to top
View user's profile Send private message
jimparis



Joined: 10 Jun 2005
Posts: 1179
Location: Boston

PostPosted: Mon Nov 23, 2009 1:16 pm    Post subject: Reply with quote

Yeah, thanks for noticing that jsharrad. sudo will clear the PATH and other variables. Try something like:
Code:
sudo env "PATH=$PATH" make install
Back to top
View user's profile Send private message
ooPo
Site Admin


Joined: 17 Jan 2004
Posts: 2032
Location: Canada

PostPosted: Mon Nov 23, 2009 6:16 pm    Post subject: Reply with quote

Using 'sudo -E' will preserve environment variables.
Back to top
View user's profile Send private message Visit poster's website
someone
Idiot


Joined: 13 Sep 2005
Posts: 74

PostPosted: Tue Nov 24, 2009 12:21 am    Post subject: Reply with quote

With sudo env "PATH=$PATH" make install it worked please change it in the readme :)
Back to top
View user's profile Send private message
jimparis



Joined: 10 Jun 2005
Posts: 1179
Location: Boston

PostPosted: Tue Nov 24, 2009 2:20 am    Post subject: Reply with quote

ooPo wrote:
Using 'sudo -E' will preserve environment variables.
Ubuntu versions prior to Karmic were compiled with SECURE_PATH which overrides the PATH even with -E. On Karmic I think that's fixed, but /etc/sudoers still contains env_reset by default which disables -E. So it's not quite that easy -- the env trick is a more sure-fire way to get it through.
Back to top
View user's profile Send private message
ooPo
Site Admin


Joined: 17 Jan 2004
Posts: 2032
Location: Canada

PostPosted: Tue Nov 24, 2009 2:47 am    Post subject: Reply with quote

Ahh. I just did a quick test with $PS2DEV, but the path is the important part. :)
Back to top
View user's profile Send private message Visit poster's website
Mon Ouïe



Joined: 05 Jul 2009
Posts: 36

PostPosted: Tue Nov 24, 2009 3:11 am    Post subject: Reply with quote

You could also put your export in the /etc/profile.

According to man sudo, -E work even when there is an env_reset in sudoers :
Quote:
The -E (preserve environment) option will override the env_reset option in sudoers(5)). It is only available when either the matching command has the SETENV tag or the setenv option is set in sudoers(5)


Anyway, nothing forces you to use sudo instead of su.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    forums.ps2dev.org Forum Index -> PSP Development All times are GMT + 10 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group