2011-09-04 8 views
0

완전히 새로운 Symfony 1.4 프로젝트를 설정하고 스키마를 설계했지만 불행히도 스키마를 빌드 할 수 없습니다.PHP Symfony Build All Propel Fails - MySQL

symfony 명령에 약간의 문제가 있습니다. php symfony propel:build --all --no-confirmation.

불행히도 그것은 다소 이상한 오류 메시지를 남깁니다 php symfony propel:build --all --no-confirmation이 오류의 원인과 해결 방법을 아는 사람이 있습니까? Google은 이해할 수없는 일부 폴란드어 웹 사이트를 번역합니다.

감사합니다.

전체 오류 :

>> schema putting /Applications/XAMPP/xamppfiles/htdocs/swingers/config/generated-schema.xml 
>> propel Running "insert-sql" phing task 
Execution of target "insert-sql" failed for the following reason: /Applications/XAMPP/xamppfiles/htdocs/swingers/lib/vendor/symfony/lib/plugins/sfPropelPlugin/lib/vendor/propel-generator/build-propel.xml:272:1: [wrapped: SQLSTATE[HY000] [2002] No such file or directory] 
    [phing] /Applications/XAMPP/xamppfiles/htdocs/swingers/lib/vendor/symfony/lib/plugins/sfPropelPlugin/lib/vendor/propel-generator/build-propel.xml:272:1: [wrapped: SQLSTATE[HY000] [2002] No such file or directory] 

    Some problems occurred when executing the task:          

    build-propel.xml:272:1: [wrapped: SQLSTATE[HY000] [2002] No such file or directory] 

    If the exception message is not clear enough, read the output of the task for   
    more information                  

>> file-  /Applications/XAMPP/xamppfiles/htdocs/swingers/config/generated-schema.xml 
PezCuckowMBP:swingers pezcuckow$ 

답변

2

젠장, 내가 좀 더 생각 후에 내 자신의 질문에 대답했습니다

것은 내가 OSX 10.6 XAMPP를 사용하고 있습니다. 문제는 잘못된 PHP 바이너리를 실행하고 있다는 것입니다.

$ php symfony propel:insert-sql 

내가 처음

명령 $ PHP는 잘못된 PHP (OSX의 기본 PHP)를 실행에 원한 인

/Applications/xampp/xamppfiles/bin/에서 안 하나 /usr/bin/에서 PHP 바이너리를 부를 것이다 .

이 문제를 I를 해결하려면

/usr/bin에 가서 그런

php to php_old 
phpize to phpize_old 
php-config to php-config_old 

의 이름을 변경, 심볼릭 링크 만들기 :이 다른 붙어 사람에게 소용이

sudo ln -s /Applications/XAMPP/xamppfiles/bin/php-config php-config 
sudo ln -s /Applications/XAMPP/xamppfiles/bin/php php 
sudo ln -s /Applications/XAMPP/xamppfiles/bin/phpize phpize 

희망을!

관련 문제