Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9122897
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T06:12:39+00:00 2026-06-17T06:12:39+00:00

I am trying to write some program using the OpenKinect project. I want to

  • 0

I am trying to write some program using the OpenKinect project. I want to add the OpenKinect’s master branch as a subdirectory to my project’s source. But, if you look into the OpenKinect’s own CMake, there is too much stuff there, and I do not need everything. There are certain options there, which are being set to ON or OFF, like this:

OPTION(BUILD_AUDIO "Build audio support" OFF)
OPTION(BUILD_REDIST_PACKAGE "Build libfreenect in a legally-redistributable manner (only affects audio)" OFF)
OPTION(BUILD_EXAMPLES "Build example programs" ON)
OPTION(BUILD_FAKENECT "Build fakenect mock library" ON)
OPTION(BUILD_C_SYNC "Build c synchronous library" ON)
OPTION(BUILD_CPP "Build C++ Library (currently header only)" ON)
OPTION(BUILD_CV "Build OpenCV wrapper" ON)
OPTION(BUILD_AS3_SERVER "Build the Actionscript 3 Server Example" OFF)
OPTION(BUILD_PYTHON "Build Python extension" ON)
IF(PROJECT_OS_LINUX)
    OPTION(BUILD_CPACK "Build an RPM or DEB using CPack" ON)
ENDIF(PROJECT_OS_LINUX)

Without making any major changes to the OpenKinect files (so that I can git pull any time I need to), how do I import only some parts (e.g., the C++ wrapper and the OpenCV bindings) to my own CMake project? I thought of copying certain directories, which are not dependent on the other directories, if I completely re-write the CMake files. I would not be able to use the git any more, but it would be a quick fix. But I am getting strange errors that way, such as “stdexcept was not not declared in this scope”, which makes no sense, because it is a standard gc++ library.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T06:12:41+00:00Added an answer on June 17, 2026 at 6:12 am

    If you simply want to enable/disable some parts of that library, you can simply set the appropriate options before calling ADD_SUBDIRECTORY.

    Simply use the same OPTION commands as in the library’s CMakeLists.txt but set them ON/OFF as you need. Of course, oyu are free to change/choose the describing string as you like.

    Alternatively (and if options have a different value than true/false), you can use the SET(.... CACHE ... )

    e.g.

    SET(BUILD_CPP TRUE CACHE BOOL "Build C++ Library (currently header only)")
    

    Similar question:
    Override option in CMake subproject

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am trying to write an OpenGL visualization program for some scientific data using
I am trying to write some data pulled from some source code (using httplib2
Some overflow runtime error happens when my C++ program is trying to write some
I'm trying to write a secure transfer file program using Python and AES and
I'm trying to write a program that cleans data, using Matlab. This program takes
I'm trying to write a quick (ha!) program to organise some of my financial
I am trying to write a program that read a file using fstream then,
I'm trying to write some GUI and integration tests using JUnit and FEST. Here
I am trying to write a program using a directed graph (which I know
I am trying to write a program that reads in binary files using C++.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.