Giter VIP home page Giter VIP logo

Comments (5)

memsharded avatar memsharded commented on July 17, 2024

Hi @Zaeb0s

Could you please clarify what would be the purpose of the tool? At first I thought you were asking for a doxygen package, something that you wrapped doxygen and you could use it as a build_require in your projects, but I think you want something different. Could you write a code snippet, of how you see the interface of that tool? How would you use it in your recipes? Thanks!

from docs.

Zaeb0s avatar Zaeb0s commented on July 17, 2024

Hello @memsharded

Sorry about the lack of information I will try to clarify.

I am currently using this crude implementation of the tool which I am talking about doxygen.zip.

And to use the tool I do the following inside conanfile.py (all other build related stuff striped away).

def build(self):
    self.doxy = doxygen.Doxygen(self)

def package_info(self):        
    self.doxy.add_include_paths()
    self.doxy.build()
    self.doxy.build_latex()

Currently building inside the package_info method because I want to generate doxygen on the packaged header files only.

The result is a HTML page and/or a PDF which contains information not only about the current package but also all its dependencies.

from docs.

memsharded avatar memsharded commented on July 17, 2024

Ok, thanks for the info.

The bad thing is that such will fail when you are not building the package, because the build() method will not be called, and self.doxy will be undefined.

Also, it has another bad side effect. The doxy.xxx commands will be called everytime the package is consumed by another project or package, even if the docs have been already built (and it is a slow thing!) I think you really need to restrict building the docs in the build(), or if any, do it in the last thing in the package() method, but not the package_info() method.

Another question is: How do you consume docs that are inside a package? Because typically package artifacts are consumed with generators (cmake, etc) in build systems automatically, but there is no direct interface for users to read those docs. That would also help understand the global use case.

So I guess that such utility is a wrapper around some doxygen commands (I have used it, in the past, but I don't recall much). In that case, it shouldn't be very difficult to implement, I will label it accordingly. Thanks!

from docs.

Zaeb0s avatar Zaeb0s commented on July 17, 2024

Ah, yes thank you for pointing that out I did not think about that.

With that in mind it should probably instead be used like the following:

    options = {"doc": [True, False]}
    default_options = "doc=False"
    def package(self):
        # self.copy calls...
        if self.options.doc:
            doxy = doxygen.Doxygen(self)
            doxy.add_dependencies()
            doxy.build()
            doxy.build_latex()            

Currently documentation is only generated for the top-level package and stored in Artifactory, this way all builds are always ready for release.

from docs.

memsharded avatar memsharded commented on July 17, 2024

This is currently not planned as a built-in Conan feature.

The doxygen package in ConanCenter can be easily used in recipes as:

    def build_requirements(self):
        self.tool_requires("doxygen/1.9.4")

    def build(self):
       self.output.info("Doxygen Version:")
       self.run("doxygen --version")

However, I am moving this to the "docs" repo, I think it could make sense to document this as a useful integration

from docs.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.