diff options
author | Rasmus Johansson <rasmus@mariadb.com> | 2019-05-18 06:11:01 +0000 |
---|---|---|
committer | Sergei Golubchik <serg@mariadb.org> | 2019-06-17 12:26:26 +0200 |
commit | 24503d5711677ce77617e3ff2514a4838e95eac7 (patch) | |
tree | 3f4242c2026612bfb57d9f853c6c0638fa395a2d /man | |
parent | f02bc3cf0f8f972c8f626a42490864dddd2e4f23 (diff) | |
download | mariadb-git-24503d5711677ce77617e3ff2514a4838e95eac7.tar.gz |
MDEV-17592 Create MariaDB named commands/symlinks
Diffstat (limited to 'man')
-rw-r--r-- | man/CMakeLists.txt | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/man/CMakeLists.txt b/man/CMakeLists.txt index 7a1e284b3e7..c89d156718d 100644 --- a/man/CMakeLists.txt +++ b/man/CMakeLists.txt @@ -44,3 +44,42 @@ INSTALL(FILES ${MAN1_CLIENT} DESTINATION ${INSTALL_MANDIR}/man1 COMPONENT ManPag INSTALL(FILES ${MAN1_DEVEL} DESTINATION ${INSTALL_MANDIR}/man1 COMPONENT ManPagesDevelopment) INSTALL(FILES ${MAN1_TEST} DESTINATION ${INSTALL_MANDIR}/man1 COMPONENT ManPagesTest) +macro(MARIADB_SYMLINK_MANPAGE) + list(LENGTH MARIADB_SYMLINK_FROMS _len) + math(EXPR _listlen "${_len}-1") + + foreach(_index RANGE ${_listlen}) + list(GET MARIADB_SYMLINK_FROMS ${_index} _name) + + set(_manname "${_name}") + list(FIND MAN1_SERVER ${_manname}.1 _iman1server) + list(FIND MAN8_SERVER ${_manname}.8 _iman8server) + list(FIND MAN1_CLIENT ${_manname}.1 _iman1client) + list(FIND MAN1_DEVEL ${_manname}.1 _iman1devel) + list(FIND MAN1_TEST ${_manname}.1 _iman1test) + + if (${_iman1server} GREATER -1) + MARIADB_SYMLINK_MANPAGE_CREATE(${_manname} ${_index} 1 "man1" ManPagesServer) + endif() + if (${_iman8server} GREATER -1) + MARIADB_SYMLINK_MANPAGE_CREATE(${_manname} ${_index} 8 "man8" ManPagesServer) + endif() + if (${_iman1client} GREATER -1) + MARIADB_SYMLINK_MANPAGE_CREATE(${_manname} ${_index} 1 "man1" ManPagesClient) + endif() + if (${_iman1devel} GREATER -1) + MARIADB_SYMLINK_MANPAGE_CREATE(${_manname} ${_index} 1 "man1" ManPagesDevelopment) + endif() + if (${_iman1test} GREATER -1) + MARIADB_SYMLINK_MANPAGE_CREATE(${_manname} ${_index} 1 "man1" ManPagesTest) + endif() + endforeach(_index) +endmacro(MARIADB_SYMLINK_MANPAGE) + +macro(MARIADB_SYMLINK_MANPAGE_CREATE mysqlname index mannr dir comp) + list(GET MARIADB_SYMLINK_TOS ${index} _mariadbname) + set(symlinkname "${_mariadbname}.${mannr}") + CREATE_MARIADB_SYMLINK_IN_DIR(${mysqlname}.${mannr} ${symlinkname} ${INSTALL_MANDIR}/${dir} ${comp}) +endmacro(MARIADB_SYMLINK_MANPAGE_CREATE) + +MARIADB_SYMLINK_MANPAGE() |