Code Monkey home page Code Monkey logo

Comments (16)

Svalorzen avatar Svalorzen commented on June 28, 2024

Did you install lp solve? There's many issues in the repo that you can search that show how you can do it on Windows.

from ai-toolbox.

WiemeJarne avatar WiemeJarne commented on June 28, 2024

Did you install lp solve? There's many issues in the repo that you can search that show how you can do it on Windows.

Yes I did Install lp solve. I did look at the other issues but I could not get it to work.

from ai-toolbox.

Svalorzen avatar Svalorzen commented on June 28, 2024

Where is it located in your directories? Could you share what is in its folder exactly?

from ai-toolbox.

WiemeJarne avatar WiemeJarne commented on June 28, 2024

Its located at C:\Program Files\lpsolve.

from ai-toolbox.

Svalorzen avatar Svalorzen commented on June 28, 2024

Again, what is in it? What exactly did you download?

I also need the entire output of CMake. You might need to delete the entire build folder and start CMake from scratch to get it.

from ai-toolbox.

WiemeJarne avatar WiemeJarne commented on June 28, 2024

Screenshot 2023-10-30 180432

full command output:
(c) Microsoft Corporation. All rights reserved.

C:\AI-Toolbox>mkdir build

C:\AI-Toolbox>cmake ..
CMake Warning:
Ignoring extra path from command line:

".."

CMake Error: The source directory "C:/" does not appear to contain CMakeLists.txt.
Specify --help for usage, or press the help button on the CMake GUI.

C:\AI-Toolbox>cd build

C:\AI-Toolbox\build>cmake ..
-- Selecting Windows SDK version 10.0.22000.0 to target Windows 10.0.19045.
-- Could not link against lpsolve55!
CMake Error at C:/Program Files/CMake/share/cmake-3.26/Modules/FindPackageHandleStandardArgs.cmake:230 (message):
Could NOT find LpSolve (missing: LPSOLVE_LIBRARIES)
Call Stack (most recent call first):
C:/Program Files/CMake/share/cmake-3.26/Modules/FindPackageHandleStandardArgs.cmake:600 (_FPHSA_FAILURE_MESSAGE)
cmake/Modules/FindLpSolve.cmake:91 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
CMakeLists.txt:143 (find_package)

-- Configuring incomplete, errors occurred!

from ai-toolbox.

Svalorzen avatar Svalorzen commented on June 28, 2024

What compiler are you using?

from ai-toolbox.

WiemeJarne avatar WiemeJarne commented on June 28, 2024

What compiler are you using?

I am not sure. I googled it how to find out which one I am using but could not find it. I have visual studio 2022 installed idk if that helps?

from ai-toolbox.

Svalorzen avatar Svalorzen commented on June 28, 2024

Because the CMake script that is looking to find lp_solve does so by (1) searching for the correct folder and (2) trying to compile a test program, one small test you can try to see what is wrong is to try to compile an example project with lp solve. If you can, then it's just a matter of making CMake here find the folder correctly. If you can't, then there's something wrong with the files and you might have to compile lp solve from source.

The docs here might help you on how to do that.
https://lpsolve.sourceforge.net/5.5/Build.htm#Statically%20link%20your%20application%20with%20lpsolve

from ai-toolbox.

WiemeJarne avatar WiemeJarne commented on June 28, 2024

Because the CMake script that is looking to find lp_solve does so by (1) searching for the correct folder and (2) trying to compile a test program, one small test you can try to see what is wrong is to try to compile an example project with lp solve. If you can, then it's just a matter of making CMake here find the folder correctly. If you can't, then there's something wrong with the files and you might have to compile lp solve from source.

The docs here might help you on how to do that. https://lpsolve.sourceforge.net/5.5/Build.htm#Statically%20link%20your%20application%20with%20lpsolve

I created a visual studio project and included the lp_lib.h file and noticed that the file has errors the first one is that it can't find dlfcn.h. Is this normal? Or do I have to install that file from somewhere?

from ai-toolbox.

Svalorzen avatar Svalorzen commented on June 28, 2024

To be honest, I don't know. I don't think I'm the right person to ask; I don't have much experience with Windows.

It is for sure that if you can't compile a simple project with the lp_solve headers, then compiling this one won't be any easier, so I'd work on figuring that out first.

As a last remark, in theory, not all of the library depends on lp_solve, and if the parts of AI-Toolbox you want to use don't depend on it you could extract their headers/cpp files and only use those. Unfortunately I have not yet had the time to go and make lp_solve an optional dependency.

from ai-toolbox.

WiemeJarne avatar WiemeJarne commented on June 28, 2024

I fixed the errors in the lp_lib.h file and recloned the repo just to try again and for now its not complaining about lp solve but its something with the boost library now. Here is the full about I get when doing cmake .. in the build folder:
C:\AI-Toolbox\build>cmake ..
-- Selecting Windows SDK version 10.0.22000.0 to target Windows 10.0.19045.
CMake Warning at C:/Program Files/CMake/share/cmake-3.26/Modules/FindBoost.cmake:1384 (message):
New Boost version may have incorrect or missing dependencies and imported
targets
Call Stack (most recent call first):
C:/Program Files/CMake/share/cmake-3.26/Modules/FindBoost.cmake:1508 (_Boost_COMPONENT_DEPENDENCIES)
C:/Program Files/CMake/share/cmake-3.26/Modules/FindBoost.cmake:2119 (_Boost_MISSING_DEPENDENCIES)
CMakeLists.txt:184 (find_package)

CMake Error at C:/Program Files/CMake/share/cmake-3.26/Modules/FindPackageHandleStandardArgs.cmake:230 (message):
Could NOT find Boost (missing: unit_test_framework) (found suitable version
"1.83.0", minimum required is "1.67")
Call Stack (most recent call first):
C:/Program Files/CMake/share/cmake-3.26/Modules/FindPackageHandleStandardArgs.cmake:600 (_FPHSA_FAILURE_MESSAGE)
C:/Program Files/CMake/share/cmake-3.26/Modules/FindBoost.cmake:2377 (find_package_handle_standard_args)
CMakeLists.txt:184 (find_package)

This time there are some file being generated CMakeCache.txt is one of them
CMakeCache.txt

from ai-toolbox.

Svalorzen avatar Svalorzen commented on June 28, 2024

That seems to say that Boost Test is missing. You might not have it installed? Certain Boost packages are installed separately because they are not header only (also Boost Python). In any case, if you just set -DMAKE_TEST=0 it should not be needed (you can't build the tests then though obviously).

from ai-toolbox.

WiemeJarne avatar WiemeJarne commented on June 28, 2024

That seems to say that Boost Test is missing. You might not have it installed? Certain Boost packages are installed separately because they are not header only (also Boost Python). In any case, if you just set -DMAKE_TEST=0 it should not be needed (you can't build the tests then though obviously).

I checked in the boost folder and there is a test folder. So it should work right? Here are the files that are in the test folder. (this folder is locaed in boost/libs/test).
image
I also tried this command: cmake -DMAKE_TEST=0 .. but that gives the same result.

from ai-toolbox.

Svalorzen avatar Svalorzen commented on June 28, 2024

I don't think that test folder is what you need. What's inside of it?

For the command, my bad, if you only specify no tests it will still build them by default. Try with:

cmake -DMAKE_LIB=1

from ai-toolbox.

WiemeJarne avatar WiemeJarne commented on June 28, 2024

I don't think that test folder is what you need. What's inside of it?

For the command, my bad, if you only specify no tests it will still build them by default. Try with:

cmake -DMAKE_LIB=1

Ah yes that made the build succeed but I do get errors when trying to run the projects. For example here are the errors when trying to run AIToolboxFMDP:
image

All project fail to build. I also tried the examples but they also fail to build.

from ai-toolbox.

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.