ShiqiYu / ShiqiYu/libfacedetection

[MSVC] Libfacedetection build failed due to error C2039: 'to_string': is not a member of 'std'

Open
#348 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C++
Stars
12.8k
Forks
3k
PR merge metrics
No merged PRs in 30d

Description

Description:
Recently, we updated the commit of bitcoin for MSVC RWC testing, it failed to build due to the error C2039 and error C3861 like below, could you please help take a look? Thanks.

F:\gitP\ShiqiYu\libfacedetection\src\facedetectcnn.cpp(638,17): error C2039: 'to_string': is not a member of 'std' [F:\gitP\ShiqiYu\libfacedetection\build_amd64\facedetection.vcxproj]
         F:\gitP\ShiqiYu\libfacedetection\src\facedetectcnn.cpp(638,26): error C3861: 'to_string': identifier not found [F:\gitP\ShiqiYu\libfacedetection\build_amd64\facedetection.vcxproj]

Expected behavior:
Build successfully.

Actual behavior:
Build failed with error C2039 and error C3861

To reprodece:

  1. open VS2019 x64 Native Tools command.
  2. git clone https://github.com/ShiqiYu/libfacedetection F:\gitP\ShiqiYu\libfacedetection
  3. mkdir F:\gitP\ShiqiYu\libfacedetection\build_amd64 and cd F:\gitP\ShiqiYu\libfacedetection\build_amd64
  4. cmake -G "Visual Studio 16 2019" -A x64 -DCMAKE_SYSTEM_VERSION=10.0.18362.0 -DCMAKE_INSTALL_PREFIX=install -DBUILD_SHARED_LIBS=ON -DCMAKE_BUILD_TYPE=Release -DDEMO=OFF ..
  5. msbuild /m /p:Platform=x64 /p:Configuration=Release libfacedetection.sln /t:Rebuild

More info:
The commit of Libfacedetection we use: 4092665
VS version: VS2019 (v16.11.20)

Detailed log:
build.log

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with src/facedetectcnn.cpp at line 638 and inspect the VS2019 build output in build.log. Reproduce the failure using the provided CMake and MSBuild commands, then verify that the libfacedetection.sln Release x64 rebuild completes successfully.

Written by the indexing model from the issue text.

Assessment

Tech stack
cmake, cpp
Domain
build-system
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.