加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 百科 > 正文

ruby-on-rails – 在windows上安装rmagick gem

发布时间:2020-12-16 22:56:38 所属栏目:百科 来源:网络整理
导读:所以我一直在寻找一段时间,我终于能够获得gem install rmagick在错误输出之前超过一秒钟.我不得不得到一个旧版本的imageMagick安装程序6.8.8-0-Q16,而不是imageMagick现在托管在他们的网站上,因为它没有安装dev c / c标头的选项,我一直在努力工作以使工作正
所以我一直在寻找一段时间,我终于能够获得gem install rmagick在错误输出之前超过一秒钟.我不得不得到一个旧版本的imageMagick安装程序6.8.8-0-Q16,而不是imageMagick现在托管在他们的网站上,因为它没有安装dev c / c标头的选项,我一直在努力工作以使工作正常进行这是我上次运行gem安装的输出.
C:Sites>gem install rmagick
Temporarily enhancing PATH to include DevKit...
Building native extensions.  This could take a while...
ERROR:  Error installing rmagick:
        ERROR: Failed to build gem native extension.

        C:/RailsInstaller/Ruby1.9.3/bin/ruby.exe extconf.rb
checking for Ruby version >= 1.8.5... yes
checking for stdint.h... yes
checking for sys/types.h... yes
checking for wand/MagickWand.h... yes
checking for snprintf() in assert.h,ctype.h,stdio.h,stdlib.h,math.h,time.h,stdint.h,sys/types.h,wand/MagickWand.h... yes
checking for AcquireImage() in assert.h,wand/MagickWand.h... no
checking for AffinityImage() in assert.h,wand/MagickWand.h... no
checking for AffinityImages() in assert.h,wand/MagickWand.h... no
checking for AutoGammaImageChannel() in assert.h,wand/MagickWand.h... no
checking for AutoLevelImageChannel() in assert.h,wand/MagickWand.h... no
checking for BlueShiftImage() in assert.h,wand/MagickWand.h... no
checking for ConstituteComponentTerminus() in assert.h,wand/MagickWand.h... no
checking for DeskewImage() in assert.h,wand/MagickWand.h... no
checking for EncipherImage() in assert.h,wand/MagickWand.h... no
checking for EqualizeImageChannel() in assert.h,wand/MagickWand.h... no
checking for FloodfillPaintImage() in assert.h,wand/MagickWand.h... no
checking for FunctionImageChannel() in assert.h,wand/MagickWand.h... no
checking for GetAuthenticIndexQueue() in assert.h,wand/MagickWand.h... no
checking for GetAuthenticPixels() in assert.h,wand/MagickWand.h... no
checking for GetImageAlphaChannel() in assert.h,wand/MagickWand.h... no
checking for GetVirtualPixels() in assert.h,wand/MagickWand.h... no
checking for LevelImageColors() in assert.h,wand/MagickWand.h... no
checking for LevelColorsImageChannel() in assert.h,wand/MagickWand.h... no
checking for LevelizeImageChannel() in assert.h,wand/MagickWand.h... no
checking for LiquidRescaleImage() in assert.h,wand/MagickWand.h... no
checking for MagickLibAddendum() in assert.h,wand/MagickWand.h... yes
checking for OpaquePaintImageChannel() in assert.h,wand/MagickWand.h... no
checking for QueueAuthenticPixels() in assert.h,wand/MagickWand.h... no
checking for RemapImage() in assert.h,wand/MagickWand.h... no
checking for RemoveImageArtifact() in assert.h,wand/MagickWand.h... no
checking for SelectiveBlurImageChannel() in assert.h,wand/MagickWand.h... no
checking for SetImageAlphaChannel() in assert.h,wand/MagickWand.h... no
checking for SetImageArtifact() in assert.h,wand/MagickWand.h... no
checking for SetMagickMemoryMethods() in assert.h,wand/MagickWand.h... no
checking for SparseColorImage() in assert.h,wand/MagickWand.h... no
checking for SyncAuthenticPixels() in assert.h,wand/MagickWand.h... no
checking for TransformImageColorspace() in assert.h,wand/MagickWand.h... no
checking for TransparentPaintImage() in assert.h,wand/MagickWand.h... no
checking for TransparentPaintImageChroma() in assert.h,wand/MagickWand.h... no
checking for QueryMagickColorname() new signature... yes
checking for Image.type in assert.h,wand/MagickWand.h... yes
checking for DrawInfo.kerning in assert.h,wand/MagickWand.h... yes
checking for DrawInfo.interline_spacing in assert.h,wand/MagickWand.h... yes
checking for DrawInfo.interword_spacing in assert.h,wand/MagickWand.h... yes
checking for DitherMethod in assert.h,wand/MagickWand.h... yes
checking for MagickFunction in assert.h,wand/MagickWand.h... yes
checking for ImageLayerMethod in assert.h,wand/MagickWand.h... yes
checking for long double in assert.h,wand/MagickWand.h... yes
checking for AlphaChannelType.CopyAlphaChannel... yes
checking for AlphaChannelType.BackgroundAlphaChannel... yes
checking for CompositeOperator.BlurCompositeOp... yes
checking for CompositeOperator.DistortCompositeOp... yes
checking for CompositeOperator.LinearBurnCompositeOp... yes
checking for CompositeOperator.LinearDodgeCompositeOp... yes
checking for CompositeOperator.MathematicsCompositeOp... yes
checking for CompositeOperator.PegtopLightCompositeOp... yes
checking for CompositeOperator.PinLightCompositeOp... yes
checking for CompositeOperator.VividLightCompositeOp... yes
checking for CompressionType.DXT1Compression... yes
checking for CompressionType.DXT3Compression... yes
checking for CompressionType.DXT5Compression... yes
checking for CompressionType.ZipSCompression... yes
checking for CompressionType.PizCompression... yes
checking for CompressionType.Pxr24Compression... yes
checking for CompressionType.B44Compression... yes
checking for CompressionType.B44ACompression... yes
checking for DistortImageMethod.BarrelDistortion... yes
checking for DistortImageMethod.BarrelInverseDistortion... yes
checking for DistortImageMethod.BilinearForwardDistortion... yes
checking for DistortImageMethod.BilinearReverseDistortion... yes
checking for DistortImageMethod.DePolarDistortion... yes
checking for DistortImageMethod.PolarDistortion... yes
checking for DistortImageMethod.PolynomialDistortion... yes
checking for DistortImageMethod.ShepardsDistortion... yes
checking for DitherMethod.NoDitherMethod... yes
checking for FilterTypes.KaiserFilter... yes
checking for FilterTypes.WelshFilter... yes
checking for FilterTypes.ParzenFilter... yes
checking for FilterTypes.LagrangeFilter... yes
checking for FilterTypes.BohmanFilter... yes
checking for FilterTypes.BartlettFilter... yes
checking for FilterTypes.SentinelFilter... yes
checking for MagickEvaluateOperator.PowEvaluateOperator... yes
checking for MagickEvaluateOperator.LogEvaluateOperator... yes
checking for MagickEvaluateOperator.ThresholdEvaluateOperator... yes
checking for MagickEvaluateOperator.ThresholdBlackEvaluateOperator... yes
checking for MagickEvaluateOperator.ThresholdWhiteEvaluateOperator... yes
checking for MagickEvaluateOperator.GaussianNoiseEvaluateOperator... yes
checking for MagickEvaluateOperator.ImpulseNoiseEvaluateOperator... yes
checking for MagickEvaluateOperator.LaplacianNoiseEvaluateOperator... yes
checking for MagickEvaluateOperator.MultiplicativeNoiseEvaluateOperator... yes
checking for MagickEvaluateOperator.PoissonNoiseEvaluateOperator... yes
checking for MagickEvaluateOperator.UniformNoiseEvaluateOperator... yes
checking for MagickEvaluateOperator.CosineEvaluateOperator... yes
checking for MagickEvaluateOperator.SineEvaluateOperator... yes
checking for MagickEvaluateOperator.AddModulusEvaluateOperator... yes
checking for MagickFunction.ArcsinFunction... yes
checking for MagickFunction.ArctanFunction... yes
checking for MagickFunction.PolynomialFunction... yes
checking for MagickFunction.SinusoidFunction... yes
checking for ImageLayerMethod.FlattenLayer... yes
checking for ImageLayerMethod.MergeLayer... yes
checking for ImageLayerMethod.MosaicLayer... yes
checking for ImageLayerMethod.TrimBoundsLayer... yes
checking for VirtualPixelMethod.HorizontalTileVirtualPixelMethod... yes
checking for VirtualPixelMethod.VerticalTileVirtualPixelMethod... yes
checking for VirtualPixelMethod.HorizontalTileEdgeVirtualPixelMethod... yes
checking for VirtualPixelMethod.VerticalTileEdgeVirtualPixelMethod... yes
checking for VirtualPixelMethod.CheckerTileVirtualPixelMethod... yes
checking for ruby/io.h... yes
checking for rb_frame_this_func() in ruby.h,ruby/io.h... yes
creating extconf.h
creating Makefile


======================================================================
Sun 05Jan14 20:21:14
This installation of RMagick 2.13.2 is configured for
Ruby 1.9.3 (i386-mingw32) and ImageMagick 6.8.8
======================================================================



make
generating RMagick2-i386-mingw32.def
compiling rmagick.c
In file included from rmagick.c:13:0:
rmagick.h:81:2: error: #error Specified QuantumDepth is not supported.
rmagick.c: In function 'Magick_colors':
rmagick.c:42:5: warning: passing argument 2 of 'GetColorInfoList' from incompatible pointer type
C:Program FilesImageMagick-6.8.8-Q16include/magick/color.h:75:5: note: expected 'size_t *' but argument is of type 'long unsigned int *'
rmagick.c: In function 'Magick_fonts':
rmagick.c:90:5: warning: passing argument 2 of 'GetTypeInfoList' from incompatible pointer type
C:Program FilesImageMagick-6.8.8-Q16include/magick/type.h:98:5: note: expected 'size_t *' but argument is of type 'long unsigned int *'
rmagick.c: In function 'Magick_init_formats':
rmagick.c:178:5: warning: passing argument 2 of 'GetMagickInfoList' from incompatible pointer type
C:Program FilesImageMagick-6.8.8-Q16include/magick/magick.h:129:5: note: expected 'size_t *' but argument is of type 'long unsigned int *'
make: *** [rmagick.o] Error 1


Gem files will remain installed in C:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/rmagick-2.13.2 for inspection.
Results logged to C:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/rmagick-2.13.2/ext/RMagick/gem_make.out

任何帮助都会非常感激,因为我不知道该怎么做.

解决方法

几天前我遇到了这个问题,我通过一系列教程解决了这个问题.

简而言之,您的错误似乎是由于ImageMagic和Rmagick之间的兼容性问题.

卸载ImageMagick并重新安装适用于您的Ruby设置的先前版本.

这对我有用:

> Ruby 1.9.3
>开发套件32-4.5.2
> ImageMagick 6.7.7(我很难找到ImageMagick遗留版本的二进制版本,所以我想this link会对你很方便)> Rmagick 2.13.2

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读