Can't bootstrap

45 views
Skip to first unread message

Simon

unread,
Aug 20, 2017, 1:07:09 AM8/20/17
to Cappuccino & Objective-J
So, checking out either the starter app or the full source and running bootstrap.sh results in a working 'jake' installation - at least the --help option returns:

simon% jake --help

Usage: jake [OPTIONS] targets...

 -f --jakefile FILE: Use FILE as the jakefile.

 -T --tasks: Display the tasks with descriptions, then exit.

 -D --describe: Describe the tasks then exit.

 -P --prereqs: Display the tasks and dependencies, then exit.

 -v --verbose: Log message to standard output.

 -h --help: displays usage information (final option)



However, if I then (from the downloaded source directory) run 'jake install', I get:

(in /Volumes/home/opt/cap-src/Foundation)

(in /Volumes/home/opt/cap-src/Foundation)

(in /Volumes/home/opt/cap-src/Foundation)

(in /Volumes/home/opt/cap-src/Foundation)

(in /Volumes/home/opt/cap-src/Foundation)

(in /Volumes/home/opt/cap-src/Foundation)

(in /Volumes/home/opt/cap-src/Foundation)


... literally hundreds of the same ...


(in /Volumes/home/opt/cap-src/Foundation)

(in /Volumes/home/opt/cap-src/Foundation)

(in /Volumes/home/opt/cap-src/Foundation)

(in /Volumes/home/opt/cap-src/Foundation)

(in /Volumes/home/opt/cap-src/Foundation)

(in /Volumes/home/opt/cap-src/Foundation)

/opt/cappuccino/bin/narwhal: fork: Resource temporarily unavailable

/opt/cappuccino/bin/narwhal: line 4: cd: : No such file or directory

/opt/cappuccino/bin/narwhal: fork: Resource temporarily unavailable

/Volumes/home/opt/cappuccino/packages/narwhal-jsc/bin/narwhal-jsc: fork: Resource temporarily unavailable

/Volumes/home/opt/cappuccino/packages/narwhal-jsc/bin/narwhal-jsc: line 4: cd: : No such file or directory

/Volumes/home/opt/cappuccino/packages/narwhal-jsc/bin/narwhal-jsc: fork: Resource temporarily unavailable

/Volumes/home/opt/cappuccino/packages/narwhal-jsc/bin/narwhal-jsc: line 33: /opt/cap-src/Foundation/bin/narwhal-webkit: No such file or directory

/Volumes/home/opt/cappuccino/packages/narwhal-jsc/bin/narwhal-jsc: line 33: exec: /opt/cap-src/Foundation/bin/narwhal-webkit: cannot execute: No such file or directory


 
 I'm running OS X 10.12, I have the latest Xcode (8.3.3) and I'm fully patched. Is anyone else seeing the same ?

Martin Carlberg

unread,
Aug 22, 2017, 2:46:34 AM8/22/17
to objec...@googlegroups.com
Hi Simon,

I have not seen this before. It looks like if it just loops on building the Foundation framework and then runs out of resources as it will fork a new process for each one.

Usually when you run Jake with verbose you don’t get much more info but try ’jake -v install’ and check if you get any clues.

Can you do any other Jake commands like ’jake clean’?

- Martin

--
You received this message because you are subscribed to the Google Groups "Cappuccino & Objective-J" group.
To unsubscribe from this group and stop receiving emails from it, send an email to objectivej+...@googlegroups.com.
To post to this group, send email to objec...@googlegroups.com.
Visit this group at https://groups.google.com/group/objectivej.
For more options, visit https://groups.google.com/d/optout.

Simon

unread,
Aug 22, 2017, 11:06:38 AM8/22/17
to Cappuccino & Objective-J
Well, it happens on two different machines now. I'm not sure why :(

Running 'jake clean' before anything else gave me:

simon% jake clean


(in /opt/cap-src)


(in /opt/cap-src/Objective-J)


Build took 6 millseconds


(in /opt/cap-src/CommonJS)


Build took 2 millseconds


(in /opt/cap-src/Foundation)


Build took 3 millseconds


(in /opt/cap-src/AppKit)


(in /opt/cap-src/AppKit/Themes)


(in /opt/cap-src/AppKit/Themes/BlendKit)


Build took 2 millseconds


(in /opt/cap-src/AppKit/Themes/CommonJS)


Build took 2 millseconds


(in /opt/cap-src/AppKit/Themes/Aristo)


Build took 14 millseconds


(in /opt/cap-src/AppKit/Themes/Aristo2)


Build took 15 millseconds


Build took 2 seconds


Build took 3 seconds


(in /opt/cap-src/Tools)


(in /opt/cap-src/Tools/fontinfo)


=== CLEAN TARGET fontinfo OF PROJECT fontinfo WITH THE DEFAULT CONFIGURATION (Release) ===




Check dependencies




Clean.Remove clean build/fontinfo.build/Release/fontinfo.build


    builtin-rm -rf /opt/cap-src/Tools/fontinfo/build/fontinfo.build/Release/fontinfo.build




Clean.Remove clean build/Release/fontinfo


    builtin-rm -rf /opt/cap-src/Tools/fontinfo/build/Release/fontinfo




** CLEAN SUCCEEDED **




Build took 591 millseconds


(in /opt/cap-src/Tools/imagesize)


=== CLEAN TARGET imagesize OF PROJECT imagesize WITH THE DEFAULT CONFIGURATION (Release) ===




Check dependencies




Clean.Remove clean build/Release/imagesize


    builtin-rm -rf /opt/cap-src/Tools/imagesize/build/Release/imagesize




Clean.Remove clean build/imagesize.build/Release/imagesize.build


    builtin-rm -rf /opt/cap-src/Tools/imagesize/build/imagesize.build/Release/imagesize.build




** CLEAN SUCCEEDED **




Build took 599 millseconds


Build took 1 second


Build took 5 seconds



Then running 'jake' (just to see) gave me the same as before

simon% jake


(in /opt/cap-src)


(in /opt/cap-src/Objective-J)


Copying... CommonJS/objj-executable


Copying... CommonJS/package.json


Copying... CommonJS/bin/cplutil


Copying... CommonJS/bin/objj


Copying... CommonJS/bin/objjc


Building... /opt/cap-src/Build/Release/CommonJS/objective-j/lib/objective-j.js


Building... /opt/cap-src/Build/Release/CommonJS/objective-j/lib/objective-j/cache-manifest.js


Building... /opt/cap-src/Build/Release/CommonJS/objective-j/lib/objective-j/compiler.js


Building... /opt/cap-src/Build/Release/CommonJS/objective-j/lib/objective-j/jake.js


Building... /opt/cap-src/Build/Release/CommonJS/objective-j/lib/objective-j/loader.js


Building... /opt/cap-src/Build/Release/CommonJS/objective-j/lib/objective-j/jake/applicationtask.js


Building... /opt/cap-src/Build/Release/CommonJS/objective-j/lib/objective-j/jake/bundletask.js


Building... /opt/cap-src/Build/Release/CommonJS/objective-j/lib/objective-j/jake/environment.js


Building... /opt/cap-src/Build/Release/CommonJS/objective-j/lib/objective-j/jake/frameworktask.js


Copying... CommonJS/lib/objective-j/jake/LICENSES/LGPL-v2.1


Copying... CommonJS/lib/objective-j/jake/LICENSES/MIT


Copying... CommonJS/lib/objective-j/jake/RESOURCES/MHTMLTest.txt


Building... /opt/cap-src/Build/Release/CommonJS/objective-j/lib/objective-j/rhino/regexp-rhino-patch.js


Building... /opt/cap-src/Build/Release/Objective-J/Objective-J.js


    Version:   0.9.10


    Revision:  76d77cc244c11d9bd33d42902063cfe0ea0f9d59


    Timestamp: 1503412696396


Build took 1 second


(in /opt/cap-src/CommonJS)


    Version:   0.9.10


    Revision:  76d77cc244c11d9bd33d42902063cfe0ea0f9d59


    Timestamp: 1503412696630


Build took 24 millseconds


(in /opt/cap-src/Foundation)


(in /opt/cap-src/Foundation)


(in /opt/cap-src/Foundation)

...

I pressed CTRL-C a few times to kill the process, and now running any jake command gives the same result:

jake


(in /opt/cap-src)


(in /opt/cap-src)


(in /opt/cap-src)


(in /opt/cap-src)


(in /opt/cap-src)

...

So the other thing is that OSX10.12 doesn't seem to like installing Java properly (and running bootstrap.sh wants to run java for something because I get the popup dialog saying basically 'you need to install Java'. If I go to the site in the popup  dialog, and install Java 8, then re-run bootstrap.sh, I get the same popup; repeat ad nauseum).

The only way around that according to the FAQ is to download Apple's Legacy Java 6 and install that. I've done that, and I can then run bootstrap.sh, but now I'm wondering if the legacy Java implementation is causing the issue. 

I tried doing a fresh re-install and telling bootstrap.sh to *not* build the jsc engine, but then running jake fails:

simon% jake


/opt/cappuccino/packages/narwhal-jsc/bin/narwhal-jsc: line 33: /opt/cappuccino/packages/narwhal-jsc/bin/narwhal-jscore: No such file or directory


/opt/cappuccino/packages/narwhal-jsc/bin/narwhal-jsc: line 33: exec: /opt/cappuccino/packages/narwhal-jsc/bin/narwhal-jscore: cannot execute: No such file or directory




(I git cloned cappuccino to /opt/cap-src and set /opt/cappuccino as the installation dir)

If I cd to /opt/cappuccino/packages/narwhal-jsc and type 'make', it makes the binary 'narwhal-jscore', but I presume I'm then running the jsc variant as if I'd specified that in the script, because the behaviour of running a top-level 'jake' is the same as before (i.e.: it gets stuck in /opt/cap-src/Foundation)


So, fresh install again, and this time following your request, I passed the -v option to jake, but it looks very similar:

jake -v install

(in /opt/cap-src)

(in /opt/cap-src)

(in /opt/cap-src/Objective-J)

Copying... CommonJS/objj-executable

Copying... CommonJS/package.json

Copying... CommonJS/bin/cplutil

Copying... CommonJS/bin/objj

Copying... CommonJS/bin/objjc

Building... /opt/cap-src/Build/Debug/CommonJS/objective-j/lib/objective-j.js

Building... /opt/cap-src/Build/Debug/CommonJS/objective-j/lib/objective-j/cache-manifest.js

Building... /opt/cap-src/Build/Debug/CommonJS/objective-j/lib/objective-j/compiler.js

Building... /opt/cap-src/Build/Debug/CommonJS/objective-j/lib/objective-j/jake.js

Building... /opt/cap-src/Build/Debug/CommonJS/objective-j/lib/objective-j/loader.js

Building... /opt/cap-src/Build/Debug/CommonJS/objective-j/lib/objective-j/jake/applicationtask.js

Building... /opt/cap-src/Build/Debug/CommonJS/objective-j/lib/objective-j/jake/bundletask.js

Building... /opt/cap-src/Build/Debug/CommonJS/objective-j/lib/objective-j/jake/environment.js

Building... /opt/cap-src/Build/Debug/CommonJS/objective-j/lib/objective-j/jake/frameworktask.js

Copying... CommonJS/lib/objective-j/jake/LICENSES/LGPL-v2.1

Copying... CommonJS/lib/objective-j/jake/LICENSES/MIT

Copying... CommonJS/lib/objective-j/jake/RESOURCES/MHTMLTest.txt

Building... /opt/cap-src/Build/Debug/CommonJS/objective-j/lib/objective-j/rhino/regexp-rhino-patch.js

Building... /opt/cap-src/Build/Debug/Objective-J/Objective-J.js

   Version:   0.9.10

   Revision:  76d77cc244c11d9bd33d42902063cfe0ea0f9d59

   Timestamp: 1503414266446

Build took 362 millseconds

(in /opt/cap-src/CommonJS)

   Version:   0.9.10

   Revision:  76d77cc244c11d9bd33d42902063cfe0ea0f9d59

   Timestamp: 1503414266666

Build took 23 millseconds

(in /opt/cap-src/Foundation)

(in /opt/cap-src/Foundation)

(in /opt/cap-src/Foundation)

(in /opt/cap-src/Foundation)

...

At this point I'm stuck. I don't know much about 'jake' or how it works, so figuring out why it's constantly spawning a new process is gonna be hard...

Simon.

Simon

unread,
Aug 22, 2017, 11:15:35 AM8/22/17
to Cappuccino & Objective-J
Well, that's damn annoying. Google groups just gave up after the first quoted text.

Recap:

1) Running jake -v install didn't make any difference. As far as I can tell it's the same output (I'd post it, but that seems to make Groups eat your post...). Certainly I got the same result.
2) Trying a fresh install, running bootstrap without compiling jsc left me with no working 'jake' command 
2a) cd'ing to /opt/cappuccino/packages/narwhal-jsc and running make gave me the same as (1)
3) Running 'jake' on its own (no install) gave the same as (1)

One thing: When I first ran bootstrap.sh it asked me to install Java. If I go to the url in the popup dialog and install Java 8, then re-run bootstrap.sh it again asks me to install Java, even though it's installed.

According to the Java FAQ, the way around this is to install the legacy Java 6 environment, so I downloaded that and installed it - then I could run bootstrap.sh. I'm wondering now if running a legacy environment is part of the problem...

Cheers
  Simon


Simon

unread,
Aug 22, 2017, 1:03:31 PM8/22/17
to Cappuccino & Objective-J
For what it's worth, I get very similar output on my Linux box as well:

[simon]$ jake

(in /home/simon/src/cappuccino)

(in /home/simon/src/cappuccino/Objective-J)

Copying... CommonJS/objj-executable

Copying... CommonJS/package.json

Copying... CommonJS/bin/cplutil

Copying... CommonJS/bin/objj

Copying... CommonJS/bin/objjc

Building... /home/simon/src/cappuccino/Build/Release/CommonJS/objective-j/lib/objective-j.js

Building... /home/simon/src/cappuccino/Build/Release/CommonJS/objective-j/lib/objective-j/cache-manifest.js

Building... /home/simon/src/cappuccino/Build/Release/CommonJS/objective-j/lib/objective-j/compiler.js

Building... /home/simon/src/cappuccino/Build/Release/CommonJS/objective-j/lib/objective-j/jake.js

Building... /home/simon/src/cappuccino/Build/Release/CommonJS/objective-j/lib/objective-j/loader.js

Building... /home/simon/src/cappuccino/Build/Release/CommonJS/objective-j/lib/objective-j/jake/applicationtask.js

Building... /home/simon/src/cappuccino/Build/Release/CommonJS/objective-j/lib/objective-j/jake/bundletask.js

Building... /home/simon/src/cappuccino/Build/Release/CommonJS/objective-j/lib/objective-j/jake/environment.js

Building... /home/simon/src/cappuccino/Build/Release/CommonJS/objective-j/lib/objective-j/jake/frameworktask.js

Copying... CommonJS/lib/objective-j/jake/LICENSES/LGPL-v2.1

Copying... CommonJS/lib/objective-j/jake/LICENSES/MIT

Copying... CommonJS/lib/objective-j/jake/RESOURCES/MHTMLTest.txt

Building... /home/simon/src/cappuccino/Build/Release/CommonJS/objective-j/lib/objective-j/rhino/regexp-rhino-patch.js

Building... /home/simon/src/cappuccino/Build/Release/Objective-J/Objective-J.js

    Version:   0.9.10

    Revision:  76d77cc244c11d9bd33d42902063cfe0ea0f9d59

    Timestamp: 1503419192567

Build took 633 millseconds

(in /home/simon/src/cappuccino/CommonJS)

    Version:   0.9.10

    Revision:  76d77cc244c11d9bd33d42902063cfe0ea0f9d59

    Timestamp: 1503419194104

Build took 54 millseconds

(in /home/simon/src/cappuccino/Foundation)

(in /home/simon/src/cappuccino/Foundation)

(in /home/simon/src/cappuccino/Foundation)

(in /home/simon/src/cappuccino/Foundation)

(in /home/simon/src/cappuccino/Foundation)

...

Simon

unread,
Aug 22, 2017, 7:59:22 PM8/22/17
to Cappuccino & Objective-J
I'm really not having much luck with this. I found that there's an alternative build option using node.js, tried that and got:

 simon% jake
(in /Volumes/home/opt/cap-src)
(in /Volumes/home/opt/cap-src/Objective-J)
Copying... CommonJS/objj-executable
Copying... CommonJS/package.json
Copying... CommonJS/bin/cplutil
Copying... CommonJS/bin/objj
Copying... CommonJS/bin/objjc
Building... /opt/cap-src/Build/Release/CommonJS/objective-j/lib/objective-j.js
Building... /opt/cap-src/Build/Release/CommonJS/objective-j/lib/objective-j/cache-manifest.js
Building... /opt/cap-src/Build/Release/CommonJS/objective-j/lib/objective-j/compiler.js
Building... /opt/cap-src/Build/Release/CommonJS/objective-j/lib/objective-j/jake.js
Building... /opt/cap-src/Build/Release/CommonJS/objective-j/lib/objective-j/loader.js
Building... /opt/cap-src/Build/Release/CommonJS/objective-j/lib/objective-j/jake/applicationtask.js
Building... /opt/cap-src/Build/Release/CommonJS/objective-j/lib/objective-j/jake/bundletask.js
Building... /opt/cap-src/Build/Release/CommonJS/objective-j/lib/objective-j/jake/environment.js
Building... /opt/cap-src/Build/Release/CommonJS/objective-j/lib/objective-j/jake/frameworktask.js
Copying... CommonJS/lib/objective-j/jake/LICENSES/LGPL-v2.1
Copying... CommonJS/lib/objective-j/jake/LICENSES/MIT
Copying... CommonJS/lib/objective-j/jake/RESOURCES/MHTMLTest.txt
Building... /opt/cap-src/Build/Release/CommonJS/objective-j/lib/objective-j/rhino/regexp-rhino-patch.js
Building... /opt/cap-src/Build/Release/Objective-J/Objective-J.js
Throw caught by top level try in narwhal-node/bootstrap.js
Error: BufCache.next(n) only takes positive numbers.  n is 0
/Volumes/home/opt/cappuccino/node_modules/synchronize/sync.js:114
        fiber.run(result)
              ^

Error: BufCache.next(n) only takes positive numbers.  n is 0
    at BufCache.next (/Volumes/home/opt/cappuccino/packages/narwhal-node/lib/io-engine.js:49:15)
    at RawReadable._binPopBytes (/Volumes/home/opt/cappuccino/packages/narwhal-node/lib/io-engine.js:457:28)
    at RawReadable.read (/Volumes/home/opt/cappuccino/packages/narwhal-node/lib/io-engine.js:520:34)
    at Object.exports.receiveLengthPrefixMessage (/opt/cappuccino/packages/shrinksafe/lib/minify/shrinksafe.js:126:24)
    at compressUsingServer (/opt/cappuccino/packages/shrinksafe/lib/minify/shrinksafe.js:81:28)
    at Object.exports.compress (/opt/cappuccino/packages/shrinksafe/lib/minify/shrinksafe.js:14:16)
    at compressor (/Volumes/home/opt/cap-src/Objective-J/jakefile:114:23)
    at gcc (/Volumes/home/opt/cap-src/Objective-J/jakefile:138:20)
    at eval (/Volumes/home/opt/cap-src/Objective-J/jakefile:43:5)
    at FileTask.eval (/opt/cappuccino/packages/jake/lib/jake/task.js:153:9)

Simon

unread,
Aug 22, 2017, 8:21:33 PM8/22/17
to Cappuccino & Objective-J
Well, success of a sort. I still can't get the recommended dev-environment, but if I install the latest Starter package, and then do the bootstrap thing, that seems to sort of work. 

  •  'capp' doesn't work, it just returns that it can't find objective-j (I'm assuming it's looking for /opt/cappuccino/packages/objective-j which does exist)
  • However, pushing 'NewApplication' over to the webserver works, and I can do 'jake deploy' to trim down NewApplication a bit. If I couple that with apache gzip compression, that'll do. I'll just have to figure out how to rename NewApplication (Info.plist ?) and take it from there...

Martin Carlberg

unread,
Aug 23, 2017, 4:46:55 AM8/23/17
to objec...@googlegroups.com
Hi

Somehow your installation is messed up.

I don’t recognize the paths you are referring to like /opt/cappuccino/packages/objective-j
Is this where you have cloned the git repo?

I’m using Java 1.8 and it works great:
> java -version
java version "1.8.0_112"
Java(TM) SE Runtime Environment (build 1.8.0_112-b16)
Java HotSpot(TM) 64-Bit Server VM (build 25.112-b16, mixed mode)

Don’t remember that I have installed any legacy version.

. Martin


Simon

unread,
Aug 23, 2017, 11:34:21 AM8/23/17
to Cappuccino & Objective-J
I "git clone"d into ~/src/cappuccino and then when bootstrap.sh asked me where I wanted to install it, I typed '/opt/cappuccino'. That installation appears to be all there.

I don't think there's anything off with the system - it's literally had a "wipe the disk and reinstall everything" installation of the OS a couple of months back when I got it. It's not exhibiting any other peculiarities or idiosyncrasies, and unless Apple are pointing me to the wrong download link, there's not a lot of things that I can really do wrong with the installation itself - it's a click-and-done operation, which installs Java correctly into the web environment (1.8) but doesn't seem to install it into the command line environment. I'm wondering if it's because of SIP. Maybe I'll try the reboot-to-restore-image and use crsutil to turn off SIP. 

In any event, I'm ok with what *is* working for now. 

Keary Suska

unread,
Aug 23, 2017, 3:37:46 PM8/23/17
to objec...@googlegroups.com

> On Aug 23, 2017, at 9:34 AM, Simon <simon....@mac.com> wrote:
>
> I "git clone"d into ~/src/cappuccino and then when bootstrap.sh asked me where I wanted to install it, I typed '/opt/cappuccino'. That installation appears to be all there.
>
> I don't think there's anything off with the system - it's literally had a "wipe the disk and reinstall everything" installation of the OS a couple of months back when I got it. It's not exhibiting any other peculiarities or idiosyncrasies, and unless Apple are pointing me to the wrong download link, there's not a lot of things that I can really do wrong with the installation itself - it's a click-and-done operation, which installs Java correctly into the web environment (1.8) but doesn't seem to install it into the command line environment. I'm wondering if it's because of SIP. Maybe I'll try the reboot-to-restore-image and use crsutil to turn off SIP.
>
> In any event, I'm ok with what *is* working for now.

It is an understandable confusion, as bootstrap and the docs are a bit loose about this, but there are actually two different parts to cappuccino. One is called “narwhal”, and that is the installation path that is requested; the other is the cappuccino framework itself, which is always built in the $CAPP_BUILD directory (which you will be asked to set if it isn’t already). These two directories should be different. Other than certain tools (such as the capp command), you will not generally use narwhal.Almost all of your work will only depend on the cappuccino frameworks.

You will probably run into problems if you don’t call the first part “narwhal”, and that might be part of what you are experiencing. On top of that you need to verify that your $PATH includes the path to the narwhal installation. If the PATH or CAPP_BUILD are not set and correct you will have compilation problems.

HTH,

Keary Suska
Esoteritech, Inc.
"Demystifying technology for your home or business"

Reply all
Reply to author
Forward
0 new messages