head 1.14; access; symbols pkgsrc-2013Q2:1.14.0.36 pkgsrc-2013Q2-base:1.14 pkgsrc-2012Q4:1.14.0.34 pkgsrc-2012Q4-base:1.14 pkgsrc-2011Q4:1.14.0.32 pkgsrc-2011Q4-base:1.14 pkgsrc-2011Q2:1.14.0.30 pkgsrc-2011Q2-base:1.14 pkgsrc-2009Q4:1.14.0.28 pkgsrc-2009Q4-base:1.14 pkgsrc-2008Q4:1.14.0.26 pkgsrc-2008Q4-base:1.14 pkgsrc-2008Q3:1.14.0.24 pkgsrc-2008Q3-base:1.14 cube-native-xorg:1.14.0.22 cube-native-xorg-base:1.14 pkgsrc-2008Q2:1.14.0.20 pkgsrc-2008Q2-base:1.14 pkgsrc-2008Q1:1.14.0.18 pkgsrc-2008Q1-base:1.14 pkgsrc-2007Q4:1.14.0.16 pkgsrc-2007Q4-base:1.14 pkgsrc-2007Q3:1.14.0.14 pkgsrc-2007Q3-base:1.14 pkgsrc-2007Q2:1.14.0.12 pkgsrc-2007Q2-base:1.14 pkgsrc-2007Q1:1.14.0.10 pkgsrc-2007Q1-base:1.14 pkgsrc-2006Q4:1.14.0.8 pkgsrc-2006Q4-base:1.14 pkgsrc-2006Q3:1.14.0.6 pkgsrc-2006Q3-base:1.14 pkgsrc-2006Q2:1.14.0.4 pkgsrc-2006Q2-base:1.14 pkgsrc-2006Q1:1.14.0.2 pkgsrc-2006Q1-base:1.14 pkgsrc-2005Q4:1.13.0.2 pkgsrc-2005Q4-base:1.13 pkgsrc-2005Q3:1.9.0.16 pkgsrc-2005Q3-base:1.9 pkgsrc-2005Q2:1.9.0.14 pkgsrc-2005Q2-base:1.9 pkgsrc-2005Q1:1.9.0.12 pkgsrc-2005Q1-base:1.9 pkgsrc-2004Q4:1.9.0.10 pkgsrc-2004Q4-base:1.9 pkgsrc-2004Q3:1.9.0.8 pkgsrc-2004Q3-base:1.9 pkgsrc-2004Q2:1.9.0.6 pkgsrc-2004Q2-base:1.9 pkgsrc-2004Q1:1.9.0.4 pkgsrc-2004Q1-base:1.9 pkgsrc-2003Q4:1.9.0.2 pkgsrc-2003Q4-base:1.9 netbsd-1-6-1:1.8.0.6 netbsd-1-6-1-base:1.8 netbsd-1-6:1.8.0.8 netbsd-1-6-RELEASE-base:1.8 pkgviews:1.8.0.4 pkgviews-base:1.8 buildlink2:1.8.0.2 buildlink2-base:1.8 netbsd-1-5-PATCH003:1.8 netbsd-1-5-PATCH001:1.7 netbsd-1-5-RELEASE:1.6 netbsd-1-4-PATCH003:1.6 netbsd-1-4-PATCH002:1.5 comdex-fall-1999:1.5 netbsd-1-4-PATCH001:1.5 netbsd-1-4-RELEASE:1.4 netbsd-1-3-PATCH003:1.3; locks; strict; comment @# @; 1.14 date 2005.12.31.00.07.03; author wiz; state dead; branches; next 1.13; 1.13 date 2005.11.08.18.05.23; author reed; state Exp; branches; next 1.12; 1.12 date 2005.11.08.14.42.10; author joerg; state Exp; branches; next 1.11; 1.11 date 2005.11.08.13.20.45; author joerg; state Exp; branches; next 1.10; 1.10 date 2005.09.30.22.02.56; author wiz; state dead; branches; next 1.9; 1.9 date 2003.10.08.03.01.32; author danw; state Exp; branches; next 1.8; 1.8 date 2001.06.19.15.53.11; author jlam; state Exp; branches; next 1.7; 1.7 date 2000.10.31.16.26.34; author jlam; state Exp; branches; next 1.6; 1.6 date 2000.07.28.20.30.11; author jlam; state Exp; branches; next 1.5; 1.5 date 99.07.06.08.04.15; author jlam; state Exp; branches; next 1.4; 1.4 date 99.01.04.20.47.31; author frueauf; state Exp; branches; next 1.3; 1.3 date 98.08.07.11.10.13; author agc; state Exp; branches; next 1.2; 1.2 date 98.06.30.16.33.49; author tron; state Exp; branches; next 1.1; 1.1 date 98.05.26.22.07.19; author tron; state Exp; branches; next ; desc @@ 1.14 log @Update to 1.0.20051219: 2005/12/19 + correct return-values of new functions dlg_default_listitem() and dlg_default_formitem() (Debian #344002). + add Swedish translation (Debian #343303, by Daniel Nylander) + begin function-summaries in dialog.3 + update config.guess, config.sub 2005/12/07 + change license to LGPL. + change naming convention in dlg_colors.h to make it easier to read, and incidentally remove the last chunk of code preventing relicense. + add --passwordform (request by Reznic Valery). + modify pause.c, msgbox.c to work with --help-button. + modify formbox.c, inputbox.c, textbox.c, yesno.c to work with extra button (adapted from Reznic Valery patch). + modify dlg_exit_label(), dlg_yes_labels() and dlg_ok_label() to allow help-button (prompted by Reznic Valery patch). + add zh_CN.po file from http://www.iro.umontreal.ca/translation/maint/dialog/ + provide alternate interfaces for dialog_checklist(), dialog_menu() and dialog_form(): dlg_checklist(), dlg_menu() and dlg_form() (discussion with Michael Gebetsroither). + add/use dlg_result_key() to allow binding function keys to the buttons. + implement user-definable key bindings in the rc-file. + modify inline cases for KEY_xxx values to use binding tables in new module dlg_keys.c + add several DIALOG_STATE items to the rc file: aspect, separate_widget, tab_len and visit_links + add a tab-adjustment to dlg_print_text() to improve solution from 2005/10/30, e.g., in the samples/form* scripts. + fix an off-by-one which made mouse-selection not work for menu items past the first page (GenToo #112024, patch by Harald van Dijk). 2005/11/07 + extend dlg_add_result() to allow caller to pass a null pointer for dialog_vars.input_result (Debian #336986). + correct length used for text portion of radio/checkboxes (report by Valentin Stoykov). + modify msgbox, textbox and center_label() to work properly for LANG=bg_BG.utf8 examples by Valentin Stoykov. + modify use of freopen() to work with opaque FILE type on DragonFly (report by Jeremy C Reed). + modify print_line() to compute columns, use that for the call to dlg_print_line(). Fix a few places where strlen() was used instead of dlg_count_columns() (reports by Valentin Stoykov). 2005/10/30 + reviewed changes since beginning development in 1999, decided that there are no appreciable portions of original code remaining. Marked sources to correspond. + improve cache performance for inputstr.c using tsearch() rather than a linked-list search (Debian #294853). + remove a special case for darwin in CF_XOPEN_SOURCE configure macro. + add ms.po file from http://www.iro.umontreal.ca/translation/maint/dialog/ + remove an assignment that caused the cursor to appear initially on a form field rather than button (Debian #333506). + modify buttons.c to count columns rather than bytes, fixing case where buttons were laid out incorrectly (report by Valentin Stoykov). + change dlg_print_text() to count columns rather than bytes, fixing case where fewer columns were displayed in menu than expected (report by Valentin Stoykov). 2005/10/05 + improve fix for dlg_does_output(), eliminating redundant leading separator. + fill background color for item-help text (report by Peter Postma). + correct interaction between --separate-output and --output-separator broken in 2005/09/11 fix for Debian #326918 (Debian #331440). + update config.guess, config.sub @ text @$NetBSD: patch-aa,v 1.13 2005/11/08 18:05:23 reed Exp $ --- util.c.orig 2005-10-30 12:15:17.000000000 -0800 +++ util.c 2005-10-31 15:55:28.000000000 -0800 @@@@ -264,7 +264,8 @@@@ if ((fd1 = open_terminal(&device, O_RDONLY)) >= 0 && (fd2 = dup(fileno(stdin))) >= 0) { dialog_state.pipe_input = fdopen(fd2, "r"); - *stdin = *freopen(device, "r", stdin); + if (freopen(device, "r", stdin) == 0) + dlg_exiterr("cannot open tty-input"); if (fileno(stdin) != 0) /* some functions may read fd #0 */ (void) dup2(fileno(stdin), 0); } @ 1.13 log @Use patch from Thomas Dickey for this "tty-input". (Not bumping PKGREVISION, since it was bumped today for similar patch.) @ text @d1 1 a1 1 $NetBSD$ @ 1.12 log @Unbreak build on NetBSD, C says that stdio is not a modificable lvalue. Infact, the LHS is not needed at all. @ text @d1 1 a1 1 $NetBSD: patch-aa,v 1.11 2005/11/08 13:20:45 joerg Exp $ d3 3 a5 3 --- util.c.orig 2005-11-08 13:00:19.000000000 +0000 +++ util.c @@@@ -262,7 +262,7 @@@@ init_dialog(FILE *input, FILE *output) d10 2 a11 1 + freopen(device, "r", stdin); @ 1.11 log @Fix another stupid program, which assumes that *stdin =*reopen() is ever likely to work. @ text @d1 1 a1 1 $NetBSD$ d10 1 a10 1 + stdin = freopen(device, "r", stdin); @ 1.10 log @Update to 1.0.20050911. Changes since 1997 (or 1995?) are too many to mention here, see http://dickey.his.com/dialog/CHANGES for details. Closes PR pkg/30856. @ text @d1 1 a1 1 $NetBSD: patch-aa,v 1.9 2003/10/08 03:01:32 danw Exp $ d3 11 a13 74 --- Makefile.orig Thu Jan 9 01:19:34 1997 +++ Makefile Tue Oct 7 22:51:21 2003 @@@@ -17,21 +17,19 @@@@ # can be disabled to make dialog a bit smaller (could be done for more things) HAVE_GUAGE=true -BINDIR = /usr/bin -MANDIR = /usr/man/man1/ +BINDIR = ${PREFIX}/bin +MANDIR = ${PREFIX}/man/man1 -CC = gcc -CPP = gcc -E -OPTIM = -O2 -Wall -Wstrict-prototypes -fomit-frame-pointer -pipe +#CC = gcc +CPP = $(CC) -E +#OPTIM = -O2 -Wall -Wstrict-prototypes -fomit-frame-pointer -pipe #OPTIM = -O -Wall -Wstrict-prototypes -g -pipe # end of the configuration part #---------------------------------------------------------------------------- # do not edit below this line -CFLAGS = $(OPTIM) -DLOCALE -DVERSION=\"0.6z\" -LDFLAGS = -L . -LDLIBS = -ldialog +CFLAGS += $(OPTIM) -DLOCALE -DVERSION=\"0.6z\" OBJS = checklist.o inputbox.o menubox.o msgbox.o \ textbox.o util.o yesno.o @@@@ -42,7 +40,7 @@@@ OBJS+=mouse.o endif ifeq ($(HAVE_NCURSES), true) -CFLAGS+=-DHAVE_NCURSES -I/usr/include/ncurses +CFLAGS+=-DHAVE_NCURSES LDLIBS+=-lncurses endif ifeq ($(HAVE_RC_FILE), true) @@@@ -56,12 +54,9 @@@@ SRCS = $(OBJS:.o=.c) -all: libdialog.a dialog +all: dialog -libdialog.a: $(OBJS) - ar rcs libdialog.a $(OBJS) - -dialog: dialog.o +dialog: dialog.o $(OBJS) clean: rm -f core *.o *~ dialog .depend libdialog.a dialog.1 dialog.in @@@@ -69,8 +64,8 @@@@ include .depend -install: dialog libdialog.a - install -s dialog $(BINDIR) +install: dialog + ${BSD_INSTALL_PROGRAM} dialog $(BINDIR) cp dialog.man dialog.1 ifeq ($(HAVE_RC_FILE),false) mv dialog.1 dialog.in @@@@ -82,7 +77,7 @@@@ endif mv dialog.1 dialog.in sed -e "/COMMENTSTART/,/COMMENTEND/d" dialog.in >dialog.1 - install -m 644 dialog.1 $(MANDIR) + ${BSD_INSTALL_MAN} dialog.1 $(MANDIR) # install -m 644 libdialog.a /usr/lib/ depend: @ 1.9 log @Since we're already patching Makefile to not install libdialog.a, patch it further to not even build it, and just link the objects in directly, to save us from having to drag in libtool so the library gets ranlibbed properly on darwin. PR 20487 @ text @d1 1 a1 1 $NetBSD$ @ 1.8 log @Convert to use buildlink.mk files and mark as USE_BUILDLINK_ONLY. By using ncurses/buildlink.mk, we can refer to the ncurses header as ncurses.h and the ncurses lib as libncurses. @ text @d4 2 a5 2 +++ Makefile @@@@ -17,20 +17,20 @@@@ d28 1 a29 2 +LDFLAGS += -L . LDLIBS = -ldialog d32 2 a33 1 @@@@ -42,7 +42,7 @@@@ d42 1 a42 2 @@@@ -59,7 +59,7 @@@@ all: libdialog.a dialog d44 6 a49 1 libdialog.a: $(OBJS) d51 7 a57 3 + ar rc libdialog.a $(OBJS) dialog: dialog.o a58 1 @@@@ -70,7 +70,7 @@@@ d61 1 a61 1 install: dialog libdialog.a d63 1 d68 1 a68 1 @@@@ -82,7 +82,7 @@@@ @ 1.7 log @Respect CFLAGS passed in from environment @ text @d5 1 a5 1 @@@@ -17,8 +17,8 @@@@ d14 9 a22 3 CC = gcc CPP = gcc -E @@@@ -29,8 +29,8 @@@@ d29 1 a29 1 +LDFLAGS += -L . -L${LOCALBASE}/lib d33 1 a33 1 @@@@ -42,8 +42,13 @@@@ a38 3 +endif +ifeq ($(HAVE_TRUE_NCURSES), true) +CFLAGS+=-DHAVE_TRUE_NCURSES -I${LOCALBASE}/include a39 2 +else +LDLIBS+=-lcurses d42 1 a42 2 CFLAGS+=-DHAVE_RC_FILE @@@@ -59,7 +64,7 @@@@ d51 1 a51 1 @@@@ -70,7 +75,7 @@@@ d60 1 a60 1 @@@@ -82,7 +87,7 @@@@ @ 1.6 log @Make use of new USE_CURSES functionality. @ text @d4 1 a4 1 +++ Makefile Fri Jul 28 15:30:22 2000 d16 2 a17 1 @@@@ -30,7 +30,7 @@@@ d20 1 a20 1 CFLAGS = $(OPTIM) -DLOCALE -DVERSION=\"0.6z\" d22 1 @ 1.5 log @ * Update ncurses dependency. @ text @d4 1 a4 1 +++ Makefile Fri Jul 2 08:27:09 1999 d25 1 a25 1 @@@@ -42,7 +42,7 @@@@ d30 4 a33 1 +CFLAGS+=-DHAVE_NCURSES -I${LOCALBASE}/include d35 2 d39 2 a40 1 @@@@ -59,7 +59,7 @@@@ d49 1 a49 1 @@@@ -70,7 +70,7 @@@@ d58 1 a58 1 @@@@ -82,7 +82,7 @@@@ @ 1.4 log @Make dialog work on ELF too. @ text @d3 2 a4 2 --- Makefile.orig Thu Jan 9 07:19:34 1997 +++ Makefile Mon Jan 4 20:39:17 1999 d21 1 a21 1 +LDFLAGS = -Wl,-R${PREFIX}/lib -L . -L${PREFIX}/lib d25 1 a25 1 @@@@ -42,7 +42,8 @@@@ d30 1 a30 2 +#CFLAGS+=-DHAVE_NCURSES -I/usr/include/ncurses +CFLAGS+=-DHAVE_NCURSES -I${PREFIX}/include d34 1 a34 1 @@@@ -59,7 +60,7 @@@@ d43 1 a43 1 @@@@ -70,7 +71,7 @@@@ d52 1 a52 1 @@@@ -82,7 +83,7 @@@@ @ 1.3 log @Add NetBSD RCS Ids. @ text @d4 1 a4 1 +++ Makefile Tue Jun 30 18:29:59 1998 d21 1 a21 1 +LDFLAGS = -L . -L${PREFIX}/lib @ 1.2 log @Use "-I${PREFIX}/include" not "-I/usr/pkg/include". @ text @d1 2 @ 1.1 log @New "dialog" package supplied by Johnny C. Lam in PR pkg/4993. @ text @d2 1 a2 1 +++ Makefile Tue May 26 23:53:37 1998 d29 1 a29 1 +CFLAGS+=-DHAVE_NCURSES -I/usr/pkg/include @