[CRIU] [PATCH] criu: add a shell wrapper

Pavel Emelyanov xemul at virtuozzo.com
Tue Apr 19 22:06:12 PDT 2016


> -install: criu
> +install: .criu
>  	$(E) "  INSTALL " criu
>  	$(Q) mkdir -p $(DESTDIR)$(SBINDIR)
> -	$(Q) install -m 755 criu $(DESTDIR)$(SBINDIR)
> +	$(Q) install -m 755 .criu $(DESTDIR)$(SBINDIR)/criu
>  	$(Q) mkdir -p $(DESTDIR)$(INCLUDEDIR)
>  	$(Q) install -m 644 $(UAPI_HEADERS) $(DESTDIR)$(INCLUDEDIR)
>  .PHONY: install
>  
>  #
>  # Final @all target.
> -all: criu
> +all: .criu
>  	@true
>  .PHONY: all

Yes, the problem exists, I agree. But this solution is awful :(
Can we better export the LD_LIBRARY_PATH in the zdtm.py script?

> diff --git a/criu/criu b/criu/criu
> new file mode 100755
> index 0000000..d3cf974
> --- /dev/null
> +++ b/criu/criu
> @@ -0,0 +1,7 @@
> +#!/bin/sh
> +
> +# This is a wrapper around @REALBIN@ to be able to run it with a library
> +# from @LIB_PATH@ that might not yet be installed into a proper place.
> +
> +BASEDIR=$(dirname $0)
> +LD_LIBRARY_PATH=${BASEDIR}/../soccr exec ${BASEDIR}/.criu "$@"
> 



More information about the CRIU mailing list