unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#17477: flymake-mode looks at wrong PHP binary
@ 2014-05-12 16:26 Joe Borġ
  2014-05-12 17:15 ` Leo Liu
  0 siblings, 1 reply; 12+ messages in thread
From: Joe Borġ @ 2014-05-12 16:26 UTC (permalink / raw)
  To: 17477

[-- Attachment #1: Type: text/plain, Size: 330 bytes --]

When executing M+x flymake mode, I get

Flymake: Configuration error has occured while running (/usr/bin/php -f
viewrequest_flymake.php -l). Flymake will be switched OFF

My php is in /usr/local/bin/php

This was installed using package-install, with marmalade repository set.

Regards,
Joseph David Borġ
josephb.org

[-- Attachment #2: Type: text/html, Size: 565 bytes --]

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

* bug#17477: flymake-mode looks at wrong PHP binary
  2014-05-12 16:26 bug#17477: flymake-mode looks at wrong PHP binary Joe Borġ
@ 2014-05-12 17:15 ` Leo Liu
  2014-05-12 17:16   ` Joe Borġ
  0 siblings, 1 reply; 12+ messages in thread
From: Leo Liu @ 2014-05-12 17:15 UTC (permalink / raw)
  To: Joe Borġ; +Cc: 17477

On 2014-05-13 00:26 +0800, Joe Borġ wrote:
> When executing M+x flymake mode, I get
>
> Flymake: Configuration error has occured while running (/usr/bin/php -f
> viewrequest_flymake.php -l). Flymake will be switched OFF
>
> My php is in /usr/local/bin/php
>
> This was installed using package-install, with marmalade repository set.

Could it be that you also have /usr/bin/php? I see flymake-php-init has
no hardcoded path.

Leo





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

* bug#17477: flymake-mode looks at wrong PHP binary
  2014-05-12 17:15 ` Leo Liu
@ 2014-05-12 17:16   ` Joe Borġ
  2014-05-12 19:08     ` Glenn Morris
  0 siblings, 1 reply; 12+ messages in thread
From: Joe Borġ @ 2014-05-12 17:16 UTC (permalink / raw)
  To: Leo Liu; +Cc: 17477

[-- Attachment #1: Type: text/plain, Size: 581 bytes --]

Hi Leo,

No, only where stated.

Thanks
On 12 May 2014 18:15, "Leo Liu" <sdl.web@gmail.com> wrote:

> On 2014-05-13 00:26 +0800, Joe Borġ wrote:
> > When executing M+x flymake mode, I get
> >
> > Flymake: Configuration error has occured while running (/usr/bin/php -f
> > viewrequest_flymake.php -l). Flymake will be switched OFF
> >
> > My php is in /usr/local/bin/php
> >
> > This was installed using package-install, with marmalade repository set.
>
> Could it be that you also have /usr/bin/php? I see flymake-php-init has
> no hardcoded path.
>
> Leo
>

[-- Attachment #2: Type: text/html, Size: 903 bytes --]

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

* bug#17477: flymake-mode looks at wrong PHP binary
  2014-05-12 17:16   ` Joe Borġ
@ 2014-05-12 19:08     ` Glenn Morris
  2014-05-12 19:28       ` Joe Borġ
  0 siblings, 1 reply; 12+ messages in thread
From: Glenn Morris @ 2014-05-12 19:08 UTC (permalink / raw)
  To: Joe Borġ; +Cc: Leo Liu, 17477

Joe Borġ wrote:

>> > When executing M+x flymake mode, I get
>> >
>> > Flymake: Configuration error has occured while running (/usr/bin/php -f
>> > viewrequest_flymake.php -l). Flymake will be switched OFF
>> >
>> > My php is in /usr/local/bin/php

I don't know what to tell you.
flymake just calls "php".
It sure sounds like something thinks you have a /usr/bin/php.

>> > This was installed using package-install, with marmalade repository set.

Why is this necessary? flymake is part of Emacs. What did you install?
What version of Emacs is this?

Does this happen with emacs -Q?





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

* bug#17477: flymake-mode looks at wrong PHP binary
  2014-05-12 19:08     ` Glenn Morris
@ 2014-05-12 19:28       ` Joe Borġ
  2014-05-12 19:31         ` Glenn Morris
  0 siblings, 1 reply; 12+ messages in thread
From: Joe Borġ @ 2014-05-12 19:28 UTC (permalink / raw)
  To: Glenn Morris; +Cc: Leo Liu, 17477

[-- Attachment #1: Type: text/plain, Size: 891 bytes --]

I promise you there is no /usr/bin/php.

I installed flymake-php and want to turn it on.

Emacs 24.3.1 - I've not tried with -Q.



Regards,
Joseph David Borġ
josephb.org


On 12 May 2014 20:08, Glenn Morris <rgm@gnu.org> wrote:

> Joe Borġ wrote:
>
> >> > When executing M+x flymake mode, I get
> >> >
> >> > Flymake: Configuration error has occured while running (/usr/bin/php
> -f
> >> > viewrequest_flymake.php -l). Flymake will be switched OFF
> >> >
> >> > My php is in /usr/local/bin/php
>
> I don't know what to tell you.
> flymake just calls "php".
> It sure sounds like something thinks you have a /usr/bin/php.
>
> >> > This was installed using package-install, with marmalade repository
> set.
>
> Why is this necessary? flymake is part of Emacs. What did you install?
> What version of Emacs is this?
>
> Does this happen with emacs -Q?
>

[-- Attachment #2: Type: text/html, Size: 1498 bytes --]

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

* bug#17477: flymake-mode looks at wrong PHP binary
  2014-05-12 19:28       ` Joe Borġ
@ 2014-05-12 19:31         ` Glenn Morris
  2014-05-12 19:33           ` Joe Borġ
  0 siblings, 1 reply; 12+ messages in thread
From: Glenn Morris @ 2014-05-12 19:31 UTC (permalink / raw)
  To: Joe Borġ; +Cc: Leo Liu, 17477


Then my crystal ball says that you are using this

https://github.com/ejmr/php-mode/blob/master/php-mode.el

which is

1) not part of Emacs
2) broken in exactly the way you describe (default value of php-executable).

So you should report this to whoever maintains it.

(NB crystal ball comes with no warranty.)





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

* bug#17477: flymake-mode looks at wrong PHP binary
  2014-05-12 19:31         ` Glenn Morris
@ 2014-05-12 19:33           ` Joe Borġ
  2014-05-12 19:39             ` Glenn Morris
  0 siblings, 1 reply; 12+ messages in thread
From: Joe Borġ @ 2014-05-12 19:33 UTC (permalink / raw)
  To: Glenn Morris; +Cc: Leo Liu, 17477

[-- Attachment #1: Type: text/plain, Size: 556 bytes --]

Yes, you're right - but why does that effect flymake-php?  I ask so I can
try and fix it.



Regards,
Joseph David Borġ
josephb.org


On 12 May 2014 20:31, Glenn Morris <rgm@gnu.org> wrote:

>
> Then my crystal ball says that you are using this
>
> https://github.com/ejmr/php-mode/blob/master/php-mode.el
>
> which is
>
> 1) not part of Emacs
> 2) broken in exactly the way you describe (default value of
> php-executable).
>
> So you should report this to whoever maintains it.
>
> (NB crystal ball comes with no warranty.)
>

[-- Attachment #2: Type: text/html, Size: 1081 bytes --]

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

* bug#17477: flymake-mode looks at wrong PHP binary
  2014-05-12 19:33           ` Joe Borġ
@ 2014-05-12 19:39             ` Glenn Morris
  2014-05-13  5:59               ` Glenn Morris
  0 siblings, 1 reply; 12+ messages in thread
From: Glenn Morris @ 2014-05-12 19:39 UTC (permalink / raw)
  To: Joe Borġ; +Cc: Leo Liu, 17477

Joe Borġ wrote:

> Yes, you're right - but why does that effect flymake-php?  I ask so I can
> try and fix it.

Because they load flymake.el, then clobber its flymake-php-init function
with their own version, which is identical to the default version apart
from using "/usr/bin/php" (by default), thus breaking flymake.

Simply (setq php-executable "php") and it should work.

I assume they want to cater for cases where "php" is not installed as
"php"; if there are any.





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

* bug#17477: flymake-mode looks at wrong PHP binary
  2014-05-12 19:39             ` Glenn Morris
@ 2014-05-13  5:59               ` Glenn Morris
  2014-05-13  8:09                 ` Joe Borġ
  0 siblings, 1 reply; 12+ messages in thread
From: Glenn Morris @ 2014-05-13  5:59 UTC (permalink / raw)
  To: Joe Borġ; +Cc: Leo Liu, 17477


I'm going to close this because I don't think there is any bug in Emacs
here; but feel free to keep discussing it here if you like.

(If "php" is commonly installed as something other than "php", perhaps
flymake.el needs a flymake-php-program option, similar to the existing
flymake-xml-program. Likewise for "perl" and "texify".)





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

* bug#17477: flymake-mode looks at wrong PHP binary
  2014-05-13  5:59               ` Glenn Morris
@ 2014-05-13  8:09                 ` Joe Borġ
  2014-05-13 15:45                   ` Glenn Morris
  0 siblings, 1 reply; 12+ messages in thread
From: Joe Borġ @ 2014-05-13  8:09 UTC (permalink / raw)
  To: Glenn Morris; +Cc: Leo Liu, 17477

[-- Attachment #1: Type: text/plain, Size: 547 bytes --]

Thanks for your help.  I'm going to create a pull request with a fix for
them.



Regards,
Joseph David Borġ
josephb.org


On 13 May 2014 06:59, Glenn Morris <rgm@gnu.org> wrote:

>
> I'm going to close this because I don't think there is any bug in Emacs
> here; but feel free to keep discussing it here if you like.
>
> (If "php" is commonly installed as something other than "php", perhaps
> flymake.el needs a flymake-php-program option, similar to the existing
> flymake-xml-program. Likewise for "perl" and "texify".)
>

[-- Attachment #2: Type: text/html, Size: 1024 bytes --]

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

* bug#17477: flymake-mode looks at wrong PHP binary
  2014-05-13  8:09                 ` Joe Borġ
@ 2014-05-13 15:45                   ` Glenn Morris
  2014-05-13 15:56                     ` Joe Borġ
  0 siblings, 1 reply; 12+ messages in thread
From: Glenn Morris @ 2014-05-13 15:45 UTC (permalink / raw)
  To: Joe Borġ; +Cc: Leo Liu, 17477

Joe Borġ wrote:

> Thanks for your help.  I'm going to create a pull request with a fix for
> them.

Great! (AFAICS, just defaulting php-executable to "php" would be enough.)





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

* bug#17477: flymake-mode looks at wrong PHP binary
  2014-05-13 15:45                   ` Glenn Morris
@ 2014-05-13 15:56                     ` Joe Borġ
  0 siblings, 0 replies; 12+ messages in thread
From: Joe Borġ @ 2014-05-13 15:56 UTC (permalink / raw)
  To: Glenn Morris; +Cc: Leo Liu, 17477

[-- Attachment #1: Type: text/plain, Size: 410 bytes --]

Yes, that does work fine.  Just a bloody nuisance!  It should default to
`php` or `/usr/bin/env php`



Regards,
Joseph David Borġ
josephb.org


On 13 May 2014 16:45, Glenn Morris <rgm@gnu.org> wrote:

> Joe Borġ wrote:
>
> > Thanks for your help.  I'm going to create a pull request with a fix for
> > them.
>
> Great! (AFAICS, just defaulting php-executable to "php" would be enough.)
>

[-- Attachment #2: Type: text/html, Size: 875 bytes --]

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

end of thread, other threads:[~2014-05-13 15:56 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-05-12 16:26 bug#17477: flymake-mode looks at wrong PHP binary Joe Borġ
2014-05-12 17:15 ` Leo Liu
2014-05-12 17:16   ` Joe Borġ
2014-05-12 19:08     ` Glenn Morris
2014-05-12 19:28       ` Joe Borġ
2014-05-12 19:31         ` Glenn Morris
2014-05-12 19:33           ` Joe Borġ
2014-05-12 19:39             ` Glenn Morris
2014-05-13  5:59               ` Glenn Morris
2014-05-13  8:09                 ` Joe Borġ
2014-05-13 15:45                   ` Glenn Morris
2014-05-13 15:56                     ` Joe Borġ

Code repositories for project(s) associated with this public inbox

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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).