Ticket #53882: patch-Makefile.diff

File patch-Makefile.diff, 1.6 KB (added by Raimondi (Israel Chauca Fuentes), 8 years ago)
  • Makefile

    SRC = array.c buffer.c libutf.c main.c map.c register.c ring-buffer.c \ 
    77        ui-terminal.c view.c vis.c vis-lua.c vis-modes.c vis-motions.c \
    88        vis-operators.c vis-prompt.c vis-text-objects.c $(REGEX_SRC)
    99
    10 ELF = vis vis-menu vis-digraph
     10ELF = @VISEXEC@ vis-menu vis-digraph
    1111EXECUTABLES = $(ELF) vis-clipboard vis-complete vis-open
    1212
    1313MANUALS = $(EXECUTABLES:=.1)
    LDFLAGS_STD ?= -lc 
    3535CFLAGS_VIS = $(CFLAGS_AUTO) $(CFLAGS_TERMKEY) $(CFLAGS_CURSES) $(CFLAGS_ACL) \
    3636        $(CFLAGS_SELINUX) $(CFLAGS_TRE) $(CFLAGS_LUA) $(CFLAGS_LPEG) $(CFLAGS_STD)
    3737
    38 CFLAGS_VIS += -DVIS_PATH=\"${SHAREPREFIX}/vis\"
     38CFLAGS_VIS += -DVIS_PATH=\"${SHAREPREFIX}/@VISDIR@\"
    3939CFLAGS_VIS += -DCONFIG_HELP=${CONFIG_HELP}
    4040CFLAGS_VIS += -DCONFIG_CURSES=${CONFIG_CURSES}
    4141CFLAGS_VIS += -DCONFIG_LUA=${CONFIG_LUA}
    config.h: 
    5757config.mk:
    5858        @touch $@
    5959
    60 vis: config.h config.mk *.c *.h
     60@VISEXEC@: config.h config.mk *.c *.h
    6161        ${CC} ${CFLAGS} ${CFLAGS_VIS} ${CFLAGS_EXTRA} ${SRC} ${LDFLAGS} ${LDFLAGS_VIS} -o $@
    6262
    6363vis-menu: vis-menu.c
    install: $(ELF) 
    118118                chmod 755 ${DESTDIR}${PREFIX}/bin/"$$e"; \
    119119        done
    120120        @test ${CONFIG_LUA} -eq 0 || { \
    121                 echo installing support files to ${DESTDIR}${SHAREPREFIX}/vis; \
    122                 mkdir -p ${DESTDIR}${SHAREPREFIX}/vis; \
    123                 cp -r lua/* ${DESTDIR}${SHAREPREFIX}/vis; \
     121                echo installing support files to ${DESTDIR}${SHAREPREFIX}/@VISDIR@; \
     122                mkdir -p ${DESTDIR}${SHAREPREFIX}/@VISDIR@; \
     123                cp -r lua/* ${DESTDIR}${SHAREPREFIX}/@VISDIR@; \
    124124                rm -rf "${DESTDIR}${SHAREPREFIX}/vis/doc"; \
    125125        }
    126126        @echo installing manual pages to ${DESTDIR}${MANPREFIX}/man1