[macports-ports] branch master updated: wxMaxima: update to 18.02.0 & development subport

Ryan Schmidt ryandesign at macports.org
Sat Jul 7 07:17:00 UTC 2018


On Jun 28, 2018, at 12:47, tomio-arisaka wrote:

> Perry E. Metzger (pmetzger) pushed a commit to branch master
> in repository macports-ports.
> 
> 
> https://github.com/macports/macports-ports/commit/f564833fda44e715f61fe9c5e34e521a7ddc1882
> 
> The following commit(s) were added to refs/heads/master by this push:
> 
>      new f564833  wxMaxima: update to 18.02.0 & development subport
> 
> f564833 is described below
> 
> 
> commit f564833fda44e715f61fe9c5e34e521a7ddc1882
> 
> Author: tomio-arisaka
> AuthorDate: Thu Jun 28 14:57:45 2018 +0900
> 
>     wxMaxima: update to 18.02.0 & development subport
>     
>     * Update wxMaxima from version 15.04.0 to 18.02.0.
>     * Change the value of homepage to 'http://andrejv.github.io/wxmaxima/'.
>     * Use 'cmake' instead of 'autoconf' because current version of wxMaxima
>       does not support 'autoconf' any more.
>     * Add patch to avoid an error when launching.
>     * Add 'wx32' variant to be able to choose wxWidgets-3.1 instead of 3.0.
>     * Add 'wxMaxima-devel' subport to be able to get a development version.
>     * Closes: https://trac.macports.org/ticket/53732
> 
> ---
>  math/wxMaxima/Portfile                             | 153 ++++++++++++++-------
>  .../files/patch-devel-src_Dirstructure.cpp.diff    |  15 ++
>  .../wxMaxima/files/patch-src_Dirstructure.cpp.diff |  37 +++++
>  3 files changed, 154 insertions(+), 51 deletions(-)
> 

As was discussed in the PR, the diff is hard to read because whitespace changes were made in the same commit as functional changes. They should have been done as separate commits. That should have been fixed before the PR was merged.


> +version             18.02.0

This line should go away, since the github.setup line later on already provides this information.


> +subport wxMaxima-devel {
> +    conflicts       wxMaxima
> +    long_description ${description}: \
> +                    Provides the development version, which is typically updated every day.

Is that useful to mention? Are you really planning to update this port every day?


> +    livecheck.type  none
>  }

Is there a particular reason why we don't want livecheck to work in this subport?


> +if {${subport} eq ${name}} {
> +    livecheck.regex Version-(\[a-z0-9.\]+)${extract.suffix}
>  }

It should not be necessary to override the entire livecheck.regex. Perhaps you meant:

github.livecheck.regex {([a-z0-9.]+)}


> +depends_build       port:cmake

Ports that build with cmake should usually use the cmake 1.1 portgroup. It would simplify the portfile, removing the need to specify the dependency or what you're doing in the configure or build phases. Is there a reason the portgroup was not used here? If there is a valid reason, then at least this dependency should be changed so that cmake-devel could also satisfy it:

depends_build path:bin/cmake:cmake


> +depends_run         bin:maxima:maxima

This would allow a maxima binary installed outside of MacPorts to satisfy the dependency. Is there a reason why we want to allow that? Usually we don't want to do that. To fix this to allow only MacPorts-installed copies to satisfy the dependency, change it to:

depends:run path:bin/maxima:maxima


> +destroot {
> +    xinstall -m 755 -d ${destroot}${applications_dir}
> +    file copy ${worksrcpath}/build/wxMaxima.app ${destroot}${applications_dir}
> +}

It is not necessary to create the applications directory, or other common directories mentioned in "man porthier". MacPorts does it for you.


> +notes "
> +    Be careful: \n\
> +    If you want to use wxMaxima with default setting, \n\
> +    you should enter the command \n\
> +    \"open -a ${applications_dir}/wxMaxima.app\" \n\
> +    on Terminal.app in order to launch wxMaxima. \n\
> +    Because you must let wxMaxima know the path to software \n\
> +    installed with MacPorts. \n\n\
> +    On the other hand, \n\
> +    when you launch directly wxMaxima on the Finder, \n\
> +    the path to maxima (e.g. \"${prefix}/bin/maxima\") is automatically set \n\
> +    on the configuration dialog. \n\
> +    But you should enter the maxima expression \n\
> +    gnuplot_command:\"${prefix}/bin/gnuplot\"\$ \n\
> +    in order to use gnuplot. \n\n\
> +    Some configuration files are automatically created by wxMaxima. \n\
> +    You can enter the command \n\
> +    \"find \$HOME/Library -name '*wxMaxima*'\" \n\
> +    on Terminal.app in order to find them.
> +"

Please reexamine the formatting (and wording) of these notes. We want MacPorts to be able to wrap the notes to the user's terminal width. It can only do this if you do not insert hard newlines into the middle of sentences. For convenience you can put a single line of text on multiple lines of the Portfile by using the backslash line continuation. So for example, you want to write...


If you want to use wxMaxima with default setting,\
you should enter the command


...so that a newline will not actually be printed after the comma (unless that's the width of the terminal). Don't put a space before the backslash, otherwise there will be an undesirable double space printed.


In those places where you do want a hard newline, it is simpler to use e.g.:

notes "line 1
line 2"

rather than:

notes "line 1\n\
line 2"




More information about the macports-dev mailing list