-
Notifications
You must be signed in to change notification settings - Fork 386
Fix Library Loading #12
base: master
Are you sure you want to change the base?
Conversation
Probably better to tell it where to look before looking. ;-) cmake was bombing out because of this.
As stated, this compiles fine on Ubuntu 18.04 and 16.04. What OS were you on? What version of CMake? |
Kali
CMake 3.13.4
…On Mon, Feb 25, 2019 at 2:33 PM Jacob Baines ***@***.***> wrote:
As stated, this compiles fine on Ubuntu 18.04 and 16.04. What OS were you
on? What version of CMake?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#12 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AViPgc9tEG06jsxWMuf3YQqYOFFL73Yvks5vREiMgaJpZM4bQuhP>
.
|
I'm not exactly sure what you are doing, but I can't reproduce this. I just downloaded and installed Kali 64 bit (2019-01-03). I used apt to install cmake (3.13.4) and libboost-all-dev (1.67). I cloned the routeros repo. I moved to poc/cve-2018-14847. Made a directory called build. Moved into build. Typed "cmake .." and everything ran as expected. Unless you can give me specific instructions to reproduce, I'm not sure what you've done. |
I did exactly that as well, and received this error:
CMake Error at /usr/share/cmake-3.13/Modules/FindBoost.cmake:1357 (file):
file STRINGS file "/usr/include/boost/version.hpp" cannot be read.
Call Stack (most recent call first):
CMakeLists.txt:8 (find_package)
CMake Error at /usr/share/cmake-3.13/Modules/FindBoost.cmake:2100 (message):
Unable to find the requested Boost libraries.
Boost version: 0.0.0
Boost include path: /usr/include
Could not find the following Boost libraries:
boost_program_options
boost_system
boost_regex
No Boost libraries were found. You may need to set BOOST_LIBRARYDIR to
the
directory containing Boost libraries or BOOST_ROOT to the location of
Boost.
Call Stack (most recent call first):
CMakeLists.txt:8 (find_package)
…-- Configuring incomplete, errors occurred!
See also
"/root/routeros/poc/cve_2018_14847/build/CMakeFiles/CMakeOutput.log".
-------------------------------------------------------------------------------------------------------------------
Environment variable "Boost_INCLUDE_DIR" was set to "/usr/include/boost/"
Perhaps the Boost include path was set correctly via .bashrc for you or
something that didn't happen for me, and it needed to be picked up via the
include_directories directive.
But that just moving the find_package directive below the includes fixed my
issue.
If you aren't able to reproduce, no biggie, was just trying to help the
next guy.
Cheers,
Nate Kettlewell
On Mon, Feb 25, 2019 at 3:32 PM Jacob Baines ***@***.***> wrote:
I'm not exactly sure what you are doing, but I can't reproduce this.
I just downloaded and installed Kali 64 bit (2019-01-03). I used apt to
install cmake (3.13.4) and libboost-all-dev (1.67). I cloned the routeros
repo. I moved to poc/cve-2018-14847. Made a directory called build. Moved
into build. Typed "cmake .." and everything ran as expected.
Unless you can give me specific instructions to reproduce, I'm not sure
what you've done.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#12 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AViPgbqXxdFMrC6akGOTiHLyDhv3BEtuks5vRFZ1gaJpZM4bQuhP>
.
|
Despite my shortness, I really do appreciate it. And I agree, what you see does appear to be a failure to find boost. I just prefer to be able to recreate an issue before accepting a PR. I'm going to leave this open and maybe someone else will encounter the problem and set me straight. The other thing, is that there are many other CMake scripts that should have the same issue. So if someone does confirm this is a problem, it should affect just about every PoC. |
I experienced the same error message on a fresh installation, some libraries were not installed. get install libboost-all-dev fixed it maybe overkill, but i can live with the bloat on this temp VM |
I Think the Error is Because in the line 8, It's "boost" and not "Boost" Changing it to "Boost" Solves The CMake Problem. |
I'm getting similar errors, and have tried all sort of variations. $ mkdir build && cd build && cmake ..
-- Building for: Visual Studio 15 2017
-- Selecting Windows SDK version 10.0.17763.0 to target Windows 6.3.9600.
-- The C compiler identification is MSVC 19.16.27034.0
-- The CXX compiler identification is MSVC 19.16.27034.0
-- Check for working C compiler: C:/Program Files (x86)/Microsoft Visual Studio/2017/Community/VC/Tools/MSVC/14.16.27023/bin/Hostx86/x86/cl.exe
-- Check for working C compiler: C:/Program Files (x86)/Microsoft Visual Studio/2017/Community/VC/Tools/MSVC/14.16.27023/bin/Hostx86/x86/cl.exe -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: C:/Program Files (x86)/Microsoft Visual Studio/2017/Community/VC/Tools/MSVC/14.16.27023/bin/Hostx86/x86/cl.exe
-- Check for working CXX compiler: C:/Program Files (x86)/Microsoft Visual Studio/2017/Community/VC/Tools/MSVC/14.16.27023/bin/Hostx86/x86/cl.exe -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
CMake Warning at C:/Program Files/CMake/share/cmake-3.15/Modules/FindBoost.cmake:1125 (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.15/Modules/FindBoost.cmake:1247 (_Boost_COMPONENT_DEPENDENCIES)
C:/Program Files/CMake/share/cmake-3.15/Modules/FindBoost.cmake:1885 (_Boost_MISSING_DEPENDENCIES)
CMakeLists.txt:17 (find_package)
CMake Warning at C:/Program Files/CMake/share/cmake-3.15/Modules/FindBoost.cmake:1125 (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.15/Modules/FindBoost.cmake:1247 (_Boost_COMPONENT_DEPENDENCIES)
C:/Program Files/CMake/share/cmake-3.15/Modules/FindBoost.cmake:1885 (_Boost_MISSING_DEPENDENCIES)
CMakeLists.txt:17 (find_package)
CMake Warning at C:/Program Files/CMake/share/cmake-3.15/Modules/FindBoost.cmake:1125 (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.15/Modules/FindBoost.cmake:1247 (_Boost_COMPONENT_DEPENDENCIES)
C:/Program Files/CMake/share/cmake-3.15/Modules/FindBoost.cmake:1885 (_Boost_MISSING_DEPENDENCIES)
CMakeLists.txt:17 (find_package)
CMake Error at C:/Program Files/CMake/share/cmake-3.15/Modules/FindPackageHandleStandardArgs.cmake:137 (message):
Could NOT find Boost (missing: program_options system regex) (found
suitable version "1.71.0", minimum required is "1.66")
Call Stack (most recent call first):
C:/Program Files/CMake/share/cmake-3.15/Modules/FindPackageHandleStandardArgs.cmake:378 (_FPHSA_FAILURE_MESSAGE)
C:/Program Files/CMake/share/cmake-3.15/Modules/FindBoost.cmake:2142 (find_package_handle_standard_args)
CMakeLists.txt:17 (find_package)
-- Configuring incomplete, errors occurred! Including changing stuff in the CMake file: cmake_minimum_required(VERSION 3.2)
set(PROJECT_NAME btw)
project(${PROJECT_NAME})
# -Wno-dev
set(CMAKE_CXX_FLAGS "-g -std=c++17 -Wall -Wextra -Weffc++ -Wshadow -Wcast-align -Wcast-qual -Woverloaded-virtual -Wstrict-null-sentinel ... TRUNCATED!
#cmake_policy(NEW)
cmake_policy(SET CMP0074 NEW)
set(Boost_INCLUDE_DIR "C:/Program Files/boost/boost_1_71_0")
include_directories(SYSTEM ${Boost_INCLUDE_DIR})
include_directories(../../common/)
find_package(Boost 1.66 COMPONENTS program_options system regex REQUIRED)
# compilation units
add_executable(${PROJECT_NAME}
src/main.cpp
../../common/md5.cpp
../../common/session.cpp
../../common/winbox_session.cpp
../../common/winbox_message.cpp)
# linking comp / libs
target_link_libraries(${PROJECT_NAME} ${Boost_LIBRARIES} -lpthread)
Any ideas how to resolve this? BOOST_LIBRARYDIR="C:\Program Files\boost\boost_1_71_0\libs"
BOOST_ROOT="C:\Program Files\boost\boost_1_71_0"
export Boost_INCLUDE_DIR="C:\Program Files\boost\boost_1_71_0"
export Boost_LIBRARIES="C:\Program Files\boost\boost_1_71_0\libs"
export Boost_ROOT="C:\Program Files\boost\boost_1_71_0"
still no success. |
Hello. I'm on kali linux. Tried to follow install. instructions, to build CVE-2018-14847. after that, in build folder there is no cve_2018_14847_poc file (there is Makefile, cmake_install.cmake, CMakeCache.txt, and CMakeFiles folder.). |
i`m new one to compilling stuff from github, so cloned routeros, then cmake from poc/bytheway/ and all was fine, recovered old forgotten password on hex poe with 6.41, reset button was disabled PS: used ubuntu 18.04, boost 1.66, standard cmake in oracle virtualbox on windows |
Probably better to tell it where to look before looking. ;-)
cmake was bombing out because of this.