-1

How would one go about editing either the C++ opencv functions and/or the python opencv functions in Ubuntu? Where is the source code located? For C++ how would one go about recompiling the source code?

Thank you.

1 Answer 1

2

Since Ubuntu is primarily a binary package based distribution, the source code isn't "located" anywhere on your system unless you explicitly download it; either:

  1. by enabling the appropriate source repositories, and then using apt-get source e.g.

    apt-get source opencv
    

    Note that this will download the source into the current directory - hence does not need sudo if you are downloading into a location within your home directory. It should also apply any relevant Ubuntu-specific patches such that the built code is equivalent to that of the corresponding binary package.

  2. by downloading a source tarball or checking out from the maintainer's git (or similar) source code repository. Note that this may get you a more up-to-date version of the software; however it also won't necessarily have been tested or patched for your current system.

In either case, you will likely need to install additional build dependencies before you are able to recompile the package from source, regardless of any changes you may have made to it.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .