On Tue, Jul 25, 2017 at 2:51 PM, Benoît Canet < benoit.canet.cont...@gmail.com> wrote:
> external/ is an old filesystem snapshot > several years old. > This means the openssl and crypto libraries > in it are obsolettes. > > Get rid of this particular crypto dependencies > by using the host libraries. > This patch is mis-titled, because you actually "get rid" of the actual openssl libraries (nor header files) in external/. That would need to be done as a patch to a separate git submodule. What this patch does is to avoid *using* the libraries in external in two specific modules - httpserver and openssl. Amusingly (or sadly, depending on your perspective), the header files were already taken by httpserver from the build machine. > Signed-off-by: Benoît Canet <ben...@scylladb.com> > --- > modules/httpserver/Makefile | 7 +------ > modules/openssl/usr.manifest | 6 +++--- > 2 files changed, 4 insertions(+), 9 deletions(-) > > diff --git a/modules/httpserver/Makefile b/modules/httpserver/Makefile > index 8acdd3e0..9c42f4d0 100644 > --- a/modules/httpserver/Makefile > +++ b/modules/httpserver/Makefile > @@ -34,12 +34,7 @@ STUB_FILES := $(addprefix obj/,$(STUB_CPP_FILES:.cc=.o)) > > DYN_LIBS = -lpthread -ldl -L../libtools -ltools $(boost-libs) -lyaml-cpp > > -ifeq ($(use_host),y) > - DYN_LIBS += -lssl -lcrypto > -else > - DYN_LIBS += $(libs-dir)/libssl.so.10 \ > - $(libs-dir)/libcrypto.so.10 > -endif > +DYN_LIBS += -lssl -lcrypto > Please add to this patch also removing the "miscbase" and "libs-dir" variables, which are no longer used. > LIBS = $(DYN_LIBS) $(STATIC_LIBS) > > diff --git a/modules/openssl/usr.manifest b/modules/openssl/usr.manifest > index e9d13ad3..715a0358 100644 > --- a/modules/openssl/usr.manifest > +++ b/modules/openssl/usr.manifest > @@ -6,11 +6,11 @@ > # > > # From openssl-libs > -/usr/lib/openssl/**: %(miscbase)s/usr/lib64/openssl/** > +/usr/lib/openssl/**: /usr/lib64/openssl/** > How can we know that these libraries are in /usr/lib64? Is this a global Linux convention, or just a Fedora convention? Please check on at least one other non-Fedora distribution. > #/usr/lib/&/libssl.so.1.0.1k: %(miscbase)s/usr/lib64/& > You can now drop these commented out lines (they were commented out in commit 2781c85fc041b5a8a7c34a441e0830480e940940) > -/usr/lib/&/libssl.so.10: %(miscbase)s/usr/lib64/& > +/usr/lib/&/libssl.so.10: /usr/lib64/& > #/usr/lib/&/libcrypto.so.1.0.1k: %(miscbase)s/usr/lib64/& > -/usr/lib/&/libcrypto.so.10: %(miscbase)s/usr/lib64/& > +/usr/lib/&/libcrypto.so.10: /usr/lib64/& > How can we be sure that it's .so.10 and not something else? For Lua, we need this to be the case, but for other things, different versions of libcrypto would work too.... Perhaps we need the manifest to be created programically, by code which checks which libcrypto are installed? > > # From libcom_err > /usr/lib/&/libcom_err.so.2: %(miscbase)s/usr/lib64/& > There are a bunch of libraries which libssl.so and libcrypto.so require, and we may need to include those too. But why take *those* from miscbase and not from the build machine as well? Who said that external/usr/lib64/libcom_err.so.2 is good enough to use with the libssl.so we take from the build machine? (it likely is, but might not be in the future). You can use "ldd" to programatically build the right manifest from the requirements of libssl.so and libcrypto.so (we have an example of this in several modules). > -- > 2.13.3 > > -- > You received this message because you are subscribed to the Google Groups > "OSv Development" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to osv-dev+unsubscr...@googlegroups.com. > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "OSv Development" group. To unsubscribe from this group and stop receiving emails from it, send an email to osv-dev+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.