diff --git a/INSTALLATION.md b/INSTALLATION.md index b74253d..6fd0589 100644 --- a/INSTALLATION.md +++ b/INSTALLATION.md @@ -100,6 +100,7 @@ port install ncurses Build and install: ```bash +cp -vf dist/mac/configure.ac configure.ac autoreconf -fvi ./configure CFLAGS=-I$(brew --prefix)/opt/readline/include LDFLAGS=-L$(brew --prefix)/opt/readline/lib make diff --git a/configure.ac b/configure.ac index d77b1e8..24cd46e 100644 --- a/configure.ac +++ b/configure.ac @@ -4,7 +4,7 @@ AC_PREREQ([2.69]) -AC_INIT(hh, 1.15, martin.dvorak@mindforger.com) +AC_INIT(hh, 1.16, martin.dvorak@mindforger.com) AC_CONFIG_FILES([Makefile src/Makefile man/Makefile]) # Checks for src dir existence. @@ -16,19 +16,9 @@ AM_INIT_AUTOMAKE # Checks for programs. AC_PROG_CC -# Mac-specific ncurses check -AC_CANONICAL_HOST -AS_CASE([$host_os], - [darwin*], - [ - AC_CHECK_LIB(ncurses, killwchar, [], [AC_MSG_ERROR([Could not find ncurses library])]) - AC_CHECK_HEADER(curses.h) - ], - [ - AC_CHECK_LIB(ncursesw, killwchar, [], [AC_MSG_ERROR([Could not find ncursesw library])]) - AC_CHECK_HEADER(ncursesw/curses.h) - ] -) +# ncurses check. +AC_CHECK_LIB(ncursesw, killwchar, [], [AC_MSG_ERROR([Could not find ncursesw library])]) +AC_CHECK_HEADER(ncursesw/curses.h) # Checks for libraries. AC_CHECK_LIB(m, cos, [], [AC_MSG_ERROR([Could not find m library])]) diff --git a/dist/github-env.sh b/dist/github-env.sh index 72e110e..f054ad9 100755 --- a/dist/github-env.sh +++ b/dist/github-env.sh @@ -4,7 +4,7 @@ export NOW=`date +%Y-%m-%d--%H-%M-%S` export GH_RELEASE_DIR=~/p/hstr/release export GH_DISTRO_DIR=${GH_RELEASE_DIR}/release-${NOW} -export HHVERSION="1.15" -export GH_MSG="Enter first item auto-select, Vim keybinding, doc improvements." +export HHVERSION="1.16" +export GH_MSG="History timestamps, Zsh support and management fixes." # eof diff --git a/dist/mac/configure.ac b/dist/mac/configure.ac new file mode 100644 index 0000000..f85c8a3 --- /dev/null +++ b/dist/mac/configure.ac @@ -0,0 +1,58 @@ +# +# Process this file with autoconf to produce a configure script. +# + +AC_PREREQ([2.69]) + +AC_INIT(hh, 1.16, martin.dvorak@mindforger.com) +AC_CONFIG_FILES([Makefile src/Makefile man/Makefile]) + +# Checks for src dir existence. +AC_CONFIG_SRCDIR([src/hstr.c]) + +# Init (no longer takes parameters). +AM_INIT_AUTOMAKE + +# Checks for programs. +AC_PROG_CC + +# Mac specific ncurses check +# Unfortunately AC_CANONICAL_HOST macro cannot be used to +# detect Linux/Mac platform as it actives the use of config.sub/config.guess +# which doesn't work when building for launchpad (and @ launchpad) +AC_CHECK_LIB(ncurses, killwchar, [], [AC_MSG_ERROR([Could not find ncurses library])]) +AC_CHECK_HEADER(curses.h) + +# Checks for libraries. +AC_CHECK_LIB(m, cos, [], [AC_MSG_ERROR([Could not find m library])]) +AC_CHECK_LIB(readline, using_history, [], [AC_MSG_ERROR([Could not find readline library])]) + +# Checks for header files. +AC_CHECK_HEADER(assert.h) +AC_CHECK_HEADER(ctype.h) +AC_CHECK_HEADER(fcntl.h) +AC_CHECK_HEADER(getopt.h) +AC_CHECK_HEADER(locale.h) +AC_CHECK_HEADER(math.h) +AC_CHECK_HEADER(readline/history.h) +AC_CHECK_HEADER(regex.h) +AC_CHECK_HEADER(signal.h) +AC_CHECK_HEADER(stdbool.h) +AC_CHECK_HEADER(stddef.h) +AC_CHECK_HEADER(stdio.h) +AC_CHECK_HEADER(stdlib.h) +AC_CHECK_HEADER(string.h) +AC_CHECK_HEADER(sys/ioctl.h) +AC_CHECK_HEADER(termios.h) +AC_CHECK_HEADER(unistd.h) +AC_CHECK_HEADER(wchar.h) + +# Checks for typedefs, structures, and compiler characteristics. +AC_CHECK_HEADER_STDBOOL +AC_TYPE_SIZE_T + +# Checks for library functions. +AC_FUNC_MALLOC +AC_CHECK_FUNCS([memset strdup strstr]) + +AC_OUTPUT diff --git a/dist/ubuntu-make-all-distros.sh b/dist/ubuntu-make-all-distros.sh index b0af814..c45035c 100755 --- a/dist/ubuntu-make-all-distros.sh +++ b/dist/ubuntu-make-all-distros.sh @@ -1,8 +1,8 @@ #!/bin/bash -export HHBZRMSG="Enter first item auto-select, Vim keybinding, doc improvements." -export VERSION=1.15. -export MINOR=3 +export HHBZRMSG="History timestamps, Zsh support and management fixes." +export VERSION=1.16. +export MINOR=1 # precise quantal saucy / precise trusty utopic for DISTRO in trusty utopic