[LLVMdev] proposal to avoid zlib dependency.

Mueller-Roemer, Johannes Sebastian Johannes.Sebastian.Mueller-Roemer at igd.fraunhofer.de
Wed Sep 17 07:47:55 PDT 2014


It's half the way there. Configuring and compiling works, but linking fails, probably some definition mismatches...

But it can definitely be simplified, as due to the "REQUIRED" flag CMake will already fail if zlib isn't found, so no need for the

  if (ZLIB_FOUND)
    ...
  else()
    message(FATAL_ERROR "zlib was requested but it could not be found")
  endif()

--
Johannes S. Mueller-Roemer, MSc
Wiss. Mitarbeiter - Interactive Engineering Technologies (IET)

Fraunhofer-Institut für Graphische Datenverarbeitung IGD
Fraunhoferstr. 5  |  64283 Darmstadt  |  Germany
Tel +49 6151 155-606  |  Fax +49 6151 155-139
johannes.mueller-roemer at igd.fraunhofer.de  |  www.igd.fraunhofer.de


-----Original Message-----
From: Dan Liew [mailto:dan at su-root.co.uk] 
Sent: Wednesday, September 17, 2014 15:21
To: Mueller-Roemer, Johannes Sebastian
Cc: llvmdev at cs.uiuc.edu
Subject: Re: [LLVMdev] proposal to avoid zlib dependency.

On 17 September 2014 13:27, Mueller-Roemer, Johannes Sebastian <Johannes.Sebastian.Mueller-Roemer at igd.fraunhofer.de> wrote:
> Yes, this is incredibly annoying, so please avoid that. However I noticed that the current solution using CMake is broken, as I cannot enter my own ZLIB_ROOT, since no proper find_package is used.

I just had a go at hacking this so that we use find_package(ZLIB) if LLVM_ENABLE_ZLIB is used. Does the attached patch work correctly?

If so I could send to llvm-commits for review.




More information about the llvm-dev mailing list