-
Notifications
You must be signed in to change notification settings - Fork 24
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
Q:Heroku Zbar Didn't find libzbar on your system (LoadError) #8
Comments
It looks like that buildpack is putting
If it's not there, try |
thanks for the help! deploy completed. but method from_jpeg fails with "JPEG datastream contains no image my application controller.create: What should I do? |
It's not so much old as it is unpatched. The current release version ( I think the right way to do this would be to fork the buildpack, add the patch file, apply it hereabouts, and open a pull request with the buildpack maintainer to get it merged upstream. |
Updates on this end -- I am now using the following buildpacks: https://github.com/generalui/heroku-buildpack-zbar I can see in the compilation that zbar is being installed. and in heroku run bash I see a zbar folder but I don't see a libzbar.so file and the deploy is still failing: Is there a better buildpack that you recommend? I see many "yet to be official" heroku zbar buildpacks on github but haven't had success with any. Thanks for your work on this library! |
I have limited connectivity at the moment, but try something like:
Hopefully there's a
Hope that helps! |
Hi Will, thanks for the advice -- I see a libzbar.rc but no libzbar.so. Should I probably try another buildpack? |
Having the same problem, I can't find libzar even with the command. It's not located in the usr/local path either. |
So after contacting the zbar-buildpack owner, he recommended using the apt-buildpack instead. It looked like it was going to work because it installed libzbar0 just fine but it didn't create a libzbar.so file so I tried libzbar-dev. libzbar-dev created a libzbar.so file in Unfortunately when I point to it in heroku config
|
@michaelryu, I am posting a stack overflow question about this in case anyone in the community has had any success with it. Please upvote! http://stackoverflow.com/questions/31812168/how-can-i-get-zbar-to-deploy-on-heroku |
@michaelryu I am now in the same place as you. I used the apt-buildpack: `=== testing-aptfile Buildpack URLs And I made an Aptfile, saved it to root, with only the word “libzbar-dez” in it. I was able to find a libzbar.so file — this is progress for me!
I set the ENV variable ZBAR_LIB.
But when I push to Heroku, I get the same error message as before:
@willglynn Do you see anything I might be doing wrong here? Anything you might see would be a huge help. |
Hmm:
This path appears in Now I'm curious about the output of:
|
Hi @willglynn, thanks for following up. I'm still stuck! Here is the ouput of the terminal commands:
|
Does |
looks like it does -- good sign?
|
I tried setting ZBAR_LIB to /app/.apt/usr/lib/libzbar.so.0.2.0 but still getting the same error with these two buildpacks:
|
Could you make a test case repo I can clone and deploy to Heroku? I don't understand why it's failing with |
Sure thing, thanks so much for following me through this. This is a more or less blank repo: https://github.com/andyweiss1982/aptfile-test All I have added is the Aptfile with the string "libzbar-dev" in it, and placed a barcode.jpg in the public folder. This is the heroku url, but there is an application error related to the deploy issues: https://aptfile-test.herokuapp.com/ If you send me your email address, I can add you as a collaborator on heroku so you can see that side as well. My email is my github username at gmail dot com. Thanks again! |
I started a
The Checking the Heroku logs, release v9 seems to have been failing:
…while release v10 seems to work:
https://aptfile-test.herokuapp.com/ currently returns a 404 from the dyno rather than a 503 App Crashed from Heroku's router. So… it's fixed? What was the issue? |
A-ha! The I'm guessing it's being loaded as part of |
Finally! @michaelryu the require: false in the Gemfile and separately requiring in the controller is what did it for me. Thank you so much @willglynn for seeing this through to the end. Answering my own Stack Overflow question here in case anyone has the same problem in the future: |
Hi guys! I was dealing with similar issues the past few weeks and spent a lot of time trying to get it working. I ended up creating a heroku buildpack that uses the patched version of Zbar. I also figured out how to get it running on CircleCI. Maybe it will help someone else in the future! Heroku: Circle CI: |
I have a rails application which uses zbar. It works fine on my developer machine But when i tried to deploy it to Heroku my commit was rejected with the following message:
app/web.1: /app/vendor/bundle/ruby/2.0.0/gems/zbar-0.2.2/lib/zbar/lib.rb:12:in
rescue in <module:ZBar>': Didn't find libzbar on your system (LoadError) app/web.1: Please install zbar (http://zbar.sourceforge.net/) or set ZBAR_LIB if it's in a weird place app/web.1: FFI::Library::ffi_lib() failed with error: library names list must not be empty app/web.1: from /app/vendor/bundle/ruby/2.0.0/gems/zbar-0.2.2/lib/zbar/lib.rb:9:in
module:ZBar'Here is my gemfile;
gem 'zbar', '~> 0.2.2'
my /.buildpacks:
https://github.com/ballantyne/heroku-buildpack-zbar
https://github.com/heroku/heroku-buildpack-ruby.git
Why does this happen?
Thanks.
The text was updated successfully, but these errors were encountered: