Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cmake throwing ICONV_LIBRARIES not found error #8

Open
vishless opened this issue Aug 12, 2021 · 0 comments
Open

cmake throwing ICONV_LIBRARIES not found error #8

vishless opened this issue Aug 12, 2021 · 0 comments

Comments

@vishless
Copy link

Trying to install zxing_cpp gem in windows with the following command

gem install zxing_cpp

cmake complains that some environment variables (ICONV_LIBRARIES) are missing.

Environment:
Windows 10
ruby 2.5.7
zxing_cpp 0.1.1
cmake 3.20.5

Here's the complete log of the gem build:

CMake Error: The following variables are used in this project, but they are set to NOTFOUND.
Please set them or make sure they are set and tested correctly in the CMake files:
ICONV_LIBRARIES (ADVANCED)

C:\Users\viprasant>gem install zxing_cpp
Temporarily enhancing PATH for MSYS/MINGW...
Building native extensions. This could take a while...
ERROR:  Error installing zxing_cpp:
        ERROR: Failed to build gem native extension.

    current directory: C:/Ruby25-x64/lib/ruby/gems/2.5.0/gems/zxing_cpp-0.1.1/ext/zxing
C:/Ruby25-x64/bin/ruby.exe -r ./siteconf20210812-12952-1wi1uye.rb extconf.rb
CMake Deprecation Warning at CMakeLists.txt:6 (cmake_minimum_required):
  Compatibility with CMake < 2.8.12 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.


CMake Warning at CMakeLists.txt:88 (message):
  Not building testrunner, because CppUnit is missing


CMake Error: The following variables are used in this project, but they are set to NOTFOUND.
Please set them or make sure they are set and tested correctly in the CMake files:
ICONV_LIBRARIES (ADVANCED)
    linked by target "libzxing" in directory C:/Ruby25-x64/lib/ruby/gems/2.5.0/gems/zxing_cpp-0.1.1/ext/zxing/zxing-cpp

CMake Generate step failed.  Build files cannot be regenerated correctly.
make: *** No targets specified and no makefile found.  Stop.
creating Makefile

current directory: C:/Ruby25-x64/lib/ruby/gems/2.5.0/gems/zxing_cpp-0.1.1/ext/zxing
make "DESTDIR=" clean

current directory: C:/Ruby25-x64/lib/ruby/gems/2.5.0/gems/zxing_cpp-0.1.1/ext/zxing
make "DESTDIR="
generating zxing-x64-mingw32.def
compiling zxing.cc
linking shared-object zxing/zxing.so
x86_64-w64-mingw32-g++.exe: error: C:/Ruby25-x64/lib/ruby/gems/2.5.0/gems/zxing_cpp-0.1.1/ext/zxing/zxing-cpp/build/libzxing.a: No such file or directory
make: *** [Makefile:259: zxing.so] Error 1

make failed, exit code 2

Gem files will remain installed in C:/Ruby25-x64/lib/ruby/gems/2.5.0/gems/zxing_cpp-0.1.1 for inspection.
Results logged to C:/Ruby25-x64/lib/ruby/gems/2.5.0/extensions/x64-mingw32/2.5.0/zxing_cpp-0.1.1/gem_make.out
@vishless vishless changed the title Error while installing gem in windows: ICONV_LIBRARIES not found cmake throwing ICONV_LIBRARIES not found error Aug 19, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant