View | Details | Raw Unified | Return to bug 59212 | Differences between
and this patch

Collapse All | Expand All

(-)lineakd/Makefile (-7 / +23 lines)
Lines 2-16 Link Here
2
# Date created:				03 June 2002
2
# Date created:				03 June 2002
3
# Whom:					Kay Lehmann
3
# Whom:					Kay Lehmann
4
#
4
#
5
# $FreeBSD: ports/sysutils/lineakd/Makefile,v 1.1 2003/09/29 14:32:13 edwin Exp $
5
# $FreeBSD$
6
#
6
#
7
7
8
PORTNAME=	lineakd
8
PORTNAME=	lineakd
9
PORTVERSION=	0.4.p3
9
PORTVERSION=	0.7.2
10
CATEGORIES=	sysutils
10
CATEGORIES=	sysutils
11
MASTER_SITES=	${MASTER_SITE_SOURCEFORGE}
11
MASTER_SITES=	${MASTER_SITE_SOURCEFORGE}
12
MASTER_SITE_SUBDIR=lineak
12
MASTER_SITE_SUBDIR=lineak
13
DISTNAME=	${PORTNAME}-0.4pre3
14
13
15
MAINTAINER=	kay_lehmann@web.de
14
MAINTAINER=	kay_lehmann@web.de
16
COMMENT=	Lineakd is a daemon which enables special keys on internet keyboards
15
COMMENT=	Lineakd is a daemon which enables special keys on internet keyboards
Lines 18-35 Link Here
18
LIB_DEPENDS=	intl.5:${PORTSDIR}/devel/gettext
17
LIB_DEPENDS=	intl.5:${PORTSDIR}/devel/gettext
19
18
20
USE_BISON=	yes
19
USE_BISON=	yes
20
USE_AUTOCONF=	yes
21
USE_GMAKE=	yes
21
USE_GMAKE=	yes
22
USE_XLIB=	yes
22
USE_XLIB=	yes
23
GNU_CONFIGURE=	yes
23
GNU_CONFIGURE=	yes
24
24
25
CFLAGS+=	-I${X11BASE}/include
25
CFLAGS+=	-I${X11BASE}/include -L${X11BASE}/lib
26
27
.if defined(WITHOUT_XOSD)
28
CONFIGURE_ARGS+=--with-xosd=no
29
.else
30
LIB_DEPENDS+=	xosd.4:${PORTSDIR}/misc/xosd
31
.endif
26
32
27
.include <bsd.port.pre.mk>
33
.include <bsd.port.pre.mk>
28
34
29
EXTRA_PATCHES=  ${FILESDIR}/extra-patch-lineakd.c-4
35
.if ${OSVERSION} < 500000
36
EXTRA_PATCHES=	${FILESDIR}/extra-patch-lineakd__soundctrl_cpp-4
37
.endif
38
39
PORTDOCS=	INSTALL README TODO AUTHORS
30
40
31
.if ${OSVERSION} >= 500000
41
post-install:
32
EXTRA_PATCHES=	${FILESDIR}/extra-patch-lineakd.c-5
42
.if !defined(NOPORTDOCS)
43
	@${MKDIR} ${DOCSDIR}
44
.for i in ${PORTDOCS}
45
	${INSTALL_DATA} ${WRKSRC}/${i} ${DOCSDIR}
46
.endfor
33
.endif
47
.endif
48
	@${MKDIR} ${EXAMPLESDIR}
49
	${INSTALL_DATA} ${WRKSRC}/lineakd.conf.example ${EXAMPLESDIR}
34
50
35
.include <bsd.port.post.mk>
51
.include <bsd.port.post.mk>
(-)lineakd/distinfo (-1 / +1 lines)
Line 1 Link Here
1
MD5 (lineakd-0.4pre3.tar.gz) = 4606ec63a8af63aa9086395f9be42cba
1
MD5 (lineakd-0.7.2.tar.gz) = 986b947ce4f6e3dfa60fd66b4d26ea18
(-)lineakd/files/extra-patch-lineakd.c-4 (-68 lines)
Lines 1-68 Link Here
1
--- src/lineakd.c.orig	Fri Sep  6 02:50:29 2002
2
+++ src/lineakd.c	Tue May 13 10:53:21 2003
3
@@ -57,18 +57,19 @@
4
 #endif
5
 #include <fcntl.h>
6
 #include <sys/ioctl.h>
7
-#include <linux/cdrom.h> /* linux specific?!! */
8
 
9
 extern int mkdir(); /* in linux/fs.h ... other platforms!? */
10
 
11
 #if defined (__FreeBSD__)
12
 # include <machine/soundcard.h>
13
+# include <sys/cdio.h>
14
 #else
15
 # if defined (__NetBSD__) || defined (__OpenBSD__)
16
 #  include <soundcard.h>          /* OSS emulation */
17
 #  undef ioctl
18
 # else
19
 /* BSDI, Linux, Solaris */
20
+#  include <linux/cdrom.h> /* linux specific?!! */
21
 #  include <sys/soundcard.h>
22
 # endif
23
 #endif
24
@@ -100,7 +101,7 @@
25
   signal(SIGABRT, signalexit);
26
   signal(SIGINT, signalexit);
27
   /* and one so we won't have to wait() for child processes ;) */
28
-  signal(SIGCLD, SIG_IGN);
29
+  signal(SIGCHLD, SIG_IGN);
30
   /* and for a rehash when we catch SIGHUP */
31
   signal(SIGHUP,signalHUP);
32
   
33
@@ -598,12 +599,12 @@
34
 	/* try to open the device .. */
35
     if ( (fp = open(cdromdev, O_RDONLY | O_NONBLOCK)) != -1 ) {
36
 	  /* tell the drive to diable auto-eject */
37
-	  if ( (ioctl(fp, CDROMEJECT_SW, 0)) == -1 )
38
-        printf("... oops! error during CD-ROM init\n");
39
-	  close(fp);
40
-	} else {
41
+       if ( (ioctl(fp, CDIOCPREVENT)) == -1 )
42
+       printf("... oops! error during CD-ROM init\n");
43
+	 close(fp);
44
+         } else {
45
 	  printf("... oops! unable to open the CD-ROM device \"%s\" (CD-ROM init)\n",cdromdev);
46
-	}
47
+	  }
48
   } else {
49
 	printf("no CD-ROM device configured! (CD-ROM init)\n");
50
   }
51
@@ -618,7 +619,7 @@
52
     if ( (fp = open(cdromdev, O_RDONLY | O_NONBLOCK)) != -1 ) {
53
 	  if (!cdromstatus) { /* assumed closed */
54
 		/* enable the drives software eject */
55
-		if ( (ioctl(fp, CDROMEJECT_SW, 1)) == -1 )
56
+		if ( (ioctl(fp, CDIOCALLOW)) == -1 )
57
           printf("... oops! error enabling CD-ROM SW eject\n");
58
 		/* eject the cdrom tray */
59
 		if (verbosemode) printf("... ejecting the CD-ROM tray\n");
60
@@ -628,7 +629,7 @@
61
 		  cdromstatus = !cdromstatus;
62
 	  } else { /* assumed open */
63
         /* disable the drives software eject again.. */
64
-        if ( (ioctl(fp, CDROMEJECT_SW, 0)) == -1 )
65
+        if ( (ioctl(fp, CDIOCPREVENT)) == -1 )
66
           printf("... oops! error disabling CD-ROM SW eject\n");
67
 		/* close the cdrom tray */
68
 		if (verbosemode) printf("... closing the CD-ROM tray\n");
(-)lineakd/files/extra-patch-lineakd.c-5 (-69 lines)
Lines 1-69 Link Here
1
--- src/lineakd.c.orig	Fri Sep  6 02:50:29 2002
2
+++ src/lineakd.c	Sat May 24 18:01:00 2003
3
@@ -57,18 +57,19 @@
4
 #endif
5
 #include <fcntl.h>
6
 #include <sys/ioctl.h>
7
-#include <linux/cdrom.h> /* linux specific?!! */
8
 
9
 extern int mkdir(); /* in linux/fs.h ... other platforms!? */
10
 
11
 #if defined (__FreeBSD__)
12
-# include <machine/soundcard.h>
13
+# include <sys/soundcard.h>
14
+# include <sys/cdio.h>
15
 #else
16
 # if defined (__NetBSD__) || defined (__OpenBSD__)
17
 #  include <soundcard.h>          /* OSS emulation */
18
 #  undef ioctl
19
 # else
20
 /* BSDI, Linux, Solaris */
21
+#  include <linux/cdrom.h> /* linux specific?!! */
22
 #  include <sys/soundcard.h>
23
 # endif
24
 #endif
25
@@ -100,7 +101,7 @@
26
   signal(SIGABRT, signalexit);
27
   signal(SIGINT, signalexit);
28
   /* and one so we won't have to wait() for child processes ;) */
29
-  signal(SIGCLD, SIG_IGN);
30
+  signal(SIGCHLD, SIG_IGN);
31
   /* and for a rehash when we catch SIGHUP */
32
   signal(SIGHUP,signalHUP);
33
   
34
@@ -598,12 +599,12 @@
35
 	/* try to open the device .. */
36
     if ( (fp = open(cdromdev, O_RDONLY | O_NONBLOCK)) != -1 ) {
37
 	  /* tell the drive to diable auto-eject */
38
-	  if ( (ioctl(fp, CDROMEJECT_SW, 0)) == -1 )
39
-        printf("... oops! error during CD-ROM init\n");
40
-	  close(fp);
41
-	} else {
42
+       if ( (ioctl(fp, CDIOCPREVENT)) == -1 )
43
+       printf("... oops! error during CD-ROM init\n");
44
+	 close(fp);
45
+         } else {
46
 	  printf("... oops! unable to open the CD-ROM device \"%s\" (CD-ROM init)\n",cdromdev);
47
-	}
48
+	  }
49
   } else {
50
 	printf("no CD-ROM device configured! (CD-ROM init)\n");
51
   }
52
@@ -618,7 +619,7 @@
53
     if ( (fp = open(cdromdev, O_RDONLY | O_NONBLOCK)) != -1 ) {
54
 	  if (!cdromstatus) { /* assumed closed */
55
 		/* enable the drives software eject */
56
-		if ( (ioctl(fp, CDROMEJECT_SW, 1)) == -1 )
57
+		if ( (ioctl(fp, CDIOCALLOW)) == -1 )
58
           printf("... oops! error enabling CD-ROM SW eject\n");
59
 		/* eject the cdrom tray */
60
 		if (verbosemode) printf("... ejecting the CD-ROM tray\n");
61
@@ -628,7 +629,7 @@
62
 		  cdromstatus = !cdromstatus;
63
 	  } else { /* assumed open */
64
         /* disable the drives software eject again.. */
65
-        if ( (ioctl(fp, CDROMEJECT_SW, 0)) == -1 )
66
+        if ( (ioctl(fp, CDIOCPREVENT)) == -1 )
67
           printf("... oops! error disabling CD-ROM SW eject\n");
68
 		/* close the cdrom tray */
69
 		if (verbosemode) printf("... closing the CD-ROM tray\n");
(-)lineakd/files/patch-aa (-14 / +12 lines)
Lines 1-15 Link Here
1
--- src/lineakd.h.orig	Wed Aug 28 04:43:19 2002
1
--- lineakd/cdromctrl.cpp.orig	Wed Nov 12 10:08:14 2003
2
+++ src/lineakd.h	Tue May 13 10:56:23 2003
2
+++ lineakd/cdromctrl.cpp	Wed Nov 12 10:08:58 2003
3
@@ -127,6 +127,12 @@
3
@@ -23,8 +23,8 @@
4
 #define VOLMUTE_VALUE 0
4
 #include <sys/ioctl.h>
5
 #define MAX_VOLUME 100
5
 #if defined (__FreeBSD__)
6
 
6
 	# include <sys/cdio.h>
7
+/* we need this for freebsd */
7
-	#define CDROMEJECT     CDIOCEJECT      /*_IO('c', 107)*/
8
+#if defined (__FreeBSD__)
8
-	#define CDROMCLOSETRAY  CDIOCCLOSE
9
+#define CDROMEJECT	CDIOCEJECT	/*_IO('c', 107)*/
9
+#define CDROMEJECT  CDIOCEJECT
10
+#define CDROMCLOSETRAY  CDIOCCLOSE
10
+#define CDROMCLOSETRAY  CDIOCCLOSE
11
+#endif
11
 #else
12
+
12
 	#include <linux/cdrom.h> /* linux specific?!! */
13
 /* we might need this .. oss emulation under BSD */
13
 #endif
14
 #if defined (__NetBSD__) || defined (__OpenBSD__)
15
 #define SOUND_IOCTL(a,b,c)      _oss_ioctl(a,b,c)
(-)lineakd/files/patch-cc (-16 lines)
Lines 1-16 Link Here
1
--- intl/dcigettext.c.orig	Sat Jun  8 21:56:27 2002
2
+++ intl/dcigettext.c	Tue May 13 10:56:23 2003
3
@@ -58,11 +58,11 @@
4
 #include <stdlib.h>
5
 
6
 #include <string.h>
7
-#if !HAVE_STRCHR && !defined _LIBC
8
+/*#if !HAVE_STRCHR && !defined _LIBC
9
 # ifndef strchr
10
 #  define strchr index
11
 # endif
12
-#endif
13
+#endif*/
14
 
15
 #if defined HAVE_UNISTD_H || defined _LIBC
16
 # include <unistd.h>
(-)lineakd/files/patch-dd (-11 lines)
Lines 1-11 Link Here
1
--- Makefile.in.orig	Thu May 15 16:05:33 2003
2
+++ Makefile.in	Thu May 15 16:06:13 2003
3
@@ -112,7 +112,7 @@
4
 
5
 SUBDIRS = intl po  src 
6
 
7
-lineakddocdir = ${prefix}/doc/lineakd
8
+lineakddocdir = ${prefix}/share/doc/lineakd
9
 lineakddoc_DATA = \
10
 	README\
11
 	COPYING\
(-)lineakd/files/patch-ee (-28 lines)
Lines 1-28 Link Here
1
--- Makefile.orig	Thu May 15 16:09:02 2003
2
+++ Makefile	Thu May 15 16:10:10 2003
3
@@ -83,14 +83,14 @@
4
 LTLIBINTL = 
5
 MKINSTALLDIRS = ./mkinstalldirs
6
 NO_PREFIX_PACKAGE_DATA_DIR = share/lineakd
7
-NO_PREFIX_PACKAGE_DOC_DIR = doc/lineakd
8
+NO_PREFIX_PACKAGE_DOC_DIR = share/doc/lineakd
9
 NO_PREFIX_PACKAGE_HELP_DIR = share/lineakd/help
10
 NO_PREFIX_PACKAGE_MENU_DIR = share/lineakd
11
 NO_PREFIX_PACKAGE_PIXMAPS_DIR = share/lineakd/pixmaps
12
 OBJEXT = o
13
 PACKAGE = lineakd
14
 PACKAGE_DATA_DIR = /usr/local/share/lineakd
15
-PACKAGE_DOC_DIR = /usr/local/doc/lineakd
16
+PACKAGE_DOC_DIR = /usr/local/share/doc/lineakd
17
 PACKAGE_HELP_DIR = /usr/local/share/lineakd/help
18
 PACKAGE_MENU_DIR = /usr/local/share/lineakd
19
 PACKAGE_PIXMAPS_DIR = /usr/local/share/lineakd/pixmaps
20
@@ -112,7 +112,7 @@
21
 
22
 SUBDIRS = intl po  src 
23
 
24
-lineakddocdir = ${prefix}/doc/lineakd
25
+lineakddocdir = ${prefix}/share/doc/lineakd
26
 lineakddoc_DATA = \
27
 	README\
28
 	COPYING\
(-)lineakd/pkg-plist (-11 / +1 lines)
Lines 1-13 Link Here
1
bin/lineakd
1
bin/lineakd
2
etc/lineakkb.def
2
etc/lineakkb.def
3
lib/charset.alias
3
%%EXAMPLESDIR%%/lineakd.conf.example
4
share/locale/locale.alias
5
share/doc/lineakd/README
6
share/doc/lineakd/COPYING
7
share/doc/lineakd/AUTHORS
8
share/doc/lineakd/ChangeLog
9
share/doc/lineakd/INSTALL
10
share/doc/lineakd/NEWS
11
share/doc/lineakd/TODO
12
share/doc/lineakd/ABOUT-NLS
13
@dirrm share/doc/lineakd

Return to bug 59212