iOS Tutorial Local Mac Builder Installation

Status
Not open for further replies.
Edit: Apple Configurator 2 must be used when using a local Mac:
iOS compilation requires an Apple Mac computer. Developers have two options with B4i:
- Use a local Mac machine connected over the local network.
- Use our hosted builder rental service.

These instructions explain how to install the builder on a local Mac machine.

1. Install Java JDK 8: http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html
OpenJDK 11+ is also good (link is available here: https://www.b4x.com/android/forum/t...lest-way-to-distribute-ui-apps.99835/#content)

2. Install Xcode 14:
2.5. You need to run Xcode at least once. Approve installation of additional components when asked.
3. Download and unzip the B4i-Builder.
4. Open a terminal and navigate to B4i-Builder folder.
5. Run it with: java -jar B4iBuildServer.jar
6. Set the builder IP address in the IDE under Tools - Build Server - Server Settings
7. Install Apple configurator 2: https://www.b4x.com/android/forum/threads/installing-apps-with-apple-configurator-2.128397/#content
It is not possible to make an over the air installation with the local builder.
8. You might be asked for a password during a build (codesign step). The password is 111111

Notes & Tips

-
By default ports numbers 51041 (http) and 51042 (https) are used.
- The firewall should be either disabled or allow incoming connections on these two ports.
- You can test that the server is running by going to the following link: http://<server ip>:51041/test
- You can kill the server with: http://<server ip>:51041/kill
- It is recommended to set your Mac server ip address to a static address. This can be done in your router settings or in the Mac under Network settings.
- A single Mac builder can serve multiple developers as long as they are all connected to the same local network. Note that you are not allowed to host builders for developers outside of your organization.


Troubleshooting

BuildServer v1.02 includes a new test page which provides information about the server, including the SSL key ip address and the libraries versions.
You can access this page with: <Mac ip>:51041/test
 
Last edited:

paucon

New Member
Licensed User
Longtime User
All appeared to go well after acurately following the instructions, running the B4iBuildServer completes on the mac and reports "Build server is ready" which is confirmed from the PC when following the test link and the "Build server is running" page appears. However when compiling the app I receive a Communication error: SendFailure and the server reports

WARN:eek:ejh.HttpParser:qtp1389133897-25: badMessage: 400 Illegal character for HttpChannelOverHttp@7f28f133{r=0,a=IDLE,uri=-}

There is also a warning when running the B4iBuildServer as follows;

WARN:eek:ejh.MimeTypes:main: java.util.MissingResourceException: Can't find bundle for base name org/eclipse/jetty/http/encoding, locale en_US

Apologies if this is something obvious.

Thanks
 

Erel

B4X founder
Staff member
Licensed User
Longtime User
Hi Erel,
I followed above instructions and installed the local builder on my macbook pro with vmware running.

When first running the builder from the terminal, it picked one of the virtual ip addresses from vmware as the builder address.
After removing the builder directory, stopping vmware and then reinstalling the builder, it picked the correct ip address and everything now works smoothly.
Thanks
Val
I've added a "multiple ips" section to the first tutorial. It explains how to solve this issue.
 

alvinmb

Member
Licensed User
Longtime User
Erel,
I also get this message every time when I try and compile, after fixing my IP address issue I reported this morning.
My firewall is switched off so I dont think its a firewall issue.
 

paucon

New Member
Licensed User
Longtime User
Does it compile successfully if you change to the cloud Mac ip address?

Sorry for the delay, I just got back.

1. Firewall is not activated on the Mac
2. Yes it compiles correctly to the cloud Mac ip address
3. Noted cloud ip uses port 51042 so changed to this and got the following error

Error: xcrun: error: active developer path ("/Applications/Xcode 2.app/Contents/Developer") does not exist, use xcode-select to change

Suggesting an incorrect path or permissions issue

So ran the command

sudo xcode-select -switch /Applications/Xcode.app

All now appears to be working fine.

Thanks
 

alvinmb

Member
Licensed User
Longtime User
Can you post the error message?
Hi Erel

This is what Im getting

Build server is ready

https://192.168.0.10:51042

http://192.168.0.10:51041

2014-11-05 12:34:01.837:WARN:eek:ejh.HttpParser:qtp1880587981-43: badMessage: 400 Illegal character for HttpChannelOverHttp@7c004801{r=0,a=IDLE,uri=-}

2014-11-05 12:34:02.921:WARN:eek:ejh.HttpParser:qtp1880587981-43: badMessage: 400 Illegal character for HttpChannelOverHttp@47060e5d{r=0,a=IDLE,uri=-}
 

alvinmb

Member
Licensed User
Longtime User
I was able to reproduce this error. It happens when you try to connect to the non-SSL port instead of the SSL port.

You checked the port number, right? It should be 51042.
Have you deleted the key folder when you set the manual ip address?

Erel,
I will double check and start a fresh and see what happens. Thanks for the prompt reply and I will let you know later today.
Thanks
 

imbault

Well-Known Member
Licensed User
Longtime User
Erel,
just a warning on the mac:

2014-11-05 18:18:30.953:WARN:eek:ejh.MimeTypes:main: java.util.MissingResourceException: Can't find bundle for base name org/eclipse/jetty/http/encoding, locale fr_FR

Patrick
 
D

Deleted member 103

Guest
Hi,

why am I getting this error?

What is to be specified at server-setting as a User ID?
Parsing code. 0.01
Compiling code. 0.07
Compiling debugger engine code. 0.95
Building Xcode project 0.01
Sending data to remote compiler. Error
Out: Build settings from command line:
ARCHS = armv7
CODE_SIGN_IDENTITY = iPhone
CONFIGURATION_BUILD_DIR = /Users/filippogozza/Documents/B4iBuild-Server/UploadedProjects/beta116/Payload
OTHER_CODE_SIGN_FLAGS = --keychain beta116
PRODUCT_NAME = CMM
PROVISIONING_PROFILE = 0aa7276e-bb25-4881-8e87-4da6f1e9bb92

=== BUILD TARGET B4iProject OF PROJECT B4iProject WITH CONFIGURATION Release ===

Check dependencies

Write auxiliary files
/bin/mkdir -p /Users/filippogozza/Documents/B4iBuild-Server/UploadedProjects/beta116/build/B4iProject.build/Release-iphoneos/B4iProject.build/Objects-normal/armv7
write-file /Users/filippogozza/Documents/B4iBuild-Server/UploadedProjects/beta116/build/B4iProject.build/Release-iphoneos/B4iProject.build/Objects-normal/armv7/CMM.LinkFileList
write-file /Users/filippogozza/Documents/B4iBuild-Server/UploadedProjects/beta116/build/B4iProject.build/Release-iphoneos/B4iProject.build/CMM.hmap
write-file /Users/filippogozza/Documents/B4iBuild-Server/UploadedProjects/beta116/build/B4iProject.build/Release-iphoneos/B4iProject.build/CMM-all-target-headers.hmap
write-file /Users/filippogozza/Documents/B4iBuild-Server/UploadedProjects/beta116/build/B4iProject.build/Release-iphoneos/B4iProject.build/CMM-own-target-headers.hmap
write-file /Users/filippogozza/Documents/B4iBuild-Server/UploadedProjects/beta116/build/B4iProject.build/Release-iphoneos/B4iProject.build/CMM-all-non-framework-target-headers.hmap
write-file /Users/filippogozza/Documents/B4iBuild-Server/UploadedProjects/beta116/build/B4iProject.build/Release-iphoneos/B4iProject.build/CMM-generated-files.hmap
write-file /Users/filippogozza/Documents/B4iBuild-Server/UploadedProjects/beta116/build/B4iProject.build/Release-iphoneos/B4iProject.build/CMM-project-headers.hmap
 

Erel

B4X founder
Staff member
Licensed User
Longtime User
D

Deleted member 103

Guest
here is the full error message as text-file.
 

Attachments

  • full error message.txt
    47.1 KB · Views: 678
Status
Not open for further replies.
Top