windows compatability #123

Closed
AlgoTrader opened this Issue Mar 23, 2012 · 12 comments

Comments

Projects
None yet
7 participants
@AlgoTrader

Great library but cannot use it in Windows. There is no node-waf there. Can you please fix it?

npm WARN continuing anyway libxmljs@0.5.4 preuninstall: node-waf clean
npm WARN continuing anyway cmd "/c" "node-waf clean" failed with 1

npm ERR! libxmljs@0.5.4 install: node-waf configure build
npm ERR! cmd "/c" "node-waf configure build" failed with 1
npm ERR!
npm ERR! Failed at the libxmljs@0.5.4 install script.
npm ERR! This is most likely a problem with the libxmljs package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-waf configure build
npm ERR! You can get their info via:
npm ERR! npm owner ls libxmljs
npm ERR! There is likely additional logging output above.
npm ERR!
npm ERR! System Windows_NT 5.1.2600
npm ERR! command "C:\Program Files\nodejs\node.exe" "C:\Program Files\nodejs\node_modules\n
pm\bin\npm-cli.js" "install" "betfair-sports-api"
npm ERR! cwd C:\Node
npm ERR! node -v v0.6.13
npm ERR! npm -v 1.1.9
npm ERR! code ELIFECYCLE
npm ERR! message libxmljs@0.5.4 install: node-waf configure build
npm ERR! message cmd "/c" "node-waf configure build" failed with 1
npm ERR! errno {}
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! C:\Node\npm-debug.log

@defunctzombie

This comment has been minimized.

Show comment
Hide comment
@defunctzombie

defunctzombie Mar 25, 2012

Collaborator

I personally do not use windows (or have any boxes active with it). If you would like to provide a patch, we would probly accept it :)

Collaborator

defunctzombie commented Mar 25, 2012

I personally do not use windows (or have any boxes active with it). If you would like to provide a patch, we would probly accept it :)

@deanlandolt

This comment has been minimized.

Show comment
Hide comment
@deanlandolt

deanlandolt Mar 30, 2012

bump ... I've got a project using libxmljs that I ultimately need to deploy on windows and I'd really like to avoid cygwin if at all possible. Any idea of level of effort?

bump ... I've got a project using libxmljs that I ultimately need to deploy on windows and I'd really like to avoid cygwin if at all possible. Any idea of level of effort?

@defunctzombie

This comment has been minimized.

Show comment
Hide comment
@defunctzombie

defunctzombie Mar 30, 2012

Collaborator

I am not sure on the level of effort, you just have to have a go at it. I will not be able to fix this issue as I do not use windows.

My first suggestion would be to get a gyp build for the package going.

Collaborator

defunctzombie commented Mar 30, 2012

I am not sure on the level of effort, you just have to have a go at it. I will not be able to fix this issue as I do not use windows.

My first suggestion would be to get a gyp build for the package going.

@AlgoTrader

This comment has been minimized.

Show comment
Hide comment
@AlgoTrader

AlgoTrader Mar 30, 2012

To use NPM one must have Visual Studio 2008/2010 installed, npm should run from Visual Studio prompt to compile libxmljs and ... There is still a problem - there is no libxml2 on windows. One can make a custom build of libxmljs bundled with build libxml2 and deploy it. I see no easy way to fix it, node-waf is just a pin of iceberg

To use NPM one must have Visual Studio 2008/2010 installed, npm should run from Visual Studio prompt to compile libxmljs and ... There is still a problem - there is no libxml2 on windows. One can make a custom build of libxmljs bundled with build libxml2 and deploy it. I see no easy way to fix it, node-waf is just a pin of iceberg

@fabio-polimeni

This comment has been minimized.

Show comment
Hide comment
@fabio-polimeni

fabio-polimeni Mar 31, 2012

Following the link to libxml2 -> Libxml2 is known to be very portable, the library should build and work without serious troubles on a variety of systems (Linux, Unix, Windows, CygWin, MacOS, MacOS X, RISC Os, OS/2, VMS, QNX, MVS, VxWorks, ...)

I've got a libxml2.dll on my win7. You can find it in here http://xmlsoft.org/downloads.html

Oh, sorry @betfairtrader, you probably meant that you can't actually build is under Windows.

Following the link to libxml2 -> Libxml2 is known to be very portable, the library should build and work without serious troubles on a variety of systems (Linux, Unix, Windows, CygWin, MacOS, MacOS X, RISC Os, OS/2, VMS, QNX, MVS, VxWorks, ...)

I've got a libxml2.dll on my win7. You can find it in here http://xmlsoft.org/downloads.html

Oh, sorry @betfairtrader, you probably meant that you can't actually build is under Windows.

@AlgoTrader

This comment has been minimized.

Show comment
Hide comment
@AlgoTrader

AlgoTrader Apr 3, 2012

I can. I don't think it is good idea of bundling libxmljs with libxml2 . I need install libxml2 and that is not as simple as "zypper install libxml2-devel" on SUSE linux. I need to install Visual Studio C++ and run npm from the VS friendly command prompt, make shure libxml2 headers are visible and libxml2.lib is in linking path. Then I need to patch libxmljs to support VS C++ build. Too many troubles, isn't it?

I can. I don't think it is good idea of bundling libxmljs with libxml2 . I need install libxml2 and that is not as simple as "zypper install libxml2-devel" on SUSE linux. I need to install Visual Studio C++ and run npm from the VS friendly command prompt, make shure libxml2 headers are visible and libxml2.lib is in linking path. Then I need to patch libxmljs to support VS C++ build. Too many troubles, isn't it?

@defunctzombie

This comment has been minimized.

Show comment
Hide comment
@defunctzombie

defunctzombie Aug 31, 2012

Collaborator

closing due to inactivity. There is a new build system in place (gyp) that might be of more assistance. Patches are welcome for windows support :)

Collaborator

defunctzombie commented Aug 31, 2012

closing due to inactivity. There is a new build system in place (gyp) that might be of more assistance. Patches are welcome for windows support :)

@matthewkastor

This comment has been minimized.

Show comment
Hide comment
@matthewkastor

matthewkastor Nov 1, 2012

ok, so how do I do it on windows? node-gyp works for compiling things and, I can get binaries and such for libxml2. The binaries for windows don't come with the xml2-config utility though. I'm just not sure what to do here.

I found some information about xml2-config at http://www.xmlsoft.org/FAQ.html and it says that it's a shell script. Obviously I can't run a shell script for linux so, if I wrote a script my system could execute, would I be able to compile this or am I just being naive?

ok, so how do I do it on windows? node-gyp works for compiling things and, I can get binaries and such for libxml2. The binaries for windows don't come with the xml2-config utility though. I'm just not sure what to do here.

I found some information about xml2-config at http://www.xmlsoft.org/FAQ.html and it says that it's a shell script. Obviously I can't run a shell script for linux so, if I wrote a script my system could execute, would I be able to compile this or am I just being naive?

@kessler

This comment has been minimized.

Show comment
Hide comment
@kessler

kessler Dec 19, 2012

Hey @matthewkastor :) I'm having the same problem, maybe you ran into a solution by now...?

kessler commented Dec 19, 2012

Hey @matthewkastor :) I'm having the same problem, maybe you ran into a solution by now...?

@matthewkastor

This comment has been minimized.

Show comment
Hide comment
@matthewkastor

matthewkastor Dec 19, 2012

@yanush

Yes, the solution is to use something else. This project is a linux program that depends on node and other software. It is not compatible with windows.

xmldom is described as

"Fully compatible with W3C DOM level2; and some compatible with level3. support DOMParser and XMLSerializer interface such as in browser."

https://github.com/jindw/xmldom#readme

xpath is described as

"DOM 3 Xpath implemention and helper for node.js. xpath is xml engine agnostic but I recommend to use xmldom"

https://npmjs.org/package/xpath

Also of note is jsdom which provides

"A JavaScript implementation of the W3C DOM."

It's basically a fully scriptable headless web browser. Depending on what you're trying to accomplish this might be more useful.

https://npmjs.org/package/jsdom

Since many windows users are introduced to libxml through php, the following unrelated package may be interesting https://npmjs.org/package/phpjs

Let me know if that helps.

@yanush

Yes, the solution is to use something else. This project is a linux program that depends on node and other software. It is not compatible with windows.

xmldom is described as

"Fully compatible with W3C DOM level2; and some compatible with level3. support DOMParser and XMLSerializer interface such as in browser."

https://github.com/jindw/xmldom#readme

xpath is described as

"DOM 3 Xpath implemention and helper for node.js. xpath is xml engine agnostic but I recommend to use xmldom"

https://npmjs.org/package/xpath

Also of note is jsdom which provides

"A JavaScript implementation of the W3C DOM."

It's basically a fully scriptable headless web browser. Depending on what you're trying to accomplish this might be more useful.

https://npmjs.org/package/jsdom

Since many windows users are introduced to libxml through php, the following unrelated package may be interesting https://npmjs.org/package/phpjs

Let me know if that helps.

@kessler

This comment has been minimized.

Show comment
Hide comment
@kessler

kessler Dec 19, 2012

@matthewkastor

Thank you very much for your detailed reply! I will look into all of this.

kessler commented Dec 19, 2012

@matthewkastor

Thank you very much for your detailed reply! I will look into all of this.

@polotek

This comment has been minimized.

Show comment
Hide comment
@polotek

polotek Dec 20, 2012

Collaborator

Duplicate of #176. No promises, but watch that space.

Collaborator

polotek commented Dec 20, 2012

Duplicate of #176. No promises, but watch that space.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment