I got a simple application I want to run on my iphone. However I get a annoying error the provisioning profile can not be found. It happens after I go to my project folder and run:
sudo rake device:iphone:production
=== BUILD NATIVE TARGET RhoLib OF PROJECT RhoLib WITH CONFIGURATION Release ===
Check dependencies
=== BUILD NATIVE TARGET rhoextlib OF PROJECT rhoextlib WITH CONFIGURATION Release ===
Check dependencies
=== BUILD NATIVE TARGET curl OF PROJECT curl WITH CONFIGURATION Release ===
Check dependencies
=== BUILD NATIVE TARGET rhorunner OF PROJECT rhorunner WITH CONFIGURATION Release ===
Check dependencies
Code Sign error: Provisioning profile '0558F1B2-FE5A-4236-B9EE-A200EFAD68E9' can't be found
cd ~/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/gems/1.9.1/gems/rhodes-3.3.3
set bundle identifier
set URL name
restore_default_images
rm -f platform/iphone/Default.png
rm -f platform/iphone/Default.png
cp platform/iphone/Default.bak platform/iphone/Default.png
rm -f platform/iphone/Default.bak
rm -f platform/iphone/[email protected]
rm -f platform/iphone/Default-Portrait.png
rm -f platform/iphone/Default-PortraitUpsideDown.png
rm -f platform/iphone/Default-Landscape.png
rm -f platform/iphone/Default-LadscapeLeft.png
rm -f platform/iphone/Default-LandscapeRight.png
restore icon
rm -f platform/iphone/icon.png
cp platform/iphone/icon.bak platform/iphone/icon.png
rm -f platform/iphone/icon.bak
rm -f platform/iphone/icon57.png
cp platform/iphone/icon57.bak platform/iphone/icon57.png
rm -f platform/iphone/icon57.bak
rm -f platform/iphone/icon72.png
cp platform/iphone/icon72.bak platform/iphone/icon72.png
rm -f platform/iphone/icon72.bak
rm -f platform/iphone/icon114.png
cp platform/iphone/icon114.bak platform/iphone/icon114.png
rm -f platform/iphone/icon114.bak
************************************
ERROR during building by XCode !
XCode return next error code = pid 9102 exit 65
I checked the xcode organizer and the profile is both on the phone and the library. I checked developer.apple.com and the profile is Distribution Ad Hoc for the device plugged in.
My build.yml:
sdkversion: 3.3.2
name: My Application
version: 0.1
vendor: rhomobile
build: release
bbver: 4.6
applog: rholog.txt
iphone:
provisionprofile: 0558F1B2-FE5A-4236-B9EE-A200EFAD68E9
sdk: iphoneos5.1
codesignidentity: "iPhone Distribution"
entitlements:
configuration: Release
emulator: 5.1
emulatortarget: iphone
BundleIdentifier: com.randomname.myapplication
BundleURLScheme: myapplication
wp:
productid:
uid: 3928127822
android:
version: 2.1
extensions:
- accelerometer
Anyone got a clue what I missed here? Already been trying different things for a few days without result :(
After a while I found that the script checks for the provisioning profile in /Library/MobileDevice/Provisioning Profiles
instead of ~/Library/MobileDevice/Provisioning Profiles
. This is caused by using the sudo command, however without sudo I dont have permission. Workaround is to create a /Library/MobileDevice/Provisioning Profiles folder and copy the installed profile to that location. Code signing works fine now.
edit: even a better solution is to reinstall the rhodes gem without sudo. By installing the suite I had to sudo it to make system changes, however this made the compilation require sudo as well and therefor look in the wrong place for provisioning profiles.
This did the trick:
sudo gem uninstall rhodes
gem install rhodes