[os x] pyrcc4 introuvable !

pyrcc4 introuvable ! [os x] - Python - Programmation

Marsh Posté le 08-01-2014 à 15:07:50    

Bonjour,
 
Je souhaite compiler un fichier avec pyrcc4.
Mais lorsque je tape la commande :

Citation :

pyrcc4 -o monFichier.py monFichier.qrc


 
J'ai l'erreur :  
 

Citation :

-bash: pyrcc4: command not found


 
Je suis sous mac avec Maverick.
Quelqu'un à déjà eu le problème ?

Reply

Marsh Posté le 08-01-2014 à 15:07:50   

Reply

Marsh Posté le 08-01-2014 à 22:31:34    

T'as pyqt d'installé? Parce-que ni Qt in PyQt ne sont livrés par défaut avec OSX hein :)


---------------
I mean, true, a cancer will probably destroy its host organism. But what about the cells whose mutations allow them to think outside the box, and replicate and expand beyond their wildest dreams by throwing away the limits imposed by overbearing genetic r
Reply

Marsh Posté le 09-01-2014 à 10:35:36    

Reply

Marsh Posté le 09-01-2014 à 12:19:39    

Et il est bien installé sur ton path?


---------------
I mean, true, a cancer will probably destroy its host organism. But what about the cells whose mutations allow them to think outside the box, and replicate and expand beyond their wildest dreams by throwing away the limits imposed by overbearing genetic r
Reply

Marsh Posté le 09-01-2014 à 13:40:02    

Je fais comment pour savoir ?

Reply

Marsh Posté le 09-01-2014 à 14:43:21    

essaie de faire un "sudo find / -name 'pyrcc*', s'il est trouvé il est bien installé, regardes dans quel répertoire il est et si ce répertoire est bien dans ton $PATH.


---------------
I mean, true, a cancer will probably destroy its host organism. But what about the cells whose mutations allow them to think outside the box, and replicate and expand beyond their wildest dreams by throwing away the limits imposed by overbearing genetic r
Reply

Marsh Posté le 09-01-2014 à 15:18:25    

Il est a priori bien installer puisqu'il trouve :

Citation :

/System/Library/Frameworks/Python.framework/Versions/2.7/bin/pyrcc5


 
Par contre, il n'est pas dans mon $PATH :

Citation :

/Library/Frameworks/Python.framework/Versions/3.3/bin:/opt/local/bin:/opt/local/sbin:/opt/local/bin:/opt/local/sbin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/opt/X11/bin


 
Comment je fais pour le rajouter ?


Message édité par monster-munch le 09-01-2014 à 15:19:02
Reply

Marsh Posté le 09-01-2014 à 15:47:35    

Notes que c'est pyrcc5 ça, pas 4 :o
 
Pour fixer ton path, t'as probablement un .profile ou un .bashrc où "/Library/Frameworks/Python.framework/Versions/3.3/bin" et "/opt/local/bin" sont ajouté au PATH (tu peux utiliser grep dans ton compte pour savoir où c'est fait), faut ajouter "/System/Library/Frameworks/Python.framework/Versions/2.7/bin/" à côté du reste.


---------------
I mean, true, a cancer will probably destroy its host organism. But what about the cells whose mutations allow them to think outside the box, and replicate and expand beyond their wildest dreams by throwing away the limits imposed by overbearing genetic r
Reply

Marsh Posté le 09-01-2014 à 16:45:49    

Hum je ne comprend pas  :o  
 
J'ai dans /etc/paths

Citation :

/usr/bin
/bin
/usr/sbin
/sbin
/usr/local/bin


 
Il faut que je rajoute  

Citation :

/System/Library/Frameworks/Python.framework/Versions/2.7/bin/

à la suite ?

Reply

Marsh Posté le 09-01-2014 à 18:31:51    

Non, /etc/paths c'est pour le système, faut pas y toucher. Normalement t'as un autre fichier dans ton home où le reste du path est rajouté (genre /opt/local/bin).


---------------
I mean, true, a cancer will probably destroy its host organism. But what about the cells whose mutations allow them to think outside the box, and replicate and expand beyond their wildest dreams by throwing away the limits imposed by overbearing genetic r
Reply

Marsh Posté le 09-01-2014 à 18:31:51   

Reply

Marsh Posté le 10-01-2014 à 00:31:36    

Ok. Je n'ai pas encore trouver le fichier mais je chercherai plus tard !
Donc j'avance dans ce que je veux faire en exécutant avec  

Citation :

/System/Library/Frameworks/Python.framework/Versions/2.7/bin/pyrcc5 -o toto.py toto.qrc  


 
Ensuite, je dois utiliser pyuic4.
J'ai fait une recherche avec  

Citation :

sudo find / -name 'pyuic*'


 
Ce qui me retourne

Citation :


/System/Library/Frameworks/Python.framework/Versions/2.7/bin/pyuic5
/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/PyQt5/uic/pyuic.py


 
Donc je fais la même chose sauf  

Citation :

/System/Library/Frameworks/Python.framework/Versions/2.7/bin/pyuic5 -o ui_toto.ui

me dit :

Citation :

No module named PyQt5.uic


 
Est-ce que j'aurai mal installé PyQt ?

Reply

Marsh Posté le 10-01-2014 à 10:13:28    

N'utilisant pas pyqt, je ne saurais te dire.


---------------
I mean, true, a cancer will probably destroy its host organism. But what about the cells whose mutations allow them to think outside the box, and replicate and expand beyond their wildest dreams by throwing away the limits imposed by overbearing genetic r
Reply

Marsh Posté le 10-01-2014 à 23:28:23    

Bon, j'ai passé la semaine à essayer d'installer pyuic, puis pyqt ; J'abandonne !
Je me suis monté une vm avec un bon ubuntu, et tout fonctionne en quelques minutes  :o  
Merci pour ton aide.

Reply

Sujets relatifs:

Leave a Replay

Make sure you enter the(*)required information where indicate.HTML code is not allowed