Garnome 2.10.0.1 on Solaris 8, part 2 (long)



Here is the second part of my report on what I needed to do to get Garnome
compiled on Solaris 8. Some of this may be specific to my setup, so your mileage
may vary.

I added -DUSE_SOLARIS to my CFLAGS/CXXFLAGS. There is another define within gcc
for Solaris (sun), but originally I was too lazy to look that up, and later I
decided to stick with my original define.
I found that some programs use 'sun' as a variable, and that results in weird
compilation errors, so I changed the variable whenever I encountered this.
I have also not verified that all programs work, I am happy to just have the
basic stuff running.

-Joe

[==========	Office		==========]
==> in office/glabels: wrong download URL

==> in office/libgda/work/main.d/libgda-1.2.1/providers/bdb
Apply patch:
<<<<<<<<<<<<<<<<<<<<<<<<<
--- gda-bdb-recordset.c.orig    Wed Dec 17 03:27:02 2003
+++ gda-bdb-recordset.c Wed Mar 23 23:29:40 2005
@@ -228,9 +228,7 @@
        /* get the number of records in the database */
        ret = dbp->stat (dbp,
                         &statp,
-#if BDB_VERSION < 40000
                         NULL,
-#endif
                         0);
        if (ret != 0) {
                gda_connection_add_error (cnc, gda_bdb_make_error (ret));
>>>>>>>>>>>>>>>>>>>>>>>>>

==> in office/abiword/work/main.d/abiword-2.2.5/abi/src/af/util/xp
Apply patch:
<<<<<<<<<<<<<<<<<<<<<<<<<
--- ut_iconv.cpp.orig   Thu Sep 16 20:02:57 2004
+++ ut_iconv.cpp        Fri Mar 25 10:23:10 2005
@@ -339,7 +339,7 @@
 #ifdef UT_ICONV_USING_GLIB
   return g_iconv((GIConv)cd, (char **)inbuf, inbytesleft, outbuf, outbytesleft);
 #else
-  return iconv( (iconv_t)cd, (ICONV_CONST char **)inbuf, inbytesleft, outbuf,
outbytesleft );
+  return iconv( (iconv_t)cd, inbuf, inbytesleft, outbuf, outbytesleft );
 #endif
 }

>>>>>>>>>>>>>>>>>>>>>>>>>

==> in office/abiword/work/main.d/abiword-2.2.5/abi/src/af/xap/unix
Apply patch:
<<<<<<<<<<<<<<<<<<<<<<<<<
--- xap_UnixEncodingManager.cpp.orig    Mon Feb 28 16:14:21 2005
+++ xap_UnixEncodingManager.cpp Fri Mar 25 10:50:59 2005
@@ -546,7 +546,7 @@
                                        MYLANG += LanguageISOName;
                                        MYLANG += "_";
                                        MYLANG += LanguageISOTerritory;
-                                       putenv(MYLANG.utf8_str());
+                                       putenv((char*)MYLANG.utf8_str());
 #else
                                        UT_UTF8String MYLANG (LanguageISOName);
                                        MYLANG += "_";
@@ -569,7 +569,7 @@
 #if defined(SETENV_MISSING)
                                        MYLANG = "LANG=";
                                        MYLANG += OLDLANG;
-                                       putenv(MYLANG.utf8_str());
+                                       putenv((char*)MYLANG.utf8_str());
 #else
                                        setenv("LANG", OLDLANG.utf8_str(), 1);
 #endif
>>>>>>>>>>>>>>>>>>>>>>>>>

[==========	Fifth-toe	==========]
==> in fifth-toe/bluefish/work/main.d/bluefish-1.0/src/document.c
Add #include <sys/time.h>

==> in fifth-toe/firestarter/work/main.d/firestarter-1.0.3/src
Apply patch:
<<<<<<<<<<<<<<<<<<<<<<<<<
--- util.c.orig Sat Jan 29 04:32:08 2005
+++ util.c      Thu Mar 24 07:40:41 2005
@@ -18,6 +18,9 @@
 #include <arpa/inet.h>
 #include <net/if.h>
 #include <sys/ioctl.h>
+#ifdef USE_SOLARIS
+#include <sys/sockio.h>
+#endif

 #include "globals.h"
--- statusview.c.orig   Sat Jan 29 04:32:08 2005
+++ statusview.c        Thu Mar 24 07:51:21 2005
@@ -217,8 +217,10 @@

        while (errno=0, direproc = readdir (dirproc)) {

+#ifndef USE_SOLARIS
                if (direproc->d_type!=DT_DIR)
                        continue;
+#endif

                for (cs = direproc->d_name; *cs; cs++)
                        if (!g_ascii_isdigit(*cs) || *cs)
@@ -236,9 +238,10 @@

                cmdlp = NULL;
                while ((direfd = readdir (dirfd))) {
+#ifndef USE_SOLARIS
                        if (direfd->d_type!=DT_LNK)
                                continue;
-
+#endif
                        if (procfdlen+1+strlen(direfd->d_name)+1>sizeof(line))
                                continue;
                        memcpy(line + procfdlen - 2, "fd/", 2+1);
>>>>>>>>>>>>>>>>>>>>>>>>>

==> in fifth-toe/gftp/work/main.d/gftp-2.0.18/lib/fsplib
Apply patch:
<<<<<<<<<<<<<<<<<<<<<<<<<
--- fsplib.c.orig       Tue Jan 18 18:03:45 2005
+++ fsplib.c    Thu Mar 24 11:28:59 2005
@@ -593,10 +593,12 @@

     /* convert FSP dirent to OS dirent */

+#ifndef USE_SOLARIS
     if (fentry.type == FSP_RDTYPE_DIR )
        entry->d_type=DT_DIR;
     else
        entry->d_type=DT_REG;
+#endif

     /* remove symlink destination */
     c=strchr(fentry.name,'\n');
@@ -608,7 +610,9 @@
        fentry.namlen-=rc;
     }

+#ifndef USE_SOLARIS
     entry->d_fileno = 10;
+#endif
     entry->d_reclen = fentry.reclen;
     strncpy(entry->d_name,fentry.name,MAXNAMLEN);

-- lock.c.orig Thu Mar 24 11:30:48 2005
+++ lock.c      Thu Mar 24 11:36:16 2005
@@ -2,6 +2,14 @@
 #include <stdio.h>
 #include "lock.h"

+#ifndef HAVE_UNION_SEMUN
+union semun {
+    int val;
+    struct semid_ds *buf;
+    unsigned short *array;
+};
+#endif
+
 /* ************ Locking functions ***************** */
 #ifndef FSP_NOLOCKING

@@ -91,7 +99,7 @@
   mode_t omask;
   key_t lock_key;
   int fd;
-  union semun sun;
+  union semun sun_union;
   struct sembuf sem;

   make_key_string(lock,server_addr,server_port);
@@ -123,8 +131,8 @@
          return -1;
       }
       /* we need to init this semaphore */
-      sun.val=1;
-      if(semctl(lock->lock_sem,0,SETVAL,sun) == -1)
+      sun_union.val=1;
+      if(semctl(lock->lock_sem,0,SETVAL,sun_union) == -1)
       {
          perror("semctl setval");
          return -1;
>>>>>>>>>>>>>>>>>>>>>>>>>

==> in
fifth-toe/seahorse/work/main.d/seahorse-0.7.6/libseahorse/seahorse-gpg-options.c
Needs to link with -lucb
Apply patch:
<<<<<<<<<<<<<<<<<<<<<<<<<
--- seahorse-gpg-options.c.orig Thu Feb  3 18:50:46 2005
+++ seahorse-gpg-options.c      Thu Mar 24 21:29:42 2005
@@ -21,7 +21,12 @@

 #include <sys/param.h>
 #include <sys/wait.h>
+#ifdef USE_SOLARIS
+#include <sys/fcntl.h>
+#include "/usr/ucbinclude/sys/file.h"
+#else
 #include <sys/file.h>
+#endif
 #include <gpgme.h>
 #include <string.h>
 #include <errno.h>
>>>>>>>>>>>>>>>>>>>>>>>>>

==> in fifth-toe/seahorse/work/main.d/seahorse-0.7.6/plugins/nautilus
Apply patch:
<<<<<<<<<<<<<<<<<<<<<<<<<
--- seahorse-pgp-preferences.c.orig     Sat Feb  5 18:18:41 2005
+++ seahorse-pgp-preferences.c  Thu Mar 24 23:04:26 2005
@@ -21,6 +21,9 @@

 #include <gnome.h>
 #include <config.h>
+#ifdef USE_SOLARIS
+#define _INTL_REDIRECT_MACROS
+#endif
 #include <locale.h>

 #include "seahorse-context.h"
@@ -38,7 +41,7 @@
        SeahorseWidget *swidget;
        SeahorseContext *sctx;

-#ifdef ENABLE_NLS
+#if defined(ENABLE_NLS) && !defined(USE_SOLARIS)
         bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR);
         bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8");
         textdomain (GETTEXT_PACKAGE);
>>>>>>>>>>>>>>>>>>>>>>>>>

==> in fifth-toe/seahorse/work/main.d/seahorse-0.7.6/agent
Apply patch:
<<<<<<<<<<<<<<<<<<<<<<<<<
--- seahorse-agent-io.c.orig    Mon Nov  1 14:57:24 2004
+++ seahorse-agent-io.c Thu Mar 24 23:17:25 2005
@@ -25,7 +25,9 @@
 #include <sys/stat.h>
 #include <sys/un.h>

+#ifndef USE_SOLARIS
 #include <paths.h>
+#endif
 #include <stddef.h>
 #include <stdlib.h>
 #include <stdio.h>
@@ -34,6 +36,10 @@
 #include <ctype.h>

 #include "seahorse-agent.h"
+
+#ifndef _PATH_TMP
+#define _PATH_TMP "/tmp/"
+#endif

 /*
  * Handles the server and open sockets. Parses received commands
>>>>>>>>>>>>>>>>>>>>>>>>>


[==========	Geektoys	==========]
==> geektoys/coaster doesn't compile

==> geektoys/gkrellm doesn't compile

==> geektoys/gksu doesn't compile

==> geektoys/gnome-cups-manager doesn't compile

==> geektoys/thoggen doesn't compile (needs Ogg)

==> geektoys/netapplet needs desktop/gnome-system-tools and therefore doesn't
compile

==> geektoys/revelation needs pycrypto, didn't install

==> geektoys/screem doesn't compile

==> in geektoys/figment/work/main.d/figment-0.3.5/src
Apply patch:
<<<<<<<<<<<<<<<<<<<<<<<<<
--- opml.c.orig Mon Dec 23 17:50:06 2002
+++ opml.c      Thu Mar 24 21:08:22 2005
@@ -125,7 +125,11 @@
          {
            int val;
            tmp_str = strdup(exp_str);
+#ifdef USE_SOLARIS
+           while( (token = strtok (&tmp_str, delim)) != NULL)
+#else
            while( (token = strsep (&tmp_str, delim)) != NULL)
+#endif
              {
                val = atoi(token);
                list = g_list_append(list, GINT_TO_POINTER(val));
>>>>>>>>>>>>>>>>>>>>>>>>>

==> in geektoys/gnome-gpg/work/main.d/gnome-gpg-0.3.0
Apply patch:
<<<<<<<<<<<<<<<<<<<<<<<<<
--- gnome-gpg.c.orig    Wed Apr 21 21:29:03 2004
+++ gnome-gpg.c Fri Mar 25 09:18:03 2005
@@ -29,6 +29,10 @@
 #include <sys/wait.h>
 #include <fcntl.h>

+#ifndef SIGTERM
+#define SIGTERM         15      /* Termination (ANSI).  */
+#endif
+
 /* Temporary */
 #define _(STR) (STR)

>>>>>>>>>>>>>>>>>>>>>>>>>

==> in geektoys/gnome-pkgview/Makefile
Modify FIXUP_SCRIPTS to read FIXUP_SCRIPTS = libtool $(WORKSRC)/intltool

==> in geektoys/monkey-bubble/work/main.d/monkey-bubble-0.3.2/src/ui
Apply patch:
<<<<<<<<<<<<<<<<<<<<<<<<<
--- eggcellrendererkeys.c.orig  Sat Mar 26 12:48:07 2005
+++ eggcellrendererkeys.c       Sat Mar 26 12:48:13 2005
@@ -588,7 +588,7 @@
 void
 egg_cell_renderer_keys_set_accelerator (EggCellRendererKeys *keys,
                                         guint                keyval,
-                                        GdkModifierType      mask)
+                                        EggVirtualModifierType   mask)
 {
   char *text;
   gboolean changed;
@@ -630,7 +631,7 @@
 void
 egg_cell_renderer_keys_get_accelerator (EggCellRendererKeys *keys,
                                         guint               *keyval,
-                                        GdkModifierType     *mask)
+                                        EggVirtualModifierType  *mask)
 {
   g_return_if_fail (EGG_IS_CELL_RENDERER_KEYS (keys));

>>>>>>>>>>>>>>>>>>>>>>>>>

==> in geektoys/netspeed_applet/work/main.d/netspeed_applet-0.11/src
Apply patch:
<<<<<<<<<<<<<<<<<<<<<<<<<
--- backend.c.orig      Wed Dec  1 06:58:56 2004
+++ backend.c   Sat Mar 26 13:25:50 2005
@@ -19,6 +19,10 @@

 #include "backend.h"

+#ifdef USE_SOLARIS
+#include <sys/sockio.h>
+#endif
+
 /* Check for all available devices. This really should be
  * portable for at least all plattforms using the gnu c lib
  */
@@ -157,6 +161,10 @@
                devinfo.ip = g_strdup_printf("%s", inet_ntoa(address->sin_addr));
        } else devinfo.ip = NULL;

+#ifdef USE_SOLARIS
+       devinfo.hwaddr = NULL;
+       devinfo.netmask = NULL;
+#else
        /* Get the hardware/physical adress/ MAC */
        if (ioctl(fd, SIOCGIFHWADDR, &request) == 0) {
                unsigned char hwaddr[6];
@@ -177,6 +185,7 @@
                struct sockaddr_in *address = (struct
sockaddr_in*)&request.ifr_netmask;
                devinfo.netmask = g_strdup_printf("%s",
inet_ntoa(address->sin_addr));
        } else devinfo.netmask = NULL;
+#endif

        /* Check if the device is a ptp and if this is the
         * case, get the ptp-ip */
>>>>>>>>>>>>>>>>>>>>>>>>>

==> in geektoys/monkey-bubble/work/main.d/monkey-bubble-0.3.2/src/net/Makefile
Remove -Werror

==> in geektoys/monkey-bubble/work/main.d/monkey-bubble-0.3.2/src/ui/Makefile
Remove -Werror


[==========	Hacker-tools	==========]
==> hacker-tools/alleyoop doesn't compile (needs valgrind)

==> hacker-tools/gst-editor doesn't compile

==> hacker-tools/memprof doesn't compile (is 386-specific)


[==========	Matchbox	==========]
==> matchbox/mb-applet-volume is Linux-centric and doesn't compile

==> matchbox/matchbox-desktop/work/main.d/matchbox-desktop-0.9/config.h
comment out DNOTIFY

==> in matchbox/matchbox-desktop/work/main.d/matchbox-desktop-0.9/modules
Needs LDFLAGS ="-lucb"
Apply patch:
<<<<<<<<<<<<<<<<<<<<<<<<<
--- dotdesktop.c.orig   Wed Dec  1 03:22:33 2004
+++ dotdesktop.c        Fri Mar 25 17:04:20 2005
@@ -9,6 +9,10 @@
 #include "config.h"
 #endif

+#ifdef USE_SOLARIS
+extern  int alphasort();
+#endif
+
 static void
 item_activate_cb(void *data1, void *data2);

--- simplefilebrowser.c.orig    Wed Dec  1 03:22:33 2004
+++ simplefilebrowser.c Fri Mar 25 17:06:46 2005
@@ -6,6 +6,10 @@

 #include <libmb/mb.h>

+#ifdef USE_SOLARIS
+extern  int alphasort();
+#endif
+
 typedef struct BrowserData {
   char* BrowserCurrentPath;
   char* BrowserPath;
>>>>>>>>>>>>>>>>>>>>>>>>>

==> matchbox/matchbox-panel/work/main.d/matchbox-panel-0.9/config.h
comment out DNOTIFY

==> in matchbox/matchbox-panel/work/main.d/matchbox-panel-0.9/src
Apply patch:
<<<<<<<<<<<<<<<<<<<<<<<<<
--- panel.c.orig        Mon Dec 20 07:15:22 2004
+++ panel.c     Sat Mar 26 09:55:00 2005
@@ -1568,6 +1568,10 @@
     {  NULL,   North }
   };

+#ifdef USE_SOLARIS
+  char putenv_buf[256];
+#endif
+
   XSetErrorHandler(util_handle_xerror);

   panel = NEW(MBPanel);
@@ -1600,7 +1604,12 @@
     if (!strcmp ("-display", argv[i]) || !strcmp ("-d", argv[i])) {
       if (++i>=argc) panel_usage (argv[0]);
       display_name = argv[i];
+#ifdef USE_SOLARIS
+      snprintf (putenv_buf, 256, "DISPLAY=%s", display_name);
+      putenv(putenv_buf);
+#else
       setenv("DISPLAY", display_name, 1);
+#endif
       continue;
     }
     if (!strcmp ("--no-session", argv[i]) || !strcmp ("-ns", argv[i])) {
@@ -1845,7 +1854,12 @@
     = XInternAtom(panel->dpy, tray_atom_spec, False);

   snprintf(tray_id_env_str, 16, "%i", panel->system_tray_id);
+#ifdef USE_SOLARIS
+      snprintf (putenv_buf, 256, "SYSTEM_TRAY_ID=%s", tray_id_env_str);
+      putenv(putenv_buf);
+#else
   setenv("SYSTEM_TRAY_ID", tray_id_env_str, 1);
+#endif

   snprintf(win_name, 64, "Panel %i", panel->system_tray_id);

>>>>>>>>>>>>>>>>>>>>>>>>>


[==========	Mono		==========]
While mono compiled, it segfaults.




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]