LaserWeb4 [for Mac] … Advice please

Advert

LaserWeb4 [for Mac] … Advice please

Viewing 13 posts - 1 through 13 (of 13 total)
  • Author
    Posts
  • #436689
    Michael Gilligan
    Participant
      @michaelgilligan61133

      I have been trying LaserWeb4 [v4.0.996-130], and I'm impressed

      **LINK**

      https://github.com/LaserWeb/LaserWeb4-Binaries/releases

      This was installed from a DMG

      .

      I am now intending to update it to v4.0.996-134 … but that only has the Source Code available, and I'm out of my depth blush

      The download includes this [presumably helpful] text file:

      build.jpg

      … Could some kind soul please walk me through this ^^^

      … Presumably it is a script for me to enter in Terminal

      Thanks in advance

      MichaelG.

      Advert
      #15250
      Michael Gilligan
      Participant
        @michaelgilligan61133

        Old Dog needs to learn New Trick …

        #436700
        clivel
        Participant
          @clivel

          What you have there is a "shell" script which is run from the command line in a terminal window. The "shell" is a program that processes the commands, two of the more popular shells are bash and zsh. It looks as if this particular script is used to build the application so unless you intend rebuilding it, is probably not really useful to you.

          If you were a DOS user you may remember BAT files which ran a series of commands at the command line, a shell script is similar but vastly more powerful.

          Comments in a shell script start with # so all text in your script that follows a # is ignored by the shell it is only there for the user's edification, all that is except for the first line:
          #!/bin/sh which by convention indicate which application is used to execute the script, in this case /bin/sh (which is probably a link to the actual program),

          The first thing your script does is set a few environment variables:
          export SOMETHING=SOMETHING_ELSE

          The content of an environment variable is retrieved by means of the $ symbol. So: for example using the "echo" command that displays text in the terminal e.g:

          export XYZ=Hello
          echo "The XYZ variable contains $XYZ"
          would display
          The XYZ variable contains Hello

          That only just really touched the surface, if you are interested in learning more about shell scripts Google turned up some promising links when I searched for: introduction to shell script programming

          Clive

          #436701
          clivel
          Participant
            @clivel

            Oh, I should have read your posting more closely, you do want to build LaserWeb4 from the source.

            To do so, you will first need to install some development tools, I am not too familiar with Mac programming but you will probably need to install the Mac XCode development tools. Your script also makes use of git, yarn and npm. If any of these are not part of the Xcode development suite they will need to be installed separately.

            Once you have the tools installed, open up a terminal, change to the directory containing the build.osx.sh file, make sure that the file has execute permission, and then execute it by typing:
            ./build.osx.sh

            That should download the latest source code and build it.
            Clive

            Edited By clivel on 10/11/2019 15:46:12

            #436705
            Michael Gilligan
            Participant
              @michaelgilligan61133

              Many thanks, Clive yes

              I will give it a try tonight or tomorrow

              MichaelG.

              #436707
              SillyOldDuffer
              Moderator
                @sillyoldduffer

                Looks like the maintainer isn't available, there's been no response to any queries since 19th September's:

                Where is the .dmg (for OSX)

                I find the website isn't up-to-date and the only binary install currently available for the new version is for Windows. Both Linux and Mac require some source code hoop jumping. I'd be inclined to leave it for a few weeks to see if the maintainer provides a dmg. Could be that's what he's busy doing.

                However, if you want to install from source you have the necessary bash script. It appears to download and install Javascript modules, which are also scripts and almost certainly safe, to be run in a Browser.

                bash scripts are executed from the command line. Proceed to Mac's top-right corner & select the magnifying glass. Type terminal and a text window should open with a % or $ prompt.

                If you know the directory the script is stored in, it can be executed by typing:

                bash /path/to/build.sh

                where /path/to is the full directory name of the build script's directory. You should be able to find the full directory name by asking the magnifying glass to find 'build.sh', but there may be a few. Be sure you execute the right one.

                No guarantees – I'm not a Mac expert – but let me know what the script outputs if the advice fails. If necessary I'll steal daughters mac and install LaserWeb myself to see if it can be made to work.

                Dave

                #436710
                Michael Gilligan
                Participant
                  @michaelgilligan61133

                  Many thanks to you also, Dave yes

                  You have both, I think, assured me that I should be able to just call that script, rather than copying it line-by-line

                  … which is much simpler than I feared.

                  MichaelG.

                  #436743
                  Michael Gilligan
                  Participant
                    @michaelgilligan61133

                    Currently downloading Xcode … now that I have located the appropriate version: **LINK**

                    https://discussions.apple.com/thread/8648195

                    … this may take a while

                    MichaelG.

                    .

                    Edit: the download was 4.53GB … and it's now expanding it surprise

                    Edited By Michael Gilligan on 10/11/2019 19:18:30

                    #436757
                    Michael Gilligan
                    Participant
                      @michaelgilligan61133

                      Then … I had to download the 'Command Line Developer Tools'

                      And finally … It failed crying 2

                      fail.jpg

                      Looks like I will be sticking with -130 until the author provides a dmg

                      … But at least I have learned something; so thanks again

                      MichaelG.

                      .

                      Edit: I've just found this … 

                      https://forum.makerforums.info/t/hi-all-its-time-to-take-a-nap/9090

                      … so it looks like -130 until I find something better.

                      Edited By Michael Gilligan on 10/11/2019 19:55:27

                      #436830
                      Keith Petley
                      Participant
                        @keithpetley53472

                        Hi Michael,

                        I took a quick look at the errors above and if you still want to have a go at building this then try the following:

                        1 – I think you are launching the script from the wrong place. The script expects to be run from the directory where it is located.

                        cd Downloads/LaserWeb4-Binaries-4.0.996-134

                        ./build.osx.sh

                        2 – The script can't find the yarn command – you probably need to download it from somewhere

                        3 – The same with npm.

                        Keith

                        #436836
                        Michael Gilligan
                        Participant
                          @michaelgilligan61133

                          Thanks for that, Keith

                          … I will have another try this evening.

                          [no idea what the yarn command is, or npm … or where to find them]

                          MichaelG.

                          #436842
                          SillyOldDuffer
                          Moderator
                            @sillyoldduffer

                            yarn and npm are both package managers – used to download, install, and remove software.

                            yarn is available from here. But try typing 'brew install yarn' at the command line. (brew is another package manager)

                            npm is the Javascript package manager, and comes with node: Try typing 'brew install node'

                            If they install, re-run build.sh Good spot from Keith about it expecting to run in the directory in which it's located.

                            For background:

                            • DMG is the Mac Package Manager. If set up correctly by the software maintainer, it should download and install (or remove) all the software needed to make something work on an Apple computer. In this case it's not available in full form hence Michael has to install some foundation software manually. Welcome to the cruel world of software engineering. It's Dependency Hell!
                            • LaserWeb4 is a Javascript application, and any Javascript dependencies are managed by npm, 'Node Package Manager'.
                            • yarn is also a package manager, not sure what is does here, I think it's managing the Javascript components as a development package, ie a programmer tool supporting several people working at the same time on a project.
                            • git is a source code repository and version control package, also normally a programmer tool supporting team work. It may be necessary to install it as well.
                            • xcode is Mac's software development toolset, which is 'do everything' huge. May not need it, there's a smaller package called 'homebrew'.

                            Have sympathy for package management writers. On a large MS-Windows project of my acquaintance the stress was such that they had to be rotated off the job after about 6 months!

                            Dave

                            .

                            #437042
                            Michael Gilligan
                            Participant
                              @michaelgilligan61133

                              Many thanks for the help, Clive, Keith & Dave

                              I started along the brew / yarn / nam trail … but chickened-out when I got this far:

                              chicken.jpg

                              It's finally time to accept that we are obsolete sad

                              MichaelG.

                              Edited By Michael Gilligan on 12/11/2019 21:10:27

                            Viewing 13 posts - 1 through 13 (of 13 total)
                            • Please log in to reply to this topic. Registering is free and easy using the links on the menu at the top of this page.

                            Advert

                            Latest Replies

                            Viewing 25 topics - 1 through 25 (of 25 total)
                            Viewing 25 topics - 1 through 25 (of 25 total)

                            View full reply list.

                            Advert

                            Newsletter Sign-up