iOS Question [SOLVED]B4i 7.0 / Xcode 12.3 / Compiling error / Questions

christianjeannot

Member
Licensed User
Hello Community,

I tried to compile a test app (Hello World) to understand how B4i, the compiling, the certificates and the provisioning profiles works.
From the experiences with Xojo I do not use wildcards in the App Identifier Bundle. I use explicit one.

I am using a local Builder with
- Apple Mac Mini Late 2014
- macos 11.1
- xcode 12.3 (12C33)
- B4i 7.00

On my PC I am using
- Windows 10 1909 Build 18363.836
- B4i 7.00

I have configured the package name according to my Bundle Identifier.

I can run the B4i Buildserver test page on port 51041.

Is it correct that the test page only works on port 51041 and not on ssl, port 51042?

I follow the Videos "B4i Certificate and Provision Profile" and "B4i-Bridge" from Erel. The certificate and provisioning profile are stored in the Keys directory and in Xcode.

When I try to Build the Bridge App I got

B4X:
B4i Version: 7.00
Parsing code.    (0.01s)
Building folders structure.    (0.28s)
Running custom action.    (0.05s)
Compiling code.    (0.06s)
Building designer app.    (0.21s)
Building Xcode project.    (0.19s)
Preparing project for builder.    (0.12s)
    Project size: 0.23 MB
Sending data to remote compiler.    Error
Error: security: SecKeychainDelete: The specified keychain could not be found.

Out: Command line invocation:
    /Applications/Xcode_123.app/Contents/Developer/usr/bin/xcodebuild -configuration Release PRODUCT_NAME=B4i-Bridge CONFIGURATION_BUILD_DIR=/Users/**********ent/Downloads/B4iBuildServer/UploadedProjects/<user id>/Payload "CODE_SIGN_IDENTITY=iPhone Distribution: Christian Jeannot (**********)" "OTHER_CODE_SIGN_FLAGS=--keychain <user id>" PROVISIONING_PROFILE=******98-**74-**31-**28-**********75 -arch armv7 -arch arm64

Build settings from command line:
    ARCHS = armv7 arm64
    CODE_SIGN_IDENTITY = iPhone Distribution: Christian Jeannot (**********)
    CONFIGURATION_BUILD_DIR = /Users/**********ent/Downloads/B4iBuildServer/UploadedProjects/<user id>/Payload
    OTHER_CODE_SIGN_FLAGS = --keychain <user id>
    PRODUCT_NAME = B4i-Bridge
    PROVISIONING_PROFILE = ******98-**74-**31-**28-**********75

note: Using new build system
note: Using codesigning identity override: iPhone Distribution: Christian Jeannot (**********)
note: Planning build
note: Constructing build description
error: "B4iProject" requires a provisioning profile. Select a provisioning profile in the Signing & Capabilities editor. (in target 'B4iProject' from project 'B4iProject')
warning: The iOS deployment target 'IPHONEOS_DEPLOYMENT_TARGET' is set to 8.0, but the range of supported deployment target versions is 9.0 to 14.3.99. (in target 'B4iProject' from project 'B4iProject')


Error: ** BUILD FAILED **

Why it said B4iProject? I expected to see the Bundle Identifier / Package name here.
Is the Deployment Target with 8.0 correct?

Is there more documentation about B4i and the compiling procedure? From the Booklet titles I found not more.

If both informations are valid what can I do to fix this?

Best regards

--Christian
 

Erel

B4X founder
Staff member
Licensed User
Longtime User
Upvote 0

hatzisn

Expert
Licensed User
Longtime User
Hello Community,

I tried to compile a test app (Hello World) to understand how B4i, the compiling, the certificates and the provisioning profiles works.
From the experiences with Xojo I do not use wildcards in the App Identifier Bundle. I use explicit one.

I am using a local Builder with
- Apple Mac Mini Late 2014
- macos 11.1
- xcode 12.3 (12C33)
- B4i 7.00

On my PC I am using
- Windows 10 1909 Build 18363.836
- B4i 7.00

I have configured the package name according to my Bundle Identifier.

I can run the B4i Buildserver test page on port 51041.

Is it correct that the test page only works on port 51041 and not on ssl, port 51042?

I follow the Videos "B4i Certificate and Provision Profile" and "B4i-Bridge" from Erel. The certificate and provisioning profile are stored in the Keys directory and in Xcode.

When I try to Build the Bridge App I got

B4X:
B4i Version: 7.00
Parsing code.    (0.01s)
Building folders structure.    (0.28s)
Running custom action.    (0.05s)
Compiling code.    (0.06s)
Building designer app.    (0.21s)
Building Xcode project.    (0.19s)
Preparing project for builder.    (0.12s)
    Project size: 0.23 MB
Sending data to remote compiler.    Error
Error: security: SecKeychainDelete: The specified keychain could not be found.

Out: Command line invocation:
    /Applications/Xcode_123.app/Contents/Developer/usr/bin/xcodebuild -configuration Release PRODUCT_NAME=B4i-Bridge CONFIGURATION_BUILD_DIR=/Users/**********ent/Downloads/B4iBuildServer/UploadedProjects/<user id>/Payload "CODE_SIGN_IDENTITY=iPhone Distribution: Christian Jeannot (**********)" "OTHER_CODE_SIGN_FLAGS=--keychain <user id>" PROVISIONING_PROFILE=******98-**74-**31-**28-**********75 -arch armv7 -arch arm64

Build settings from command line:
    ARCHS = armv7 arm64
    CODE_SIGN_IDENTITY = iPhone Distribution: Christian Jeannot (**********)
    CONFIGURATION_BUILD_DIR = /Users/**********ent/Downloads/B4iBuildServer/UploadedProjects/<user id>/Payload
    OTHER_CODE_SIGN_FLAGS = --keychain <user id>
    PRODUCT_NAME = B4i-Bridge
    PROVISIONING_PROFILE = ******98-**74-**31-**28-**********75

note: Using new build system
note: Using codesigning identity override: iPhone Distribution: Christian Jeannot (**********)
note: Planning build
note: Constructing build description
error: "B4iProject" requires a provisioning profile. Select a provisioning profile in the Signing & Capabilities editor. (in target 'B4iProject' from project 'B4iProject')
warning: The iOS deployment target 'IPHONEOS_DEPLOYMENT_TARGET' is set to 8.0, but the range of supported deployment target versions is 9.0 to 14.3.99. (in target 'B4iProject' from project 'B4iProject')


Error: ** BUILD FAILED **

Why it said B4iProject? I expected to see the Bundle Identifier / Package name here.
Is the Deployment Target with 8.0 correct?

Is there more documentation about B4i and the compiling procedure? From the Booklet titles I found not more.

If both informations are valid what can I do to fix this?

Best regards

--Christian

It might be that you have not selected your device (put a check on it) in apple developer account when you create your profile. An other option is that you did not name the provisioning profile "default" (but if I remember correctly you would get a warning about that). A third option is that you did not set correctly the keys folder in your B4i (Tools > Configure paths - you need to place in this folder the provisioning profile).
 
Upvote 0

christianjeannot

Member
Licensed User
@Alex_197
Thank you for this hint. I had missed that.

@Erel
Thank you for the links. I will check them.
I will test thew hosted builder but as I have a Mac infrastructure I try to solve the errors and use my own infrastructure.

@hatzisn
Thank you for your hints. I will check them.

Best regards

--Christian
 
Upvote 0

christianjeannot

Member
Licensed User
Hi @all,

In my first try the Build Server was running with sudo. I have not found an information or overlook it but as which user has the Build Server to run?

When I run it now as normal user I got a different error message where it is more clear that this is a certificate issue. So I guess this can run as a normal user.

B4X:
error: Provisioning profile "ProvTestB4i" has app ID "biz.cjse.b4itest", which does not match the bundle ID "biz.cjse.b4i1st.bridge". (in target 'B4iProject' from project 'B4iProject')
error: Provisioning profile "ProvTestB4i" doesn't include signing certificate "iPhone Distribution: Christian Jeannot (**********)". (in target 'B4iProject' from project 'B4iProject')

Now with this error message I understand better why to use a wildcard.

When I try to compile Release App and Simulator Release App the compile action is working.

I am not able to copy the .ipa file to the device but this is also a certificate issue.

So I will creaste new certificates and continue.

Best regards

--Christian
 
Upvote 0
Top