airplay-server icon indicating copy to clipboard operation
airplay-server copied to clipboard

errors with the mdsn when module is used

Open KingCheng1987 opened this issue 8 years ago • 4 comments

I did the test with the api followed:

var server = require('airplay-server')("my pc airplay");

server.on('request',function(req,res){ console.log("aiplay request",res); });

server.listen(6000);

but, when the test actived,the errors came followed: module.js:339 throw err; ^

Error: Cannot find module '../build/Release/dns_sd_bindings' at Function.Module._resolveFilename (module.js:337:15) at Function.Module._load (module.js:287:25) at Module.require (module.js:366:17) at require (module.js:385:17) at Object. (/home/king/re/node_modules/airplay-mdns- server/node_modules/mdns/lib/dns_sd.js:32:22) at Module._compile (module.js:435:26) at Object.Module._extensions..js (module.js:442:10) at Module.load (module.js:356:32) at Function.Module._load (module.js:311:12) at Module.require (module.js:366:17)

what can i do to fix the error?

KingCheng1987 avatar Apr 19 '16 03:04 KingCheng1987

What operation system are you running on? Seems like it can't find the dns bindings

watson avatar Apr 24 '16 18:04 watson

Error: Cannot find module '..\build\Release\dns_sd_bindings' at Function.Module._resolveFilename (module.js:339:15) at Function.Module._load (module.js:290:25) at Module.require (module.js:367:17) at require (internal/module.js:16:19) at Object. (C:\Users\Administrator\Desktop\airp npminstall\mdns\2.3.3\mdns\lib\dns_sd.js:32:22) at Module._compile (module.js:413:34) at Object.Module._extensions..js (module.js:422:10) at Module.load (module.js:357:32) at Function.Module._load (module.js:314:12) at Module.require (module.js:367:17)

it is win7 ,it is same error ,how can fix it.

buzai avatar Jun 04 '16 05:06 buzai

I updated my nodejs,then the problem disappeared.But i forgot the special situation,if I don't misremember ,my nodejs is not match with the package.json

KingCheng1987 avatar Jun 06 '16 07:06 KingCheng1987

@buzai

Error: Cannot find module '..\build\Release\dns_sd_bindings' at Function.Module._resolveFilename (module.js:339:15) at Function.Module._load (module.js:290:25) at Module.require (module.js:367:17) at require (internal/module.js:16:19) at Object. (C:\Users\Administrator\Desktop\airp npminstall\mdns\2.3.3\mdns\lib\dns_sd.js:32:22) at Module._compile (module.js:413:34) at Object.Module._extensions..js (module.js:422:10) at Module.load (module.js:357:32) at Function.Module._load (module.js:314:12) at Module.require (module.js:367:17)

it is win7 ,it is same error ,how can fix it.

I was facing the same issue, however, downloading and installing Bonjour SDK fixed it

Bonjour SDK will create system environment variable BONJOUR_SDK_HOME which points to installation dir

simkuns avatar Apr 23 '21 11:04 simkuns