From owner-freebsd-bugs@FreeBSD.ORG Tue Oct 16 02:00:01 2012 Return-Path: Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 36ECDEB1 for ; Tue, 16 Oct 2012 02:00:01 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [8.8.178.135]) by mx1.freebsd.org (Postfix) with ESMTP id 0D5D38FC0C for ; Tue, 16 Oct 2012 02:00:01 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.5/8.14.5) with ESMTP id q9G200BY088141 for ; Tue, 16 Oct 2012 02:00:00 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id q9G2008X088140; Tue, 16 Oct 2012 02:00:00 GMT (envelope-from gnats) Resent-Date: Tue, 16 Oct 2012 02:00:00 GMT Resent-Message-Id: <201210160200.q9G2008X088140@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Joćo Rocha Braga Filho Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 7F7FAE93 for ; Tue, 16 Oct 2012 01:56:39 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from red.freebsd.org (red.freebsd.org [IPv6:2001:4f8:fff6::22]) by mx1.freebsd.org (Postfix) with ESMTP id 4D6148FC0A for ; Tue, 16 Oct 2012 01:56:39 +0000 (UTC) Received: from red.freebsd.org (localhost [127.0.0.1]) by red.freebsd.org (8.14.5/8.14.5) with ESMTP id q9G1udDB088846 for ; Tue, 16 Oct 2012 01:56:39 GMT (envelope-from nobody@red.freebsd.org) Received: (from nobody@localhost) by red.freebsd.org (8.14.5/8.14.5/Submit) id q9G1udFD088845; Tue, 16 Oct 2012 01:56:39 GMT (envelope-from nobody) Message-Id: <201210160156.q9G1udFD088845@red.freebsd.org> Date: Tue, 16 Oct 2012 01:56:39 GMT From: Joćo Rocha Braga Filho To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Subject: misc/172744: Where is ttyslot() (3) in FreeBSD 9.1? X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Oct 2012 02:00:01 -0000 >Number: 172744 >Category: misc >Synopsis: Where is ttyslot() (3) in FreeBSD 9.1? >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Tue Oct 16 02:00:00 UTC 2012 >Closed-Date: >Last-Modified: >Originator: Joćo Rocha Braga Filho >Release: 9.1-PRERELEASE #23 >Organization: >Environment: FreeBSD 9.1-PRERELEASE FreeBSD 9.1-PRERELEASE #23: Sat Oct 13 18:35:35 BRT 2012 goffredo@:/usr/obj/usr/src/sys/SUPER amd64 >Description: I had this problem compiling x11/sessre port: " ===> Building for sessreg-1.0.7 make all-recursive Making all in man GEN filenames.sed GEN sessreg.1 CC sessreg.o sessreg.c: In function 'main': sessreg.c:276: warning: assignment discards qualifiers from pointer target type sessreg.c:281: warning: implicit declaration of function 'ttyslot' sessreg.c:281: warning: nested extern declaration of 'ttyslot' sessreg.c: In function 'set_utmp': sessreg.c:387: warning: declaration of 'line' shadows a global declaration sessreg.c:93: warning: shadowed declaration is here sessreg.c: In function 'set_utmpx': sessreg.c:463: warning: declaration of 'line' shadows a global declaration sessreg.c:93: warning: shadowed declaration is here sessreg.c: In function 'Xslot': sessreg.c:556: warning: declaration of 'ttys_file' shadows a global declaration sessreg.c:113: warning: shadowed declaration is here sessreg.c:556: warning: declaration of 'host_name' shadows a global declaration sessreg.c:108: warning: shadowed declaration is here sessreg.c: In function 'findslot': sessreg.c:616: warning: declaration of 'host_name' shadows a global declaration sessreg.c:108: warning: shadowed declaration is here sessreg.c:632: warning: assignment discards qualifiers from pointer target type CCLD sessreg sessreg.o: In function `main': sessreg.c:(.text+0xc7a): undefined reference to `ttyslot' *** [sessreg] Error code 1 Stop in /usr/ports/x11/sessreg/work/sessreg-1.0.7. *** [all-recursive] Error code 1 Stop in /usr/ports/x11/sessreg/work/sessreg-1.0.7. *** [all] Error code 1 Stop in /usr/ports/x11/sessreg/work/sessreg-1.0.7. *** [do-build] Error code 1 Stop in /usr/ports/x11/sessreg. root:[172] " I found ttyslot in man page. Then I made a little thisprogram to test: " #include #include main() { printf( "%d\n",ttyslot() ); } " Result: " goffredo:[1004] cc -s -o ttyslot_test ttyslot_test.c /tmp//ccyJQC88.o: In function `main': ttyslot_test.c:(.text+0xa): undefined reference to `ttyslot' " I worked around downloading and installing the old package below: ftp://ftp.freebsd.org/pub/FreeBSD/releases/amd64/9.0-RELEASE/packages/x11/sessreg-1.0.7.tbz >How-To-Repeat: Compile this program: " #include #include main() { printf( "%d\n",ttyslot() ); } " >Fix: >Release-Note: >Audit-Trail: >Unformatted: