tech-pkg archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: doxygen build failing with python confusion

On Fri, 24 Mar 2023 19:55:51 -0400
Greg Troxel <> wrote:

> doxygen is failing with:
>   [ 15%] Generating ../generated_src/configvalues.h
>   cd
> /tmp/work/devel/doxygen/work/doxygen-1.9.6/cmake-pkgsrc-build/src &&
> /usr/pkg/bin/python2.7
> /tmp/work/devel/doxygen/work/doxygen-1.9.6/src/ -maph
> /tmp/work/devel/doxygen/work/doxygen-1.9.6/src/config.xml >
> /tmp/work/devel/doxygen/work/doxygen-1.9.6/cmake-pkgsrc-build/generated_src/configvalues.h
>   No module named pyexpat
> and the bug is that cmake is finding 2.7 (which is installed) instead
> of the python3.10 which is the chosen version from including python
> for build.  I am not particularly good at at cmake and out of time
> today, so I'm mentioning it here in case any one knows how to fix it
> easily. Probably it's adding -Dpython_I_want_is_3.10 or somethig to
> the cmake invocation :-)

Hi Greg and Thomas, as Thomas mentions in his mail there is
patch-Modules_FindPythonInterp.cmake that checks if PYVERSSUFFIX is
defined and uses that as a version number. PYVERSSUFFIX is passed to
cmake in lang/python/ . It is only passed when USE_CMAKE is
defined. doxygen uses devel/cmake/ that does not set this
variable. So checking for if devel/ is included might
fix the problem. Do we have a convention on how to check for if a
particular file is included? One way could be to look for the
targets it defines like cmake-configure. I have tested this, aka
adding "|| target(cmake-configure)" after "defined(USE_CMAKE)", in and it works for me with the configuration you mention
(python2.7 but no py27-expat). Also I did a grep on
"defined(USE_CMAKE)" in the pkgsrc tree and the lua buildlink3 files
also check for USE_CMAKE to add cmake arguments, so I hope they are not
causing similar problems.


Home | Main Index | Thread Index | Old Index