The result of "sudo which javac" is "/usr/bin/javac". I think there is no
problem in javac's path.
As a temporary measure, I changed JDK from Zulu to Oracle and now it works
well.
But I've set Zulu JDK path in setup.py file before type "sudo python
setup.py install" command...so still I don't know what is the cause.


2019년 1월 8일 (화) 오후 10:44, Michael McCandless <luc...@mikemccandless.com>님이
작성:

> Likely the "sudo" env does not have javac on its PATH?
>
> Try "sudo which javac" (if you use bash, or any shell that has the "which"
> command).
>
> Mike McCandless
>
> http://blog.mikemccandless.com
>
>
> On Tue, Jan 8, 2019 at 5:51 AM NDelt <blackj0...@gmail.com> wrote:
>
> > I'm trying to install PyLucene on Ubuntu Linux and WSL, and my
> development
> > environment is Java 8 and Python 3.6.7.
> >
> > *python setup.py build* was successful, but I got an error after input
> > *sudo
> > python setup.py install *command.
> >
> > Error message:
> > *Applied shared mode monkeypatch to: <module 'setuptools' from
> > '/usr/lib/python3/dist-packages/setuptools/__init__.py'>*
> > *Traceback (most recent call last):*
> > *    File "setup.py", line 389, in main process = Popen(args,
> stderr=PIPE)
> >  *
> > *    File "/usr/lib/python3.6/subprocess.py", line 709, in __init__
> > restore_signals, start_new_session)*
> > *    File "/usr/lib/python3.6/subprocess.py", line 1344, in
> _execute_child
> > raise child_exception_type(errno_num, err_msg, err_filename)*
> > *    FileNotFoundError: [Errno 2] No such file or directory: 'javac':
> > 'javac'*
> >
> > *During handling of the above exception, another exception occurred:*
> >
> > *Traceback (most recent call last):*
> > *    File "setup.py", line 449, in <module> main('--debug' in sys.argv)*
> > *    File "setup.py", line 391, in main raise sys.exc_info()[0]("%s: %s"
> > %(sys.exc_info()[1], args))*
> > *    FileNotFoundError: [Errno 2] No such file or directory: 'javac':
> > 'javac': ['javac', '-d', 'jcc3/classes',
> > 'java/org/apache/jcc/PythonVM.java',
> > 'java/org/apache/jcc/PythonException.java']*
> >
> > But I already installed JDK 8u192 so *java -version*, *javac -version*
> > command works very well.
> >
> > *$ java -version*
> > *openjdk version "1.8.0_192"*
> > *OpenJDK Runtime Environment (Zulu 8.33.0.1-linux64) (build
> 1.8.0_192-b01)*
> > *OpenJDK 64-Bit Server VM (Zulu 8.33.0.1-linux64) (build 25.192-b01,
> mixed
> > mode)*
> >
> > *$ javac -version*
> > *javac 1.8.0_192*
> >
> > How to I fix this problem?
> >
>

Reply via email to