Giter Club home page Giter Club logo

Comments (8)

htaox avatar htaox commented on June 2, 2024

They are of STD, so take out "tr1/".

Compiled after changing to below:

unordered_map.hpp
#include <unordered_map>

unordered_set.hpp
#include <unordered_set>

from msgpack-node.

danielabar avatar danielabar commented on June 2, 2024

I'm having the same problem on Windows 8.1 64 bit with Visual Studio 2013 Express.
It looks like the above comment is a solution, but I don't understand, what does it mean:
"They are of STD, so take out tr1/" ?

I'm actually trying to do npm install winston-fluent
from https://github.com/sakamoto-san/winston-fluent

Which depends on msgpack, and when its building msgpack, I get the error:

c:\projects\myapp\node_modules\winston-fluent\node_modules\fluent-logger\node_modules\msgpack\deps\msgpack\msgpack\type/tr1/unordered_map.hpp(22) : fatal error C1083: Cannot open include file: 'tr1/unordered_map': No such file or directory (..\..\..\deps\msgpack\object.cpp) [c:\projects\myapp\node_modules\winston-fluent\node_modules\fluent-logger\node_modules\msgpack\build\deps\msgpack\libmsgpack.vcxproj]
gyp ERR! build error
gyp ERR! stack Error: `C:\Program Files (x86)\MSBuild\12.0\bin\msbuild.exe` failed with exit code: 1
gyp ERR! stack     at ChildProcess.onExit (c:\app\nodejs\node_modules\npm\node_modules\node-gyp\lib\build.js:267:23)
gyp ERR! stack     at ChildProcess.EventEmitter.emit (events.js:98:17)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (child_process.js:797:12)
gyp ERR! System Windows_NT 6.2.9200
gyp ERR! command "node" "c:\\app\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
gyp ERR! cwd c:\projects\myapp\node_modules\winston-fluent\node_modules\fluent-logger\node_modules\msgpack
gyp ERR! node -v v0.10.26
gyp ERR! node-gyp -v v0.12.2
gyp ERR! not ok
npm ERR! [email protected] install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script.
npm ERR! This is most likely a problem with the msgpack package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node-gyp rebuild

from msgpack-node.

htaox avatar htaox commented on June 2, 2024

Can you try this?

  1. Get the repo
    git clone https://github.com/msgpack/msgpack-node
  2. Make the following changes
    C:\downloadFolder\msgpack-node\deps\msgpack\msgpack\type\tr1\unordered_map.hpp
    Change:
    #include <tr1/unordered_map>
    To:
    #include <unordered_map>

C:\downloadFolder\msgpack-node\deps\msgpack\msgpack\type\tr1\unordered_set.hpp
Change:
#include <tr1/unordered_set>
To:
#include <unordered_set>

  1. Open "Windows SDK 7.1 Command Prompt"
  2. Set the compile environment
    SetEnv /Release /x64
  3. Install
    cd C:\downloadFolder\msgpack-node

npm install

from msgpack-node.

danielabar avatar danielabar commented on June 2, 2024

Thanks for the reply. Here's what I ended up doing, because I was trying to use winston-fluent, which depends on fluent-logger, which in turn depends on msgpack:

  • Forked
  • Committed the fix for windows, removing tr1/ from unordered map and set .hpp files (verifying build works locally with Microsoft Visual Studio 2013 Express and also ran all tests)
  • Ran npm shrinkwrap --dev in my other project using winston-fluent, modified the nested dependency on msgpack to point to gzip tarball from my fork

And now it works. Thanks for your help :-)

from msgpack-node.

godsflaw avatar godsflaw commented on June 2, 2024

I will happily take pull requests that fix the issue without breaking other ports.

from msgpack-node.

htaox avatar htaox commented on June 2, 2024

I submitted pull request #16. Thanks.

from msgpack-node.

willyg302 avatar willyg302 commented on June 2, 2024

Could #16 be merged and pushed to npm? Same issue currently breaking npm install zerorpc for me, ran through the steps above and it worked.

from msgpack-node.

godsflaw avatar godsflaw commented on June 2, 2024

All merged up, version bumped, tagged, pushed to all mirrored repos, and published to npm. Thanks for the fix @htaox!

from msgpack-node.

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.