Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses

[Solved]: cpan fails when MKS installed on Windows

by prashantktyagi (Scribe)
on Apr 06, 2013 at 08:16 UTC ( #1027265=perlquestion: print w/replies, xml ) Need Help??
prashantktyagi has asked for the wisdom of the Perl Monks concerning the following question:

Hi Monks,

I know this is not specific to Perl, But I hope to find some suggestion from fellow monks..

I have MKS installed on my Win7 machine. When I use cpan on cmd prompt, MKS converts windows path which cause cpan to fail to locate perl.exe. For example:
C:Perl64perlbinperl.exe: not found
Is there anyway I can unset MKS shell on Windows cmd prompt. I need MKS installed on my machine to run my application. Thanks

update: I am using Perl v5.16.3 MSWin32-x64-multi-thread
update2: Thanks a lot Monks!!!. unset shell variable on cmd solved the issue.
set shell=

Replies are listed 'Best First'.
Re: cpan fails when MKS installed on Windows
by derby (Abbot) on Apr 06, 2013 at 12:07 UTC
    Is that MKS Toolkit. If so, I'm surprised they are still around. I thought for certain cygwin would be the end of them. Out of curiosity what value does MKS Toolkit provide that cygwin does not (or for that matter running linux in VirtualBox).
      Hi derby,
      I agree with you. But my organization has MKS Toolkit license and they are stick with it.
      I will randomly guess that MKS Toolkit along with Interix were written using Native API and both had full access to the Windows source code from Microsoft (read the story about Mainsoft), therefore both are faster and cleaner than Cygwin which was written on top of Win32 without detailed knowledge of Windows NT.
Re: cpan fails when MKS installed on Windows
by Anonymous Monk on Apr 06, 2013 at 08:28 UTC

    Well, if "MKS" is an alternate shell, and it runs when you type "cmd.exe", there is nothing perl related you can do to fix the problem

    cmd.exe should always start cmd.exe, if it doesn't, uninstall whatever is posing as cmd.exe

    OTOH, you might be able to (but it probably won't work), to recompile perl under MKS... there is such a thing as "mksperl"

Re: cpan fails when MKS installed on Windows
by marto (Bishop) on Apr 06, 2013 at 09:46 UTC

    If you've read their documentation and still can't find a way to prevent this I suggest you contact their support.

      Thanks!!! anyway I have already contacted MKS support.
      Just thought might be someone faced the same issue.
Re: cpan fails when MKS installed on Windows
by BrowserUk (Pope) on Apr 06, 2013 at 11:41 UTC

    Why not just start the real cmd.exe when running cpan?

    With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
    Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
    "Science is about questioning the status quo. Questioning authority".
    In the absence of evidence, opinion is indistinguishable from prejudice.
      Hi, I am already running windows cmd.exe but I guess MKS runs its own config scripts at cmd.exe startup or windows startup somewhere (not sure) .
      That is why I am searching for which script & where to turn off ?
        I guess MKS runs its own config scripts at cmd.exe startup or windows startup somewhere (not sure)

        That's an abominable state of affairs !! Is perl itself crippled by this affliction ?
        For example, does perl -e "print $^X" output C:Perl64perlbinperl.exe, or is it just the cpan shell that suffers ?

        If the problem is limited to the cpan shell you might be able to work around the problem by simply not using it.
        I *never* use the cpan shell - in fact I won't even use (or any of its variants) unless the module I'm trying to install has an appallingly long list of pre-requisites.

Re: [Solved]: cpan fails when MKS installed on Windows
by Jim (Curate) on Jun 12, 2013 at 05:41 UTC


        set TERM=ansi

    …or some such.

    But as you've already learned, your problem is solved with just…

        set SHELL=

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://1027265]
Approved by bulk88
and monks are getting baked in the sun...

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (5)
As of 2017-05-25 03:57 GMT
Find Nodes?
    Voting Booth?