Page 1 of 1

7ImageMagick-7.0.1-2 does not build in visual studio 2010

Posted: 2016-05-09T10:29:22-07:00
by graemeNPS
I am trying to build in VisualStudio 2010 the latest download of source. Fails in flif and MagickCore projects.
Any thoughts on how to accomplish a 2010 build?

first failure is in flif:

Code: Select all

17>------ Rebuild All started: Project: CORE_flif, Configuration: Debug Win32 ------
17>Build started 09/05/2016 1:17:06 PM.
17>_PrepareForClean:
17>  Deleting file "..\Debug\DynamicMT-Win32\CORE_flif\CORE_flif.lastbuildstate".
17>InitializeBuildStatus:
17>  Touching "..\Debug\DynamicMT-Win32\CORE_flif\CORE_flif.unsuccessfulbuild".
17>ClCompile:
17>  common.cpp
17>  flif-dec.cpp
17>  flif-enc.cpp
17>  io.cpp
17>  color_range.cpp
17>c:\sources\thirdparty\imagemagick\imagemagick-7.0.1-2\flif\src\image\crc32k.hpp(4): fatal error C1083: Cannot open include file: 'cinttypes': No such file or directory
17>  crc32k.cpp
17>c:\sources\thirdparty\imagemagick\imagemagick-7.0.1-2\flif\src\image\crc32k.hpp(4): fatal error C1083: Cannot open include file: 'cinttypes': No such file or directory
17>  flif-interface_common.cpp
17>c:\sources\thirdparty\imagemagick\imagemagick-7.0.1-2\flif\src\image\crc32k.hpp(4): fatal error C1083: Cannot open include file: 'cinttypes': No such file or directory
17>  flif-interface_dec.cpp
17>c:\sources\thirdparty\imagemagick\imagemagick-7.0.1-2\flif\src\image\crc32k.hpp(4): fatal error C1083: Cannot open include file: 'cinttypes': No such file or directory
17>  flif-interface_enc.cpp
17>c:\sources\thirdparty\imagemagick\imagemagick-7.0.1-2\flif\src\image\crc32k.hpp(4): fatal error C1083: Cannot open include file: 'cinttypes': No such file or directory
17>  bit.cpp
17>  chance.cpp
17>c:\sources\thirdparty\imagemagick\imagemagick-7.0.1-2\flif\src\image\crc32k.hpp(4): fatal error C1083: Cannot open include file: 'cinttypes': No such file or directory
17>  symbol.cpp
17>c:\sources\thirdparty\imagemagick\imagemagick-7.0.1-2\flif\src\image\crc32k.hpp(4): fatal error C1083: Cannot open include file: 'cinttypes': No such file or directory
17>  factory.cpp
17>c:\sources\thirdparty\imagemagick\imagemagick-7.0.1-2\flif\src\image\crc32k.hpp(4): fatal error C1083: Cannot open include file: 'cinttypes': No such file or directory
17>c:\sources\thirdparty\imagemagick\imagemagick-7.0.1-2\flif\src\image\crc32k.hpp(4): fatal error C1083: Cannot open include file: 'cinttypes': No such file or directory
17>
17>Build FAILED.
17>
17>Time Elapsed 00:00:10.35


next failure is in MagickCore
21>------ Rebuild All started: Project: CORE_MagickCore, Configuration: Debug Win32 ------
21>Build started 09/05/2016 1:17:33 PM.
21>_PrepareForClean:
21>  Deleting file "..\Debug\DynamicMT-Win32\CORE_MagickCore\CORE_MagickCore.lastbuildstate".
21>InitializeBuildStatus:
21>  Touching "..\Debug\DynamicMT-Win32\CORE_MagickCore\CORE_MagickCore.unsuccessfulbuild".
21>ClCompile:
21>  accelerate.c
21>  animate.c
21>  annotate.c
21>  artifact.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  attribute.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  blob.c
21>..\..\ImageMagick\MagickCore\annotate.c(1021): warning C4100: 'image' : unreferenced formal parameter
21>  cache-view.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  cache.c
21>  channel.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  BZIP compiling as DLL import
21>  cipher.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  client.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  coder.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  color.c
21>  colormap.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  colorspace.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  compare.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>..\..\ImageMagick\MagickCore\color.c(2574): warning C4100: 'image' : unreferenced formal parameter
21>  composite.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  compress.c
21>  configure.c
21>  constitute.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  decorate.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  delegate.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  deprecate.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  display.c
21>  distort.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  distribute-cache.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  draw.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  effect.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  enhance.c
21>  exception.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  feature.c
21>  fourier.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  fx.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  gem.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  geometry.c
21>  histogram.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>c:\sources\thirdparty\imagemagick\imagemagick-7.0.1-2\imagemagick\magickcore\fx.c(6040): warning C4701: potentially uninitialized local variable 'low_pass' used
21>  identify.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  image-view.c
21>  image.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  layer.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  linked-list.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  list.c
21>  locale.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  log.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  magic.c
21>  magick.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  matrix.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  memory.c
21>  mime.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  module.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  monitor.c
21>  montage.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  morphology.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  nt-base.c
21>  nt-feature.c
21>  opencl.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  option.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  paint.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  pixel.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>..\..\ImageMagick\MagickCore\option.c(2481): warning C4100: 'exception' : unreferenced formal parameter
21>  policy.c
21>  prepress.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  profile.c
21>  property.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  quantize.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  quantum-export.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  quantum-import.c
21>  quantum.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  random.c
21>  registry.c
21>  resample.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  resize.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  resource.c
21>  segment.c
21>  semaphore.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>..\..\ImageMagick\MagickCore\resource.c(773): warning C4100: 'exception' : unreferenced formal parameter
21>  shear.c
21>  signature.c
21>  splay-tree.c
21>..\..\ImageMagick\MagickCore\resize.c(161): error C2143: syntax error : missing ';' before 'type'
21>..\..\ImageMagick\MagickCore\resize.c(162): error C2065: 'cosine' : undeclared identifier
21>..\..\ImageMagick\MagickCore\resize.c(162): error C2065: 'cosine' : undeclared identifier
21>..\..\ImageMagick\MagickCore\resize.c(178): error C2143: syntax error : missing ';' before 'type'
21>..\..\ImageMagick\MagickCore\resize.c(179): error C2143: syntax error : missing ';' before 'const'
21>..\..\ImageMagick\MagickCore\resize.c(180): error C2065: 'cosine' : undeclared identifier
21>..\..\ImageMagick\MagickCore\resize.c(180): error C2065: 'sine' : undeclared identifier
21>..\..\ImageMagick\MagickCore\resize.c(293): error C2143: syntax error : missing ';' before 'type'
21>..\..\ImageMagick\MagickCore\resize.c(294): error C2065: 'cosine' : undeclared identifier
21>..\..\ImageMagick\MagickCore\resize.c(306): error C2143: syntax error : missing ';' before 'type'
21>..\..\ImageMagick\MagickCore\resize.c(307): error C2065: 'cosine' : undeclared identifier
21>  static.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  statistic.c
21>  stream.c
21>  string.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  thread.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  threshold.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  timer.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  token.c
21>  transform.c
21>  type.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  utility.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  version.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  vision.c
21>  xml-tree.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>  xwindow.c
21>  MagickCore lib DLL export interface
21>  MagickCore module DLL export interface
21>
21>Build FAILED.

Re: 7ImageMagick-7.0.1-2 does not build in visual studio 2010

Posted: 2016-05-09T11:03:00-07:00
by dlemstra
We have not tried building ImageMagick in Visual Studio 2012. I can try to see why it is not building later this week. You can also try to contact the FLIF team and request them to fix the build error.

Re: 7ImageMagick-7.0.1-2 does not build in visual studio 2010

Posted: 2016-05-09T14:25:20-07:00
by graemeNPS
visual studio 2010 is what is failing for me.
do you know what Visual Studio versions do work?

Re: 7ImageMagick-7.0.1-2 does not build in visual studio 2010

Posted: 2016-05-09T14:26:23-07:00
by graemeNPS
which visual studio do you use to build the windows binary release?

Re: 7ImageMagick-7.0.1-2 does not build in visual studio 2010

Posted: 2016-05-09T15:19:07-07:00
by fmw42
see the comment about Visual Studio 2013 at http://www.imagemagick.org/script/binar ... hp#windows

Re: 7ImageMagick-7.0.1-2 does not build in visual studio 2010

Posted: 2016-05-16T07:35:48-07:00
by dlemstra
I just pushed some patches to fix your build errors. I also made a pull requests for FLIF to fix the build error in their repository. We are using VS2013 to build our binaries so please tell us when IM fails to build under VS2010.

Re: 7ImageMagick-7.0.1-2 does not build in visual studio 2010

Posted: 2016-05-18T09:14:34-07:00
by graemeNPS
Thanks, I will try this today; moving all of our stuff to 2013 is proving to be a pain.

Re: 7ImageMagick-7.0.1-2 does not build in visual studio 2010

Posted: 2017-04-29T13:39:42-07:00
by thebunnyrules
dlemstra wrote: 2016-05-16T07:35:48-07:00 I just pushed some patches to fix your build errors. I also made a pull requests for FLIF to fix the build error in their repository. We are using VS2013 to build our binaries so please tell us when IM fails to build under VS2010.
Did those patches ever get applied? I'm trying to compile 7.0.5 in VS 2010 and I'm getting the same errors as the OP. Where can I find those patches? I'd rather avoid using VS 2013 if I can. Otherwise, what's the latest build I can use VS2010 to compile?

Re: 7ImageMagick-7.0.1-2 does not build in visual studio 2010

Posted: 2017-04-30T05:30:49-07:00
by dlemstra
Those patches got applied but they were to fix the build with VS2013. I just pushed some patches to fix the build under VS 2010. But I had to add an option to disable certain packages depending on the Visual Studio version.This means that you won't have support for the FLIF format under VS 2010. I got it building under VS 2010 inside a VM but please let me know if that still won't work for you. You will need to wait for the next release before you can give it another try.

Re: 7ImageMagick-7.0.1-2 does not build in visual studio 2010

Posted: 2017-04-30T12:26:59-07:00
by thebunnyrules
Thanks for the feedback, diemstra. I don't need FLIF for my projects so that's ok. I see the patch you made in GitHub. I'll just merge any changes made after 7.0.5-5's release into it to make my own updated release folder.

Re: 7ImageMagick-7.0.1-2 does not build in visual studio 2010

Posted: 2017-04-30T13:38:53-07:00
by thebunnyrules
Ok, using the date 7.0.5-5 was released as a reference (25 Apr 2017), I downloaded anything that was changed after that date in Github and merged them to the main 7.0.5-5 release folder.Here are the things I downloaded: VisualMagick, dcraw, ImageMagick (core), jp2, flif.

I have VS 2010 ultimate sp1 with Windows SDK 7 and DDK 7.1 installed on Win7 sp1 running out of VirtualBox. I ran the wizard with the following settings: static multi-threaded run-times, build 64bit distribution, enable HDRI, OpenMP, exclude deprecated methods, q16, VS version 2010.

I'm no longer getting the C2143: syntax error anymore but I am getting alot of linker (LNK2019) errors for unresolved external symbols when making CORE_RL_MagickCore_.lib and CORE_RL_Magick++_.lib.

Here are a few example:

Code: Select all

2> CORE_RL_MagickCore_.lib(annotate.obj) : error LNK2019: unresolved external symbol FT_Load_Glyph referenced in function ComplexTextLayout
2>CORE_RL_MagickCore_.lib(annotate.obj) : error LNK2019: unresolved external symbol FT_Get_Kerning referenced in function ComplexTextLayout
2>CORE_RL_MagickCore_.lib(annotate.obj) : error LNK2019: unresolved external symbol FT_Get_Char_Index referenced in function ComplexTextLayout
2>CORE_RL_MagickCore_.lib(annotate.obj) : error LNK2019: unresolved external symbol FT_Done_Glyph referenced in function RenderFreetype
2>CORE_RL_MagickCore_.lib(annotate.obj) : error LNK2019: unresolved external symbol FT_Glyph_To_Bitmap referenced in function RenderFreetype
2>CORE_RL_MagickCore_.lib(annotate.obj) : error LNK2019: unresolved external symbol FT_Glyph_Transform referenced in function RenderFreetype
Functions mention: ComplexTextLayout, RenderFreetype, RegisterStaticModule, UnregisterStaticModules, EOFBlob, ReadBlob, SyncBlob, writeblob, openblob, seekblob, tellblob, closeblob, lot's of blobs...., GetICCProperty, DestroyTransformThreadSet, AquireTransformThreadSet, ZLIBEncodeImage, LiquidRescaleImage - I think that's it.

Did I perhaps make a wrong selection during taget setup (in configuration)? Some linker setting I'm missing? Or is there a SDK I'm missing maybe? Or did I simply mess up prepare of the release folder?

Re: 7ImageMagick-7.0.1-2 does not build in visual studio 2010

Posted: 2017-04-30T14:06:21-07:00
by dlemstra
If you are building from source it might be easier to clone the following repo: http://git.imagemagick.org/repos/ImageM ... indows.git. You will need git for windows but you probably already have that. After you have cloned the repo run: CloneRepositories.cmd. Then you will need to compile and run configure (inside VisualMagick folder) and that will create the new solution.

Re: 7ImageMagick-7.0.1-2 does not build in visual studio 2010

Posted: 2017-04-30T14:09:09-07:00
by thebunnyrules
I switched over to the Dynamic DLL build option in the Wizard. It compiled perfectly after.

Thanks for all your help! Now the fun begins :)

Re: 7ImageMagick-7.0.1-2 does not build in visual studio 2010

Posted: 2017-04-30T14:10:09-07:00
by thebunnyrules
dlemstra wrote: 2017-04-30T14:06:21-07:00 If you are building from source it might be easier to clone the following repo: http://git.imagemagick.org/repos/ImageM ... indows.git. You will need git for windows but you probably already have that. After you have cloned the repo run: CloneRepositories.cmd. Then you will need to compile and run configure (inside VisualMagick folder) and that will create the new solution.
Noted, I'll be sure to use it for future builds. Much easier for sure.