all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [PATCH] gnu: wxwidgets: enable extended regular expressions.
@ 2016-04-16 18:33 Danny Milosavljevic
  2016-04-30  1:47 ` Leo Famulari
  2016-05-23  4:15 ` [PATCH] gnu: wxwidgets: enable extended " Leo Famulari
  0 siblings, 2 replies; 6+ messages in thread
From: Danny Milosavljevic @ 2016-04-16 18:33 UTC (permalink / raw)
  To: guix-devel

Hi,

this patch enables extended regular expression support in wxwidgets. It's needed for kicad. 

I tried to test the other packages that depend on wxwidgets (wxmaxima and audacity) but even without the patch they are in various states of brokenness. See my bug reports on the problems. These are: audacity: local help files share/audacity/help/ not installed and crash in wxmaxima on Save As.

So it's not tested in wxmaxima and little tested in audacity. I think the risks are low anyway and it's likely that it will work. KiCAD works fine with it.

* gnu/packages/wxwidgets.scm (wxwidgets): enable extended regular expressions.
---
 b/gnu/packages/wxwidgets.scm |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/gnu/packages/wxwidgets.scm b/gnu/packages/wxwidgets.scm
index b49fb2f..65adfc1 100644
--- a/gnu/packages/wxwidgets.scm
+++ b/gnu/packages/wxwidgets.scm
@@ -61,7 +61,7 @@
      `(("pkg-config" ,pkg-config)))
     (arguments
      '(#:configure-flags
-       '("--with-regex=sys" "--with-libmspack" "--with-sdl")
+       '("--with-regex" "--with-libmspack" "--with-sdl")
        #:make-flags
        (list (string-append "LDFLAGS=-Wl,-rpath="
                             (assoc-ref %outputs "out") "/lib"))

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH] gnu: wxwidgets: enable extended regular expressions.
  2016-04-16 18:33 [PATCH] gnu: wxwidgets: enable extended regular expressions Danny Milosavljevic
@ 2016-04-30  1:47 ` Leo Famulari
  2016-05-07  5:00   ` [PATCH] gnu: wxwidgets: enable advanced (!) " Danny Milosavljevic
  2016-05-23  4:15 ` [PATCH] gnu: wxwidgets: enable extended " Leo Famulari
  1 sibling, 1 reply; 6+ messages in thread
From: Leo Famulari @ 2016-04-30  1:47 UTC (permalink / raw)
  To: Danny Milosavljevic; +Cc: guix-devel

On Sat, Apr 16, 2016 at 08:33:17PM +0200, Danny Milosavljevic wrote:
> Hi,
> 
> this patch enables extended regular expression support in wxwidgets. It's needed for kicad. 

That sounds great! I would love to offer KiCad in Guix.

>      (arguments
>       '(#:configure-flags
> -       '("--with-regex=sys" "--with-libmspack" "--with-sdl")
> +       '("--with-regex" "--with-libmspack" "--with-sdl")

Taylan, do you remember why you originally created the package with
--with-regex=sys? Do you think anything will break if make this change?

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] gnu: wxwidgets: enable advanced (!) regular expressions.
  2016-04-30  1:47 ` Leo Famulari
@ 2016-05-07  5:00   ` Danny Milosavljevic
  0 siblings, 0 replies; 6+ messages in thread
From: Danny Milosavljevic @ 2016-05-07  5:00 UTC (permalink / raw)
  To: Leo Famulari; +Cc: guix-devel

Hi,

some more docs about the so-called "advanced" regular expressions needed by KiCad and wxRegEx in general:

http://wxd.sourceforge.net/wxWidgets-2.5.3/docs/html/wx/wx_wxregex.html

The "advanced" regular expression features (on top of extended regular expressions) are:
- Escapes: \a \b \n \r etc have the usual C meaning (bell, backspace, newline, carriage return etc)
- Class Shorthands: \d is the same as [[:digit:]]
- positive lookahead
- negative lookahead

The places in KiCad 4.0.1 where they are used are:

./eeschema/class_netlist_object.cpp:static wxRegEx busLabelRe( wxT( "^([^[:space:]]+)(\\[[\\d]+\\.+[\\d]+\\])$" ), wxRE_ADVANCED );
./pcbnew/dialogs/dialog_fp_lib_table.cpp:        wxRegEx re( wxT( ".*?\\$\\{(.+?)\\}.*?" ), wxRE_ADVANCED );
./pcbnew/netlist_reader.cpp:    wxRegEx reOrcad( wxT( "(?i)[ ]*\\([ \t]+{+" ), wxRE_ADVANCED );
./pcbnew/netlist_reader.cpp:    wxRegEx reLegacy( wxT( "(?i)#[ \t]+EESchema[ \t]+Netlist[ \t]+" ), wxRE_ADVANCED );
./pcbnew/netlist_reader.cpp:    wxRegEx reKicad( wxT( "[ ]*\\(export[ ]+" ), wxRE_ADVANCED );

As you can see the "advanced" features are actually used in the eeschema class_netlist_object (trivially, just the shorthand) and in the netlist reader in two places (Escapes and some mysterious "(?i)" moniker - see http://www.regular-expressions.info/modifiers.html . Not sure whether that would be supported in POSIX extended regular expressions). As far as I can see the other places don't actually use the "advanced" features. Note that POSIX extended regular expressions are "almost an exact" subset of "advanced regular expressions", according to the docs.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] gnu: wxwidgets: enable extended regular expressions.
  2016-04-16 18:33 [PATCH] gnu: wxwidgets: enable extended regular expressions Danny Milosavljevic
  2016-04-30  1:47 ` Leo Famulari
@ 2016-05-23  4:15 ` Leo Famulari
  2016-06-01  5:57   ` [PATCH v2] gnu: wxwidgets: Enable support for their "advanced" " Danny Milosavljevic
  1 sibling, 1 reply; 6+ messages in thread
From: Leo Famulari @ 2016-05-23  4:15 UTC (permalink / raw)
  To: Danny Milosavljevic; +Cc: guix-devel

On Sat, Apr 16, 2016 at 08:33:17PM +0200, Danny Milosavljevic wrote:
> I tried to test the other packages that depend on wxwidgets (wxmaxima
> and audacity) but even without the patch they are in various states of
> brokenness. See my bug reports on the problems. These are: audacity:
> local help files share/audacity/help/ not installed and crash in
> wxmaxima on Save As.
> 
> So it's not tested in wxmaxima and little tested in audacity. I think
> the risks are low anyway and it's likely that it will work. KiCAD
> works fine with it.

wxMaxima and Audacity still run with this change. I think we should go
ahead and make the change, since there have been no objections so far.
But, this patch no longer applies.

Danny, can you recreate the patch on current master?

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [PATCH v2] gnu: wxwidgets: Enable support for their "advanced" regular expressions.
  2016-05-23  4:15 ` [PATCH] gnu: wxwidgets: enable extended " Leo Famulari
@ 2016-06-01  5:57   ` Danny Milosavljevic
  2016-06-03 20:24     ` Leo Famulari
  0 siblings, 1 reply; 6+ messages in thread
From: Danny Milosavljevic @ 2016-06-01  5:57 UTC (permalink / raw)
  To: guix-devel, Leo Famulari

From: Danny Milosavljevic <dannym+a@scratchpost.org>

* wxwidgets: Enable support for their "advanced" regular expressions.
             This is required by KiCad.
---
 gnu/packages/wxwidgets.scm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/gnu/packages/wxwidgets.scm b/gnu/packages/wxwidgets.scm
index 2c4a26a..3231e3d 100644
--- a/gnu/packages/wxwidgets.scm
+++ b/gnu/packages/wxwidgets.scm
@@ -63,7 +63,7 @@
      `(("pkg-config" ,pkg-config)))
     (arguments
      '(#:configure-flags
-       '("--with-regex=sys" "--with-libmspack"
+       '("--with-regex" "--with-libmspack"
          "--with-sdl"
          "--enable-webview"
          "--enable-webkit"

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH v2] gnu: wxwidgets: Enable support for their "advanced" regular expressions.
  2016-06-01  5:57   ` [PATCH v2] gnu: wxwidgets: Enable support for their "advanced" " Danny Milosavljevic
@ 2016-06-03 20:24     ` Leo Famulari
  0 siblings, 0 replies; 6+ messages in thread
From: Leo Famulari @ 2016-06-03 20:24 UTC (permalink / raw)
  To: Danny Milosavljevic; +Cc: guix-devel

On Wed, Jun 01, 2016 at 07:57:11AM +0200, Danny Milosavljevic wrote:
> From: Danny Milosavljevic <dannym+a@scratchpost.org>
> 
> * wxwidgets: Enable support for their "advanced" regular expressions.
>              This is required by KiCad.

Thank you!

Applied as b37b854e2d6 with some more detail in the commit message.

> ---
>  gnu/packages/wxwidgets.scm | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/gnu/packages/wxwidgets.scm b/gnu/packages/wxwidgets.scm
> index 2c4a26a..3231e3d 100644
> --- a/gnu/packages/wxwidgets.scm
> +++ b/gnu/packages/wxwidgets.scm
> @@ -63,7 +63,7 @@
>       `(("pkg-config" ,pkg-config)))
>      (arguments
>       '(#:configure-flags
> -       '("--with-regex=sys" "--with-libmspack"
> +       '("--with-regex" "--with-libmspack"
>           "--with-sdl"
>           "--enable-webview"
>           "--enable-webkit"

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2016-06-03 20:25 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-04-16 18:33 [PATCH] gnu: wxwidgets: enable extended regular expressions Danny Milosavljevic
2016-04-30  1:47 ` Leo Famulari
2016-05-07  5:00   ` [PATCH] gnu: wxwidgets: enable advanced (!) " Danny Milosavljevic
2016-05-23  4:15 ` [PATCH] gnu: wxwidgets: enable extended " Leo Famulari
2016-06-01  5:57   ` [PATCH v2] gnu: wxwidgets: Enable support for their "advanced" " Danny Milosavljevic
2016-06-03 20:24     ` Leo Famulari

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.