Found an issue in SpiderBasic ? Please report it here !
Dirk Geppert
 
Posts: 132
Joined: Fri Sep 22, 2017 7:02 am

Re: [Done] 2.21 : Create iOS app stops at 60%

by Dirk Geppert Wed Sep 25, 2019 9:39 am

Now I'm confused. "cordova platform remove ios" says, "no cordova based project in current directory".

Cordova seems to be looking for a directory called "platforms" and a file: package.json.

I found this in the directory "\temp\spiderdummy".

Where does the subsystem have to be installed? In the output directory of the app?
Dirk Geppert
 
Posts: 132
Joined: Fri Sep 22, 2017 7:02 am

Re: [Done] 2.21 : Create iOS app stops at 60%

by Dirk Geppert Wed Sep 25, 2019 9:59 am

I tried some more. Copied all files from /tmp/spiderdummy into my project directory "/Documents/Apps".
Started "Cordova remove [...]" and "Cordova add [...]"
Code: Select all
Using cordova-fetch for cordova-ios@^5.0.0
Adding ios project...
Creating Cordova project for the iOS platform:
   Path: platforms/ios
   Package: com.example.hello
   Name: HelloWorld
iOS project created with cordova-ios@5.0.1
Installing "cordova-plugin-geolocation" for ios
Installing "cordova-plugin-nativeaudio" for ios
Installing "cordova-plugin-whitelist" for ios


But still no success :(

Code: Select all

sbcompiler ./CanvasGadget.sb -an HelloWorld -pi com.example.hello -i -vb -o HelloWorld.ipa -at AppleTeamID

******************************************
SpiderBasic 2.22 (MacOS X - x64)
******************************************

Compiling './CanvasGadget.sb'
Loading libraries...
Error: Can't load the 'ios' subsystem.
hoerbie
 
Posts: 23
Joined: Sun Mar 17, 2019 5:51 pm

Re: [Done] 2.21 : Create iOS app stops at 60%

by hoerbie Wed Sep 25, 2019 7:24 pm

Hi,

this "Error: Can't load the 'ios' subsystem." from my point of view has not really to do with not/worng installed iOS subsystem. I get the same error when trying manually to compile, although SBs create app works, I think there simply is something missing in the sbcompiler parameters.

@Dirk: Please try the following in terminal:
Code: Select all
npm info cordova-ios

I get then something like
Code: Select all
cordova-ios@5.0.1 | Apache-2.0 | deps: 9 | versions: 822
cordova-ios release
https://github.com/apache/cordova-ios#readme

keywords: ios, cordova, apache, ecosystem:cordova, cordova:platform

dist
.tarball: https://registry.npmjs.org/cordova-ios/-/cordova-ios-5.0.1.tgz
<snip>

dependencies:
cordova-common: ^3.1.0 plist: ^3.0.1          unorm: ^1.4.1         
ios-sim: ^8.0.1        q: ^1.5.1              xcode: ^2.0.0         
nopt: ^4.0.1           shelljs: ^0.5.3        xml-escape: ^1.1.0     

maintainers:
<snip>

dist-tags:
latest: 5.0.1
nightly: 5.1.0-nightly.2019.9.23.be68c9f6
rc: 3.6.3


And did you check the .config directory rights problem?
Dirk Geppert
 
Posts: 132
Joined: Fri Sep 22, 2017 7:02 am

Re: [Done] 2.21 : Create iOS app stops at 60%

by Dirk Geppert Thu Sep 26, 2019 7:16 am

Looks like the same:

Code: Select all
npm info cordova-ios

cordova-ios@5.0.1 | Apache-2.0 | deps: 9 | versions: 823
cordova-ios release
https://github.com/apache/cordova-ios#readme

keywords: ios, cordova, apache, ecosystem:cordova, cordova:platform

dist
.tarball: https://registry.npmjs.org/cordova-ios/-/cordova-ios-5.0.1.tgz
.shasum: 8ee30280c47f29cc3e8716167a9ce33cbaf9debd
.integrity: sha512-JcFyDmlyzY2OQJo0eHpuFERFqvO4daHl8HL96RhUVjJVtuoqXHsOF0xTuQSAqIbefelMPEWwY3Lc/dvT4ttTwQ==
.unpackedSize: 3.8 MB

dependencies:
cordova-common: ^3.1.0 plist: ^3.0.1          unorm: ^1.4.1         
ios-sim: ^8.0.1        q: ^1.5.1              xcode: ^2.0.0         
nopt: ^4.0.1           shelljs: ^0.5.3        xml-escape: ^1.1.0     

dist-tags:
latest: 5.0.1
nightly: 5.1.0-nightly.2019.9.26.be68c9f6
rc: 3.6.3

hoerbie
 
Posts: 23
Joined: Sun Mar 17, 2019 5:51 pm

Re: [Done] 2.21 : Create iOS app stops at 60%

by hoerbie Thu Sep 26, 2019 8:05 am

Then all cordova really needs for iOS build should be there.

Please double check the rights of the directory ".config" in your home directory ("/home/<yourusername>/") and also every rights in the .config directory.

Opening the terminal you should normally be in your home dir, so
Code: Select all
ls -la .config

should show you something like
Code: Select all
drwx------   6 <yourusername>  staff   192 18 Jun 13:56 .
drwxr-xr-x+ 40 <yourusername>  staff  1280 26 Sep 09:12 ..
drwx------   6 <yourusername>  staff   192 25 Sep 10:15 configstore


and
Code: Select all
ls -la .config/configstore

should show you something like
Code: Select all
drwx------  6 <yourusername>  staff  192 25 Sep 10:15 .
drwx------  6 <yourusername>  staff  192 18 Jun 13:56 ..
-rw-------  1 <yourusername>  staff    2 19 Apr 10:54 cordova-config.json
-rw-------  1 <yourusername>  staff   47 19 Apr 10:54 insight-cordova.json
-rw-------  1 <yourusername>  staff   55 25 Sep 10:15 update-notifier-cordova.json
-rw-------  1 <yourusername>  staff   55 25 Sep 10:15 update-notifier-npm.json

Instead of <yourusername> there should be your username and not "root". When there is something to be fixed, fix it (see posting above) and please try again the "create app" on SB.
The date and time can be something else at your Mac, but the above "25 Sep 10:15" is the time, when I created my app successfully yesterday with SB.

And just a shot in the dark for your manual compile try: did you try a "sudo" of your "sbcompiler...." command?
Dirk Geppert
 
Posts: 132
Joined: Fri Sep 22, 2017 7:02 am

Re: [Done] 2.21 : Create iOS app stops at 60%

by Dirk Geppert Thu Sep 26, 2019 8:44 am

@hoerbie: thank you for your support!

Looks like everything's fine:

Code: Select all
Last login: Thu Sep 26 09:11:05 on ttys000
MACmini:~ ich$ ls -la .config
total 0
drwx------   3 ich  staff   96 29 Jan  2019 .
drwxr-xr-x+ 20 ich  staff  640 13 Feb  2019 ..
drwx------   6 ich  staff  192 26 Sep 09:11 configstore
MACmini:~ ich$ ls -la .config/configstore
total 32
drwx------  6 ich  staff  192 26 Sep 09:11 .
drwx------  3 ich  staff   96 29 Jan  2019 ..
-rw-------  1 ich  staff    2 15 Aug 09:53 cordova-config.json
-rw-------  1 ich  staff   46 15 Aug 09:53 insight-cordova.json
-rw-------  1 ich  staff   55 25 Sep 14:50 update-notifier-cordova.json
-rw-------  1 ich  staff   55 26 Sep 09:11 update-notifier-npm.json
MACmini:~ ich$


I also tried to start the compiler with sudo:

Code: Select all
******************************************
SpiderBasic 2.22 (MacOS X - x64)
******************************************

Compiling '/Applications/SpiderBasic.app/Contents/Resources/examples/CanvasGadget.sb'
Loading libraries...
Error: Can't load the 'ios' subsystem.
MACmini:~ ich$



I don't understand about the subsystem. Is this a directory that Cordova installs and that is made known via PATH variables or something like that?
Or is that part of SpiderBasic?

Freds installation script creates a test application HelloWord in the Tmp/spiderdummy directory.
Why does the command "cordova add ios" only work in this directory?
Then maybe the path to the Cordova subsystems is not correct or not set or something like that?
hoerbie
 
Posts: 23
Joined: Sun Mar 17, 2019 5:51 pm

Re: [Done] 2.21 : Create iOS app stops at 60%

by hoerbie Fri Sep 27, 2019 7:38 am

@Dirk, sorry, this were all problems I had to solve and solved this year, your .config looks good, and your idea of wrong path seems right.

I wouldn't invest further time with the SB compile in terminal, I tried a lot with the sbcompiler but couldn't compile anything due to missing examples and its poor documentation of the needed parameters, needed path etc.

When I couldn't create iOS apps with SB this spring, i did a manual build, so that I was sure, that Xcode and Cordova were installed and configured correctly, maybe you can find out what's wrong at your Mac installation this way (see web documentation of Cordova).

Sorry, i can't remember the exact steps, but in short words I did the following:
-create a blank Cordova app in terminal
-add the iOS tools to the blank app in terminal
-compile a Web app in SpiderBasic to a blank directory with copying all libs/resources needed and a html filename "index.html"
[-copy the directory from the SpiderBasic Web app to another computer without SB and check it there in browser (to be sure nothing is missing)]
-copy all files and directories from the SpiderBasic Web app directory to the right directory in the blank Cordova app
I think the above steps SpiderBasic does in similar way.

But I think, at this step I saw project/workspace file for Xcode in the Cordova app (sub-)directories and opened it in the desktop Xcode. Then I could compile my first working iOS app directly in Xcode, test it in simulator and deploy it on my iOS devices.
I think this also could be done in terminal with Cordova commands and the Xcode command line tools, like SpiderBasic does, but at this step I wanted results and no more trial and error, so I preferred the clicky-way.
Dirk Geppert
 
Posts: 132
Joined: Fri Sep 22, 2017 7:02 am

Re: [Done] 2.21 : Create iOS app stops at 60%

by Dirk Geppert Mon Sep 30, 2019 8:54 am

Thanks again hoerbie! I'm one step further.

1. I've created a blank new cordova project under /Users/[..]/Documents/newApp/:

According to codova --help I took the following steps then:

Code: Select all
cordova create myApp org.apache.cordova.myApp myApp


Changed directory to myApp and added iOS support:
Code: Select all
cordova platform add ios


Checked requirements:
Code: Select all
cordova requirements ios


This one told me, that CocaPods isn't installed
Code: Select all
sudo gem install cocapods


After that, I could build and run my first ios App :-)
Code: Select all
cordova build ios
cordova run ios


The canvas app is displayed in the emulator and runs :-)

Unfortunately, creating ios Apps with Spiderbasic is still not possible. :-(
hoerbie
 
Posts: 23
Joined: Sun Mar 17, 2019 5:51 pm

Re: [Done] 2.21 : Create iOS app stops at 60%

by hoerbie Mon Oct 07, 2019 2:54 pm

@Dirk: Sorry for delay, we had the biggest folk fair of the world here and I was busy.

Your direct Cordova testing looks good to me, so that I think Cordova and Xcode generally are installed correctly.

I'm just not sure, with what account and certificates your above test build was done. Looking at https://cordova.apache.org/docs/en/latest/guide/platforms/ios/index.html there are parameters like the "Code Sign Identity", "Development Team", "Packaging Type", "Provisioning Profile" and so on. Maybe your build was done with some Cordova defaults and there is still something missing from _your_ developer account/configuration?
If you have a look at the file "build.json" of your test build, does it look like the example at the webpage and/or does it contain your Apple Team ID?
Maybe you can try to open the file "platforms/ios/myApp.xcworkspace" of your Cordova build in Xcode desktop, there maybe you are able to find out better, what Xcode is doing and using, and you could try to compile there and maybe get some warnings/error messages to identify the problem.

And just another shot in the dark: I never installed SpiderBasic at the normal "programs" directory, as I have a "Development" directory in my home dir, where I have different PB and SB versions installed in different subdirectories, so if not done until now, maybe you could try to install SB to a different directory. If you open the installer, just pull from from the left to an open Finder window or directly to desktop.

And one last idea, in the beginning I had some problems in compiling without the "Enable debugger" switch activated, although I now can't reproduce it.
Return to Bugs Reports

Who is online

Users browsing this forum: No registered users and 0 guests