uWebSockets icon indicating copy to clipboard operation
uWebSockets copied to clipboard

More control of linking / including dependencies with Makefile

Open yurivict opened this issue 4 years ago • 3 comments

These lines

# WITH_LIBDEFLATE=1 enables fast paths for SHARED_COMPRESSOR and inflation
ifeq ($(WITH_LIBDEFLATE),1)
        override CXXFLAGS += -I libdeflate -DUWS_USE_LIBDEFLATE
        override LDFLAGS += libdeflate/libdeflate.a
endif

require bundled libdeflate but libdeflate packages are available on many systems: https://repology.org/project/libdeflate/versions

yurivict avatar Mar 11 '21 20:03 yurivict

From what I understand - every Linux dist pretty much has its own "build system" and its own package manager / dependency resolution.

So if the goal is to play better with the "native" dependency manager of a particular Linux dist - that's probably a task of that package for that particular platform.

What I mean is if Homebrew is a platform we want to support then of course that Homebrew package will have to play along with Homebrew's packages.

Same for Fedora, etc.

Or how do you think about it? Simply a way to specify what prefix to use?

WITH_LIBDEFLATE=/usr/include?

ghost avatar Mar 12 '21 11:03 ghost

WITH_LIBDEFLATE=/usr/include?

Something like this would work.

yurivict avatar Mar 12 '21 17:03 yurivict

That could also be a good idea for OpenSSL/BoringSSL where both are compatible and only need a linking / include change

ghost avatar Mar 13 '21 11:03 ghost