<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><html><head><meta content="text/html;charset=UTF-8" http-equiv="Content-Type"></head><body ><div style='font-size:10pt;font-family:Verdana,Arial,Helvetica,sans-serif;'><div id="message"></div>Hi, <div><br></div><div>I totally agreed to use -x instead to exclude the folder, this will also eliminate the extra unnecessary folder. Thanks for the better fix. </div><div><br></div><div>As for the extra folder case, it could be very tricky as there are many possibilities of the dev packaging an module,  it could make the packaging flexible,  but also lacking of standardization?</div><div><br></div><div>Just my thought</div><div><br></div><div>Thanks</div><div><br></div><div>Rgds,</div><div>CL<br id="br3"><br id="br3"><br id="br3"><div id="signature"></div><div id="content"><br> ---- On Tue, 05 Nov 2019 17:52:42 +0800 <b> stephane.mottelet@utc.fr </b> wrote ----<br><br><blockquote style="border-left: 1px solid rgb(204, 204, 204); padding-left: 6px; margin-left: 5px;"><meta>
  
  <div>
    <p>Le 05/11/2019 à 08:18, Stéphane Mottelet a écrit :<br>
    </p>
    <blockquote>
      <meta>
      <div dir="ltr">Great analysis !</div>
      <div dir="ltr"><br>
        <blockquote>Le 5 nov. 2019 à 07:16, Chin Luh Tan
          <a class="x_-71738144moz-txt-link-rfc2396E" href="mailto:chinluh.tan@bytecode-asia.com" target="_blank"><chinluh.tan@bytecode-asia.com></a> a écrit :<br>
          <br>
        </blockquote>
      </div>
      <blockquote>
        <div dir="ltr">
          <meta>
          <div style="font-family: Verdana, Arial, Helvetica, sans-serif;font-size: 10.0pt;">
            <div>Hi,<br>
            </div>
            <div><br>
            </div>
            <div>just to add on to the issue on the atomsInstall. I
              finally find out that the issue was due to the extra
              "__MACOSX" folder created during zip process under MAC.<br>
            </div>
            <div><br>
            </div>
            <div>"<span class="x_-71738144colour" style="color: rgb(102,102,102);"><span class="x_-71738144font" style="font-family: Arial, Helvetica, sans-serif;"><span class="x_-71738144size" style="font-size: 13.3333px;">The __MACOSX folder is
                    created when a Mac user creates and archive (also
                    called a zip file) using the Mac. If the Mac user
                    sends the zip file to another Mac user, the folder
                    will not appear - <span class="x_-71738144colour" style="color: rgb(102,102,102);"><span class="x_-71738144font" style="font-family: Arial, Helvetica, sans-serif;"><span class="x_-71738144size" style="font-size: 13.3333px;">this is a hidden
                          folder.<span> </span></span></span></span>"</span></span></span><br>
            </div>
            <div> <br>
            </div>
            <div>During the atomsInstall process, the module zip file
              will be downloaded in the
              SCI\contrib\module_name\module_name.zip (or the SCIHOME
              atoms) and extract it. <br>
            </div>
            <div><br>
            </div>
            <div>In this stage, for windows and linux, it will be only
              one directory in SCI\contrib\module_name, namely
              module_name,</div>
          </div>
        </div>
      </blockquote>
    </blockquote>
    <p>The packaging rules do not impose that the package root dir has
      the name "module_name". For example latest scicv has root dir
      "scicv-0.4".<br>
    </p>
    <p> If the zip or tar.gz contains more than one directory (by
      accident, or else) then it can break atomsExtract, on every
      platform. The atomsInstall process should end when such an
      incoherence is detected. <br>
    </p>
    <p>In the meantime (before the proposed above fix), to avoid
      repackaging all OSX zip packages it would be simpler to use the -x
      flag of unzip, e.g. like this<br>
    </p>
    <p>unzip IPCV-4.1-MacOS-bin.zip -x __MACOSX/*<br>
    </p>
    <p><br>
          elseif regexp(archive_in,"/\.zip$/","o") <> [] then<br>
      <br>
              if getos() == "Windows" then<br>
                  extract_cmd = """" +
      getshortpathname(pathconvert(SCI+"/tools/zip/unzip.exe",%F)) +
      """";<br>
              else<br>
                  extract_cmd = "unzip";<br>
              end<br>
      <br>
              extract_cmd = extract_cmd + " -q -o """ + archive_in + """
      -d """ + pathconvert(dir_out,%F) +"""";<br>
              <br>
      <b>        if getos() == "Darwin"</b><b><br>
      </b><b>            extract_cmd = extract_cmd + " -x __MACOSX/*"</b><b><br>
      </b><b>        end</b><br>
      <br>
          end<br>
      <br>
          [rep,stat,err] = unix_g(extract_cmd);<br>
    </p>
    <blockquote>
      <blockquote>
        <div dir="ltr">
          <div style="font-family: Verdana, Arial, Helvetica, sans-serif;font-size: 10.0pt;">
            <div> and it will be renamed to version number, such as 1.0,
              and the module installation would be successful. <br>
            </div>
            <div><br>
            </div>
            <div>In Mac, it will have extra __MACOSX folder (unless the
              module packager manually remove it) and it will cause the
              system to detect this folder as the newly created module,
              and rename this to the version number, which the actual
              folder module_name, will remained as it is and gives error
              during module loading.<br>
            </div>
            <div> <br>
            </div>
            <div>While guideline could be given to the modules developer
              to remove the _MACOSX folder before releasing it, we could
              also add the following line in atomsExtract function to
              ensure the renaming function find the correct folder
              instead of __MACOSX folder. <br>
            </div>
            <div><br>
            </div>
            <div>atomsExtract.sci<br>
            </div>
            <div><br>
            </div>
            <div>    // Get the list of directories after the extraction
              <br>
            </div>
            <div>    //
=========================================================================<br>
            </div>
            <div><br>
            </div>
            <div>    dirs_after = atomsListDir(dir_out);<br>
            </div>
            <div><br>
            </div>
            <div><b>    dirs_after(dirs_after=='__MACOSX') = [];   //
                <-- extra line proposed to add</b><br>
            </div>
            <div>   <br>
            </div>
            <div>    // Get the name of the created directory<br>
            </div>
            <div>    //
=========================================================================<br>
            </div>
            <div><br>
            </div>
            <div>    dir_created = [];<br>
            </div>
            <div><br>
            </div>
            <div>    for j=1:size(dirs_after,"*")<br>
            </div>
            <div>        if find(dirs_after(j) == dirs_before) == []
              then<br>
            </div>
            <div>            dir_created = dirs_after(j);<br>
            </div>
            <div>            break;<br>
            </div>
            <div>        end<br>
            </div>
            <div>    end<br>
            </div>
            <div> <br>
            </div>
            <div><br>
            </div>
            <div>This shall solve the issue of module installation
              problem under MACOS.<br>
            </div>
            <div><br>
            </div>
            <div>Thanks.<br>
            </div>
            <div><br>
            </div>
            <div>Regards,<br>
              CL</div>
            <div><br>
            </div>
            <div><br>
            </div>
            <br>
            <div class="x_-71738144zmail_extra"><br>
              <div id="x_-71738144Zm-_Id_-Sgn1">---- On Tue, 05 Nov 2019 01:06:37
                +0800 <b> <a class="x_-71738144moz-txt-link-rfc2396E" href="mailto:stephane.mottelet@utc.fr" target="_blank"><stephane.mottelet@utc.fr></a></b> wrote
                ----<br>
              </div>
              <br>
              <blockquote style="border-left: 1.0px solid rgb(204,204,204);padding-left: 6.0px;margin: 0.0px 0.0px 0.0px 5.0px;">
                <div style="font-family: Arial;font-size: 14.0px;">
                  <p>There is a big difference in the inherited
                    environment when scilab is launched from the command
                    line and by clicking the icon.<br>
                    In the past I solved a problem with the LANG
                    variable<br>
                    <br>
                    <a target="_blank" href="https://antispam.utc.fr/proxy/2/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/antispam.utc.fr/proxy/2/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/codereview.scilab.org/#/c/20787/">https://codereview.scilab.org/#/c/20787/</a><br>
                    <a target="_blank" href="https://antispam.utc.fr/proxy/2/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/antispam.utc.fr/proxy/2/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/codereview.scilab.org/#/c/21069/">https://codereview.scilab.org/#/c/21069/</a><br>
                    <br>
                    the second one is still not merged in master but has
                    been included in 19 august build of Scilab 6.0.2 for
                    OSX (the one available from <a class="x_-71738144moz-txt-link-abbreviated" href="http://www.scilab.org" target="_blank">www.scilab.org</a>), since
                    it was really blocking for many users.<br>
                    <br>
                    Just to say that the regexp problem may be due to a
                    similar problem (locale, encoding, ...)<br>
                    <br>
                    S.<br>
                    <br>
                    Chin Luh Tan <<a target="_blank" href="mailto:chinluh.tan@bytecode-asia.com">chinluh.tan@bytecode-asia.com</a>>
                    a écrit :</p>
                  <blockquote style="border-left: 2.0px solid blue;margin-left: 2.0px;padding-left: 12.0px;">
                    <div style="font-family: Verdana, Arial, Helvetica, sans-serif;font-size: 10.0pt;">
                      <div>ok, i did:<br>
                      </div>
                      <div> <br>
                      </div>
                      <div>1. Del both previous scilab and the scilab
                        from your link installed just now to make it
                        clean<br>
                      </div>
                      <div>2. Totally remove the .Scilab folder under
                        home folder by using sudo rm -R .Scilab<br>
                      </div>
                      <div>3. Re-download the link <br>
                      </div>
                      <div>4. Double click and install (by dragging the
                        scilab icon to application folder)<br>
                      </div>
                      <div>5. run scilab from the app and type atomsList<br>
                      </div>
                      <div> <br>
                      </div>
                      <div>Same regexp error until i launch it from
                        terminal, and then it is ok. <br>
                      </div>
                      <div> <br>
                      </div>
                      <div>noted on the atoms issue for the modules with
                        gateway, will try to look into it.<br>
                      </div>
                      <div> <br>
                      </div>
                      <div>p/s: will continue any extra testing
                        tomorrow. <br>
                      </div>
                      <div> <br>
                      </div>
                      <div>rgds,<br>
                        CL</div>
                      <div> <br>
                      </div>
                      <div class="x_8808249zmail_extra">
                        <div> <br>
                        </div>
                        <div>---- On Tue, 05 Nov 2019 00:24:53 +0800 <b><<a target="_blank" href="mailto:stephane.mottelet@utc.fr">stephane.mottelet@utc.fr</a>></b>
                          wrote ----<br>
                        </div>
                        <div> <br>
                        </div>
                        <div><br>
                        </div>
                      </div>
                      <div> <br>
                      </div>
                    </div>
                  </blockquote>
                  <p><br>
                    <br>
                  </p>
                </div>
                _______________________________________________<br>
                users mailing list <br>
                <a class="x_-71738144moz-txt-link-abbreviated" href="mailto:users@lists.scilab.org" target="_blank">users@lists.scilab.org</a> <br>
                <a class="x_-71738144moz-txt-link-freetext" href="http://lists.scilab.org/mailman/listinfo/users" target="_blank">http://lists.scilab.org/mailman/listinfo/users</a> <br>
                <blockquote style="border-left: 1.0px solid rgb(204,204,204);padding-left: 6.0px;margin: 0.0px 0.0px 0.0px 5.0px;">
                  <div style="font-family: Arial;font-size: 14.0px;">
                    <p>Obviously, between points 3 and 4 I moved the
                      Scilab app from the archive in the Appplication
                      folder.<br>
                      <br>
                      <a target="_blank" href="mailto:stephane.mottelet@utc.fr">stephane.mottelet@utc.fr</a>
                      a écrit :</p>
                    <blockquote style="border-left: 2.0px solid blue;margin-left: 2.0px;padding-left: 12.0px;">
                      <p>Hello,<br>
                        <br>
                        I don't have the regexp error. Here is my
                        complete workflow:<br>
                        <br>
                        1 - Delete the eventual previous Sciab 6.0.2 I
                        had in the /Applications/ folder <br>
                        2 - Delete my .Scilab folder<br>
                        3 - extract the .dmg I downloaded from <a target="_blank" href="https://antispam.utc.fr/proxy/2/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/antispam.utc.fr/proxy/2/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/antispam.utc.fr/proxy/1/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/www.utc.fr/~mottelet/scilab/download/6.0.2/scilab-6.0.2-x86_64-2019-11-04.dmg">http://www.utc.fr/~mottelet/scilab/download/6.0.2/scilab-6.0.2-x86_64-2019-11-04.dmg</a><br>
                        4 - double click the Scilab icon (with first
                        launch usual but annoying details...)<br>
                        5 - click the ATOMS gui icon or type atomsList
                        at Scilab prompt<br>
                        <br>
                        Concerning the problem with IPCV (and maybe
                        other packages with gateways, I only tested
                        IPCV), I did not address it in the above
                        archive. I only modified the scilab script (I
                        will create a commit on codereview.scilab.org)
                        and removed the libcurl.dylib that was shipped
                        in lib/thirdparty folder.<br>
                        <br>
                        Best,<br>
                        <br>
                        S.</p>
                      <p>Chin Luh Tan <<a target="_blank" href="mailto:chinluh.tan@bytecode-asia.com">chinluh.tan@bytecode-asia.com</a>>
                        a écrit :<br>
                      </p>
                      <blockquote style="border-left: 2.0px solid blue;margin-left: 2.0px;padding-left: 12.0px;">
                        <div style="font-family: Verdana, Arial, Helvetica, sans-serif;font-size: 10.0pt;">
                          <div>Hi, <br>
                          </div>
                          <div> <br>
                          </div>
                          <div>from my end:<br>
                          </div>
                          <div> <br>
                          </div>
                          <div>1. The warning for the 10.15 gone. <br>
                          </div>
                          <div>2. First launch from the app still give
                            the regexp error when running atomsList, but
                            after running one time from terminal and get
                            it run successfully, I could run it from the
                            app as after all. <br>
                          </div>
                          <div>3. atomsInstall for the module with
                            gateway folder still extracted to 2 separate
                            folders which need to be manually move in
                            order for it to run. No issue for macros
                            only module. <br>
                          </div>
                          <div> <br>
                          </div>
                          <div>Thanks for the great effort. Is is
                            possible to share the compilation steps? <br>
                          </div>
                          <div> <br>
                          </div>
                          <div>rgds,<br>
                          </div>
                          <div>CL<br>
                          </div>
                          <div> <br>
                          </div>
                          <div class="x_576295042zmail_extra">
                            <div> <br>
                            </div>
                            <div>---- On Mon, 04 Nov 2019 22:40:20 +0800
                              <b><<a target="_blank" href="mailto:stephane.mottelet@utc.fr">stephane.mottelet@utc.fr</a>></b>
                              wrote ----<br>
                            </div>
                            <div> <br>
                            </div>
                            <blockquote style="border-left: 1.0px solid rgb(204,204,204);padding-left: 6.0px;margin: 0.0px 0.0px 0.0px 5.0px;">
                              <div style="font-family: Arial;font-size: 14.0px;">
                                <p>Did you test the Atoms stuff ?<br>
                                  <br>
                                  Heinz Nabielek <<a target="_blank" href="mailto:heinznabielek@me.com">heinznabielek@me.com</a>>
                                  a écrit :</p>
                                <blockquote style="border-left: 2.0px solid blue;margin-left: 2.0px;padding-left: 12.0px;">
                                  <p>On 04.11.2019, at 14:55, <a target="_blank" href="mailto:stephane.mottelet@utc.fr">stephane.mottelet@utc.fr</a>
                                    wrote:<br>
                                  </p>
                                  <blockquote style="border-left: 2.0px solid blue;margin-left: 2.0px;padding-left: 12.0px;">
                                    <p>Thanks Samuel. So the regexp
                                      error can eventually have the same
                                      cause (libcurl version mismatch).
                                      I have packaged a scilab-6.0.2
                                      without these libraries (and
                                      removing the 10.15 warning) for
                                      OSX users at the following URL:<br>
                                      <br>
                                      <a target="_blank" href="https://antispam.utc.fr/proxy/2/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/antispam.utc.fr/proxy/2/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/antispam.utc.fr/proxy/2/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/antispam.utc.fr/proxy/2/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/antispam.utc.fr/proxy/2/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/antispam.utc.fr/proxy/1/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/www.utc.fr/~mottelet/scilab/download/6.0.2/scilab-6.0.2-x86_64-2019-11-04.dmg">https://antispam.utc.fr/proxy/1/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/www.utc.fr/~mottelet/scilab/download/6.0.2/scilab-6.0.2-x86_64-2019-11-04.dmg</a><br>
                                      <br>
                                      CL, Heinz, Willi can you test it ?</p>
                                  </blockquote>
                                  <div>Works to perfection and without
                                    this funny warning.<br>
                                  </div>
                                  <div> <br>
                                  </div>
                                  <div> <br>
                                  </div>
                                  <blockquote style="border-left: 2.0px solid blue;margin-left: 2.0px;padding-left: 12.0px;">
                                    <p>I recommend temporary
                                      renaming/moving your
                                      .Scilab/scilab-6.0.2 directory
                                      before testing<br>
                                    </p>
                                  </blockquote>
                                  <div>Thanks. Very helpful. Great
                                    suggestion. I would not have thought
                                    of it…..<br>
                                  </div>
                                  <div> <br>
                                  </div>
                                  <div>Thanks for your dedication to
                                    this work.Heinz<br>
                                  </div>
                                </blockquote>
                                <p><br>
                                   </p>
                              </div>
                              <div>_______________________________________________<br>
                              </div>
                              <div>users mailing list<br>
                              </div>
                              <div><a target="_blank" href="mailto:users@lists.scilab.org">users@lists.scilab.org</a><br>
                              </div>
                              <div><a target="_blank" href="https://antispam.utc.fr/proxy/2/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/antispam.utc.fr/proxy/2/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/antispam.utc.fr/proxy/1/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/lists.scilab.org/mailman/listinfo/users">http://lists.scilab.org/mailman/listinfo/users</a><br>
                              </div>
                            </blockquote>
                          </div>
                          <div> <br>
                          </div>
                        </div>
                      </blockquote>
                      <p><br>
                         </p>
                    </blockquote>
                    <p><br>
                       </p>
                  </div>
                  <div>_______________________________________________<br>
                  </div>
                  <div>users mailing list<br>
                  </div>
                  <div><a target="_blank" href="mailto:users@lists.scilab.org">users@lists.scilab.org</a><br>
                  </div>
                  <div><a target="_blank" href="https://antispam.utc.fr/proxy/2/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/antispam.utc.fr/proxy/1/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/lists.scilab.org/mailman/listinfo/users">http://lists.scilab.org/mailman/listinfo/users</a><br>
                  </div>
                </blockquote>
              </blockquote>
            </div>
            <div><br>
            </div>
          </div>
          <br>
          <span>_______________________________________________</span><br>
          <span>users mailing list</span><br>
          <span><a class="x_-71738144moz-txt-link-abbreviated" href="mailto:users@lists.scilab.org" target="_blank">users@lists.scilab.org</a></span><br>
          <span><a class="x_-71738144moz-txt-link-freetext" href="https://antispam.utc.fr/proxy/1/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/lists.scilab.org/mailman/listinfo/users" target="_blank">https://antispam.utc.fr/proxy/1/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/lists.scilab.org/mailman/listinfo/users</a></span><br>
        </div>
      </blockquote>
      <br>
      <fieldset class="x_-71738144mimeAttachmentHeader"></fieldset>
      <pre class="x_-71738144moz-quote-pre">_______________________________________________
users mailing list
<a class="x_-71738144moz-txt-link-abbreviated" href="mailto:users@lists.scilab.org" target="_blank">users@lists.scilab.org</a>
<a class="x_-71738144moz-txt-link-freetext" href="https://antispam.utc.fr/proxy/1/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/lists.scilab.org/mailman/listinfo/users" target="_blank">https://antispam.utc.fr/proxy/1/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/lists.scilab.org/mailman/listinfo/users</a>
</pre>
    </blockquote>
    <pre class="x_-71738144moz-signature">-- 
Stéphane Mottelet
Ingénieur de recherche
EA 4297 Transformations Intégrées de la Matière Renouvelable
Département Génie des Procédés Industriels
Sorbonne Universités - Université de Technologie de Compiègne
CS 60319, 60203 Compiègne cedex
Tel : +33(0)344234688
<a class="x_-71738144moz-txt-link-freetext" href="http://www.utc.fr/~mottelet" target="_blank">http://www.utc.fr/~mottelet</a>
</pre>
  </div>

_______________________________________________
<br>users mailing list
<br>users@lists.scilab.org
<br>http://lists.scilab.org/mailman/listinfo/users
<br></blockquote></div></div></div>
<br></body></html>