Hi all,

I'm trying to create a package for python-jcc:
https://pypi.org/project/JCC/

I've overcome a few hurdles, but am now stuck on a seemingly simple
question.

javadoc doesn't appear to be part of the openjdk or icedtea packages (I
think this unusual?).

Could anyone suggest the canonical way to get javadoc installed on Guix?

For context my draft attempt at packaging JCC with build error below.  I
know it finds the correct JDK location because it passes the find JDK
test.  Also I can show at the command line that javadoc doesn't exist by
using -K to keep the build and setting the 'environment_variables'
script in /tmp.

Finally installing openjdk or icedtea into a profile has no javadoc
accessible on the profile PATH.

Any ideas?


Thanks,
Phil.

(define-public python-jcc
  (package
    (name "python-jcc")
    (version "3.8")
    (source
     (origin
       (method url-fetch)
       (uri (pypi-uri "JCC" version))
       (sha256
        (base32
         "1wbyd2srj89116j0d7dnkw8ricli8r1h2pr7nj1kq97miwdh6l96"))))
    (build-system python-build-system)
    (native-inputs
     `(("openjdk" ,openjdk14)))
    (arguments
     `(#:phases
       (modify-phases %standard-phases
         (add-before 'build 'set-JCC_JDK
           ;; should find this programatically?
           (lambda _ (setenv "JCC_JDK" 
"/gnu/store/s2w6bfrc3nqghpqpcryz4l5h86gsvqvz-openjdk-14.0") #t)))))
    (home-page "https://lucene.apache.org/pylucene/jcc/index.html";)
    (synopsis
     "a C++ code generator for calling Java from C++/Python")
    (description
     "a C++ code generator for calling Java from C++/Python")
    (license #f)))


starting phase `set-JCC_JDK'
phase `set-JCC_JDK' succeeded after 0.0 seconds
starting phase `build'
running "python setup.py" with command "build" and parameters ()
Applied shared mode monkeypatch to: <module 'setuptools' from 
'/gnu/store/q9rm8h9imazsq2c4qiv2yjpvlvliywqb-python-3.8.2/lib/python3.8/site-packages/setuptools/__init__.py'>
Traceback (most recent call last):
  File "setup.py", line 413, in main
    process = Popen(args, stderr=PIPE)
  File 
"/gnu/store/q9rm8h9imazsq2c4qiv2yjpvlvliywqb-python-3.8.2/lib/python3.8/subprocess.py",
 line 854, in __init__
    self._execute_child(args, executable, preexec_fn, close_fds,
  File 
"/gnu/store/q9rm8h9imazsq2c4qiv2yjpvlvliywqb-python-3.8.2/lib/python3.8/subprocess.py",
 line 1702, in _execute_child
    raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: 'javadoc'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "setup.py", line 461, in <module>
    main('--debug' in sys.argv)
  File "setup.py", line 415, in main
    raise sys.exc_info()[0]("%s: %s" %(sys.exc_info()[1], args))
FileNotFoundError: [Errno 2] No such file or directory: 'javadoc': ['javadoc', 
'-d', 'javadoc', '-sourcepath', 'java', 'org.apache.jcc']
command "python" "-c" "import setuptools, 
tokenize;__file__='setup.py';f=getattr(tokenize, 'open', 
open)(__file__);code=f.read().replace('\\r\\n', 
'\\n');f.close();exec(compile(code, __file__, 'exec'))" "build" failed with 
status 1
builder for `/gnu/store/hshh3jkfdzv1lv8yqvvb4gbxza7ygv46-python-jcc-3.8.drv' 
failed with exit code 1
build of /gnu/store/hshh3jkfdzv1lv8yqvvb4gbxza7ygv46-python-jcc-3.8.drv failed

Reply via email to