Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GNU/Hurd and GNU/*BSD patch #838

Closed
michaelrsweet opened this issue Aug 5, 2004 · 4 comments
Closed

GNU/Hurd and GNU/*BSD patch #838

michaelrsweet opened this issue Aug 5, 2004 · 4 comments
Labels
enhancement New feature or request
Milestone

Comments

@michaelrsweet
Copy link
Collaborator

Version: 1.1-current
CUPS.org User: kmuto.debian

Hi,

I received a patch for GNU/Hurd (and GNU/k*BSD) ready from Robert Millan rmh@debian.org.

I saw this and looks work and doesn't corrupt anything.

Thanks,

@michaelrsweet
Copy link
Collaborator Author

CUPS.org User: mike

Note: their patch is incorrect - it tests for sigset on Linux and GNU HURD instead of testing on all platforms except Linux and GNU HURD.

Also, I've simplified things a bit - see the attached patch.

@michaelrsweet
Copy link
Collaborator Author

CUPS.org User: mike

Fixed in CVS - the anonymous CVS repository will be updated at midnight EST.

@michaelrsweet
Copy link
Collaborator Author

"hurd.patch":

diff -ur cupsys-1.1.20final+rc1.old/config-scripts/cups-common.m4 cupsys-1.1.20final+rc1/config-scripts/cups-common.m4
--- cupsys-1.1.20final+rc1.old/config-scripts/cups-common.m4 2004-02-26 17:52:00.000000000 +0100
+++ cupsys-1.1.20final+rc1/config-scripts/cups-common.m4 2004-08-04 21:24:43.000000000 +0200
@@ -156,9 +156,9 @@
AC_CHECK_FUNCS(vsyslog)

dnl Checks for signal functions.
-if test "$uname" != "Linux"; then

  • AC_CHECK_FUNCS(sigset)
    -fi
    +case $uname in Linux|GNU|GNU/*)
  • AC_CHECK_FUNCS(sigset) ;;
    +esac

AC_CHECK_FUNCS(sigaction)

diff -ur cupsys-1.1.20final+rc1.old/config-scripts/cups-directories.m4 cupsys-1.1.20final+rc1/config-scripts/cups-directories.m4
--- cupsys-1.1.20final+rc1.old/config-scripts/cups-directories.m4 2004-02-26 17:52:00.000000000 +0100
+++ cupsys-1.1.20final+rc1/config-scripts/cups-directories.m4 2004-08-04 21:25:27.000000000 +0200
@@ -115,7 +115,7 @@
INITDDIR="/System/Library/StartupItems/PrintingServices"
;;

  •   Linux*)
    
  •   Linux_|GNU_|GNU/*)
        # Linux seems to choose an init.d directory at random...
        if test -d /sbin/init.d; then
            # SuSE
    
    @@ -173,6 +173,9 @@
    AC_DEFINE_UNQUOTED(CUPS_LOGDIR, "$logdir")
    fi

+dnl Prevent GNU/k_BSD from matching the BSD rule below
+case "$uname" in GNU/_) uname=GNU ;; esac
+
dnl See what directory to put server executables...
case "$uname" in
BSD | Darwin
)
@@ -197,7 +200,7 @@

dnl Set the CUPS_LOCALE directory...
case "$uname" in

  • Linux* | BSD | Darwin*)
  • Linux* | GNU* | GNU/* | BSD | Darwin*)
    CUPS_LOCALEDIR="$datadir/locale"
    AC_DEFINE_UNQUOTED(CUPS_LOCALEDIR, "$datadir/locale")
    ;;
    diff -ur cupsys-1.1.20final+rc1.old/config-scripts/cups-manpages.m4 cupsys-1.1.20final+rc1/config-scripts/cups-manpages.m4
    --- cupsys-1.1.20final+rc1.old/config-scripts/cups-manpages.m4 2004-02-26 17:52:00.000000000 +0100
    +++ cupsys-1.1.20final+rc1/config-scripts/cups-manpages.m4 2004-08-04 21:25:53.000000000 +0200
    @@ -25,7 +25,7 @@
    dnl Fix "mandir" variable...
    if test "$mandir" = "${prefix}/man" -a "$prefix" = "/"; then
    case "$uname" in
  •       Darwin\* | Linux\* | _BSD_ | AIX*)
    
  •       Darwin\* | Linux\* | GNU\* | GNU/\* | _BSD_ | AIX*)
            # Darwin, MacOS X, Linux, *BSD, and AIX
            mandir="/usr/share/man"
            AMANDIR="/usr/share/man"
    
    diff -ur cupsys-1.1.20final+rc1.old/config-scripts/cups-sharedlibs.m4 cupsys-1.1.20final+rc1/config-scripts/cups-sharedlibs.m4
    --- cupsys-1.1.20final+rc1.old/config-scripts/cups-sharedlibs.m4 2004-02-26 17:52:00.000000000 +0100
    +++ cupsys-1.1.20final+rc1/config-scripts/cups-sharedlibs.m4 2004-08-04 21:23:00.000000000 +0200
    @@ -47,7 +47,7 @@
    DSO="$(CC)"
    DSOFLAGS="$DSOFLAGS -Wl,-rpath,$(libdir),-set_version,sgi2.5,-soname,$@ -shared $(OPTIM)"
    ;;
  •   OSF1\* | Linux\* | _BSD_)
    
  •   OSF1\* | Linux\* | _BSD_ | GNU\* | GNU/*)
        LIBCUPS="libcups.so.2"
        LIBCUPSIMAGE="libcupsimage.so.2"
        DSO="\$(CC)"
    
    @@ -135,7 +135,7 @@
    LDFLAGS="$LDFLAGS -Wl,-R$libdir"
    EXPORT_LDFLAGS="-Wl,-R$libdir"
    ;;
  •            Linux*)
    
  •            Linux\* | GNU\* | GNU/*)
                     # Linux
                DSOFLAGS="-Wl,-rpath,$libdir $DSOFLAGS"
                     LDFLAGS="$LDFLAGS -Wl,-rpath,$libdir"
    

@michaelrsweet
Copy link
Collaborator Author

"str838.patch":

Index: cups-common.m4

RCS file: /development/cvs/cups/config-scripts/cups-common.m4,v
retrieving revision 1.46
diff -u -r1.46 cups-common.m4
--- cups-common.m4 2 Jul 2004 04:44:19 -0000 1.46
+++ cups-common.m4 11 Aug 2004 14:37:14 -0000
@@ -138,7 +138,7 @@
AC_MSG_CHECKING(for correct format string to use with strftime)

case "$uname" in

  • IRIX* | SunOS*)
  • IRIX | SunOS*)

    IRIX and SunOS

    AC_MSG_RESULT(NULL)
    AC_DEFINE(CUPS_STRFTIME_FORMAT, NULL)
    @@ -160,9 +160,15 @@
    AC_CHECK_FUNCS(vsyslog)

dnl Checks for signal functions.
-if test "$uname" != "Linux"; then

  • AC_CHECK_FUNCS(sigset)
    -fi
    +case "$uname" in

  • Linux | GNU)

  •   # Do not use sigset on Linux or GNU HURD
    
  •   ;;
    
  • *)

  •   # Use sigset on other platforms, if available
    
  •   AC_CHECK_FUNCS(sigset)
    
  •   ;;
    

    +esac

    AC_CHECK_FUNCS(sigaction)

Index: cups-compiler.m4

RCS file: /development/cvs/cups/config-scripts/cups-compiler.m4,v
retrieving revision 1.27
diff -u -r1.27 cups-compiler.m4
--- cups-compiler.m4 29 Jun 2004 03:44:52 -0000 1.27
+++ cups-compiler.m4 11 Aug 2004 14:37:14 -0000
@@ -119,7 +119,7 @@
OPTIM="+z $OPTIM"
fi
;;

  •       IRIX*)
    
  •       IRIX)
        if test -z "$OPTIM"; then
            if test "x$with_optim" = x; then
                OPTIM="-O2"
    

    Index: cups-directories.m4

    RCS file: /development/cvs/cups/config-scripts/cups-directories.m4,v
    retrieving revision 1.12
    diff -u -r1.12 cups-directories.m4
    --- cups-directories.m4 29 Jun 2004 03:44:52 -0000 1.12
    +++ cups-directories.m4 11 Aug 2004 14:37:14 -0000
    @@ -115,8 +115,8 @@
    INITDDIR="/System/Library/StartupItems/PrintingServices"
    ;;

  •   Linux*)
    
  •       # Linux seems to choose an init.d directory at random...
    
  •   Linux | GNU)
    
  •       # Linux/HURD seems to choose an init.d directory at random...
        if test -d /sbin/init.d; then
            # SuSE
            INITDIR="/sbin/init.d"
    

    @@ -197,7 +197,7 @@

    dnl Set the CUPS_LOCALE directory...
    case "$uname" in

  • Linux* | BSD | Darwin*)

  • Linux | GNU | BSD | Darwin*)
    CUPS_LOCALEDIR="$datadir/locale"
    AC_DEFINE_UNQUOTED(CUPS_LOCALEDIR, "$datadir/locale")
    ;;
    Index: cups-manpages.m4
    ===================================================================
    RCS file: /development/cvs/cups/config-scripts/cups-manpages.m4,v
    retrieving revision 1.9
    diff -u -r1.9 cups-manpages.m4
    --- cups-manpages.m4 29 Jun 2004 03:44:52 -0000 1.9
    +++ cups-manpages.m4 11 Aug 2004 14:37:14 -0000
    @@ -25,13 +25,13 @@
    dnl Fix "mandir" variable...
    if test "$mandir" = "${prefix}/man" -a "$prefix" = "/"; then
    case "$uname" in

  •       Darwin\* | Linux\* | _BSD_ | AIX*)
    
  •           # Darwin, MacOS X, Linux, *BSD, and AIX
    
  •       Darwin\* | Linux | GNU | _BSD_ | AIX*)
    
  •           # Darwin, MacOS X, Linux, GNU HURD, *BSD, and AIX
            mandir="/usr/share/man"
            AMANDIR="/usr/share/man"
            PMANDIR="/usr/share/man"
            ;;
    
  •       IRIX*)
    
  •       IRIX)
            # SGI IRIX
            mandir="/usr/share/catman/u_man"
            AMANDIR="/usr/share/catman/a_man"
    

    Index: cups-opsys.m4

    RCS file: /development/cvs/cups/config-scripts/cups-opsys.m4,v
    retrieving revision 1.12
    diff -u -r1.12 cups-opsys.m4
    --- cups-opsys.m4 29 Jun 2004 03:44:52 -0000 1.12
    +++ cups-opsys.m4 11 Aug 2004 14:37:14 -0000
    @@ -25,9 +25,17 @@
    dnl Get the operating system and version number...
    uname=uname
    uversion=uname -r | sed -e '1,$s/[[^0-9]]//g'
    -if test x$uname = xIRIX64; then

  • uname="IRIX"
    -fi
    +case "$uname" in

  • GNU* | GNU/*)

  •   uname="GNU"
    
  •   ;;
    
  • IRIX*)

  •   uname="IRIX"
    
  •   ;;
    
  • Linux*)

  •   uname="Linux"
    
  •   ;;
    

    +esac

    dnl Determine the correct username and group for this OS...
    AC_ARG_WITH(cups-user, [ --with-cups-user set default user for CUPS],

    Index: cups-pam.m4

    RCS file: /development/cvs/cups/config-scripts/cups-pam.m4,v
    retrieving revision 1.10
    diff -u -r1.10 cups-pam.m4
    --- cups-pam.m4 29 Jun 2004 03:44:52 -0000 1.10
    +++ cups-pam.m4 11 Aug 2004 14:37:14 -0000
    @@ -65,7 +65,7 @@
    # Darwin, MacOS X
    PAMFILE="pam.darwin"
    ;;

  •   IRIX*)
    
  •   IRIX)
        # SGI IRIX
        PAMFILE="pam.irix"
        ;;
    

    Index: cups-sharedlibs.m4

    RCS file: /development/cvs/cups/config-scripts/cups-sharedlibs.m4,v
    retrieving revision 1.24
    diff -u -r1.24 cups-sharedlibs.m4
    --- cups-sharedlibs.m4 29 Jun 2004 03:44:52 -0000 1.24
    +++ cups-sharedlibs.m4 11 Aug 2004 14:37:14 -0000
    @@ -41,13 +41,13 @@
    DSO="ld"
    DSOFLAGS="$DSOFLAGS -b -z +h $@"
    ;;

  •   IRIX*)
    
  •   IRIX)
        LIBCUPS="libcups.so.2"
        LIBCUPSIMAGE="libcupsimage.so.2"
        DSO="\$(CC)"
        DSOFLAGS="$DSOFLAGS -Wl,-rpath,\$(libdir),-set_version,sgi2.5,-soname,\$@ -shared \$(OPTIM)"
        ;;
    
  •   OSF1\* | Linux\* | _BSD_)
    
  •   OSF1\* | Linux | GNU | _BSD_)
        LIBCUPS="libcups.so.2"
        LIBCUPSIMAGE="libcupsimage.so.2"
        DSO="\$(CC)"
    

    @@ -135,8 +135,8 @@
    LDFLAGS="$LDFLAGS -Wl,-R$libdir"
    EXPORT_LDFLAGS="-Wl,-R$libdir"
    ;;

  •            Linux*)
    
  •                    # Linux
    
  •            Linux | GNU)
    
  •                    # Linux and HURD
                DSOFLAGS="-Wl,-rpath,$libdir $DSOFLAGS"
                     LDFLAGS="$LDFLAGS -Wl,-rpath,$libdir"
                     EXPORT_LDFLAGS="-Wl,-rpath,$libdir"
    

@michaelrsweet michaelrsweet added the enhancement New feature or request label Mar 17, 2016
@michaelrsweet michaelrsweet added this to the Stable milestone Mar 17, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant