the Fink project is an effort to port
popular Unix programs to Mac OS X
Package: nedit
Version: 5.6cvs20081118
Revision: 2
#Source: http://www.nedit.org/ftp/v5_5/nedit-%v.tar.gz
Source: mirror:debian:pool/main/n/nedit/nedit_5.6~cvs20081118.orig.tar.gz
Source-MD5: 4d0ba8f4142d3f35ffec874470cf26dd
SourceDirectory: nedit-5.6.orig
Depends: openmotif4-shlibs, x11
BuildDepends: x11-dev, openmotif4, fink (>= 0.24.12-01)
PatchFile: %n.patch
PatchFile-MD5: 042cde5e55d4925d016eb330e9a4c9f4
PatchScript: <<
sed 's|@PREFIX@|%p|g' < %{PatchFile} | patch -p1
<<
CompileScript: <<
#!/bin/sh -ev
make macosx PREFIX=%p
cd doc
make man
make doc
<<
InstallScript: <<
mkdir %i/bin
cp source/nedit %i/bin
cp source/nc %i/bin/nedit-nc
mkdir -p %i/share/man/man1
cp doc/nedit.man %i/share/man/man1/nedit.1
cp doc/nc.man %i/share/man/man1/nedit-nc.1
<<
DocFiles: doc/nedit.doc doc/nedit.html doc/faq.txt README COPYRIGHT ReleaseNotes ChangeLog
Description: Multi-purpose text editor X Windows
DescDetail: <<
The nc command is installed as nedit-nc to
avoid a conflict with the netcat package.
<<
DescPackaging: <<
The nc command is installed as nedit-nc to avoid a conflict with
netcat a.k.a. nc.
Disable motif version-check because it is overly strict ("approved
versions" list, long-unupdated).
<<
License: GPL
Maintainer: None
Homepage: http://nedit.org/
diff -Nurd -x'*~' nedit-5.5.orig/makefiles/Makefile.macosx nedit-5.5/makefiles/Makefile.macosx
--- nedit-5.5.orig/makefiles/Makefile.macosx 2004-07-14 15:48:21.000000000 -0400
+++ nedit-5.5/makefiles/Makefile.macosx 2008-06-19 18:42:48.000000000 -0400
@@ -9,7 +9,7 @@
# Change this line to point at the location your Motif libraries/headers are
# installed. (e.g. /usr/local or /sw) Use "locate libXm." to find the
# libraries, then remove the /lib suffix.
-MOTIFDIR=/usr/local
+MOTIFDIR=@PREFIX@
# Use the first line if you're using OpenMotif, use the second if you're using
# LessTif from Fink.
@@ -19,8 +19,8 @@
# Use the first line to link to Motif statically (highly recommended) or the
# second line to link dynamically. With Fink you'll probably have to use
# dynamic linking, since they don't normally distribute the static libraries.
-MOTIFLINK=${MOTIFDIR}/lib/libXm.a
-#MOTIFLINK=-L${MOTIFDIR}/lib -lXm.2
+#MOTIFLINK=${MOTIFDIR}/lib/libXm.a
+MOTIFLINK=-L${MOTIFDIR}/lib -lXm
############### You shouldn't need to edit anything below here ##############
@@ -46,4 +46,4 @@
#
include Makefile.common
-verify_config: check_tif_rule
+verify_config:
--- nedit-5.6.orig/source/preferences.c.org 2009-08-28 23:30:51.000000000 -0400
+++ nedit-5.6.orig/source/preferences.c 2009-08-28 23:35:08.000000000 -0400
@@ -2296,7 +2296,7 @@
XtVaGetValues(menu, XmNchildren, &items, XmNnumChildren, &nItems, NULL);
for (n=0; n<(int)nItems; n++) {
XtVaGetValues(items[n], XmNuserData, &userData, NULL);
- XmToggleButtonSetState(items[n], (int)userData == mode, False);
+ XmToggleButtonSetState(items[n], (int)(uintptr_t)userData == mode, False);
}
}
}
@@ -5148,7 +5148,7 @@
xmToggleButtonGadgetClass, menu,
XmNlabelString, s1=XmStringCreateSimple(LanguageModes[i]->name),
XmNmarginHeight, 0,
- XmNuserData, (void *)i,
+ XmNuserData, (void *)(uintptr_t)i,
XmNset, window->languageMode==i, NULL);
XmStringFree(s1);
XtAddCallback(btn, XmNvalueChangedCallback, setLangModeCB, window);
@@ -5169,14 +5169,14 @@
XtVaGetValues(w, XmNuserData, &mode, NULL);
/* If the mode didn't change, do nothing */
- if (window->languageMode == (int)mode)
+ if (window->languageMode == (int)(uintptr_t)mode)
return;
/* redo syntax highlighting word delimiters, etc. */
/*
reapplyLanguageMode(window, (int)mode, False);
*/
- params[0] = (((int)mode) == PLAIN_LANGUAGE_MODE) ? "" : LanguageModes[(int)mode]->name;
+ params[0] = (((int)(uintptr_t)mode) == PLAIN_LANGUAGE_MODE) ? "" : LanguageModes[(int)(uintptr_t)mode]->name;
XtCallActionProc(window->textArea, "set_language_mode", NULL, params, 1);
}
--- nedit-5.6.orig/util/prefFile.c.org 2009-08-28 23:37:01.000000000 -0400
+++ nedit-5.6.orig/util/prefFile.c 2009-08-28 23:39:03.000000000 -0400
@@ -353,9 +353,9 @@
*(int *)rsrcDescrip->valueAddr = 0;
return False;
case PREF_STRING:
- if ((int)strlen(string) >= (int)rsrcDescrip->arg)
+ if ((int)strlen(string) >= (int)(uintptr_t)rsrcDescrip->arg)
return False;
- strncpy(rsrcDescrip->valueAddr, string, (int)rsrcDescrip->arg);
+ strncpy(rsrcDescrip->valueAddr, string, (int)(uintptr_t)rsrcDescrip->arg);
return True;
case PREF_ALLOC_STRING:
*(char **)rsrcDescrip->valueAddr = XtMalloc(strlen(string) + 1);
--- nedit-5.6.orig/Xlt/SlideC.c.org 2009-08-28 23:41:08.000000000 -0400
+++ nedit-5.6.orig/Xlt/SlideC.c 2009-08-28 23:46:04.000000000 -0400
@@ -116,14 +116,14 @@
/* notify that initialize called XtArgsProc */ NULL,
/* NULL XtProc */ NULL,
/* NULL XtPointer */ NULL,
-/* NULL Cardinal */ (Cardinal)NULL,
+/* NULL Cardinal */ (Cardinal)(uintptr_t)NULL,
/* resources for subclass fields XtResourceList */ resources,
/* number of entries in resources Cardinal */ XtNumber(resources),
/* resource class quarkified XrmClass */ NULLQUARK,
-/* NULL Boolean */ (Boolean)NULL,
-/* NULL XtEnum */ (XtEnum)NULL,
-/* NULL Boolean */ (Boolean)NULL,
-/* NULL Boolean */ (Boolean)NULL,
+/* NULL Boolean */ (Boolean)(uintptr_t)NULL,
+/* NULL XtEnum */ (XtEnum)(uintptr_t)NULL,
+/* NULL Boolean */ (Boolean)(uintptr_t)NULL,
+/* NULL Boolean */ (Boolean)(uintptr_t)NULL,
/* free data for subclass pointers XtWidgetProc */ destroy,
/* NULL XtProc */ NULL,
/* NULL XtProc */ NULL,
--- nedit-5.6.orig/source/file.c.org 2009-08-28 23:47:38.000000000 -0400
+++ nedit-5.6.orig/source/file.c 2009-08-28 23:48:50.000000000 -0400
@@ -1914,7 +1914,7 @@
if (XmToggleButtonGetState(w)) {
XtPointer userData;
XtVaGetValues(w, XmNuserData, &userData, NULL);
- *(int*) clientData = (int) userData;
+ *(int*) clientData = (int) (uintptr_t) userData;
}
}
--- nedit-5.6.orig/source/macro.c.org 2009-08-28 23:50:22.000000000 -0400
+++ nedit-5.6.orig/source/macro.c 2009-08-28 23:53:59.000000000 -0400
@@ -2924,7 +2924,7 @@
readStringArg(argList[i], &btnLabel, btnStorage, errMsg);
btn = XtVaCreateManagedWidget("mdBtn", xmPushButtonWidgetClass, dialog,
XmNlabelString, s1=XmStringCreateSimple(btnLabel),
- XmNuserData, (XtPointer)(i+1), NULL);
+ XmNuserData, (XtPointer)(uintptr_t)(i+1), NULL);
XtAddCallback(btn, XmNactivateCallback, dialogBtnCB, window);
XmStringFree(s1);
}
@@ -2965,7 +2965,7 @@
return; /* shouldn't happen */
if (XtClass(w) == xmPushButtonWidgetClass) {
XtVaGetValues(w, XmNuserData, &userData, NULL);
- retVal.val.n = (int)userData;
+ retVal.val.n = (int)(uintptr_t)userData;
} else
retVal.val.n = 1;
retVal.tag = INT_TAG;
@@ -3101,7 +3101,7 @@
readStringArg(argList[i], &btnLabel, btnStorage, errMsg);
btn = XtVaCreateManagedWidget("mdBtn", xmPushButtonWidgetClass, dialog,
XmNlabelString, s1=XmStringCreateSimple(btnLabel),
- XmNuserData, (XtPointer)(i+1), NULL);
+ XmNuserData, (XtPointer)(uintptr_t)(i+1), NULL);
XtAddCallback(btn, XmNactivateCallback, stringDialogBtnCB, window);
XmStringFree(s1);
}
@@ -3155,7 +3155,7 @@
returned in w. */
if (XtClass(w) == xmPushButtonWidgetClass) {
XtVaGetValues(w, XmNuserData, &userData, NULL);
- btnNum = (int)userData;
+ btnNum = (int)(uintptr_t)userData;
} else
btnNum = 1;
@@ -3680,7 +3680,7 @@
readStringArg(argList[i], &btnLabel, btnStorage, errMsg);
btn = XtVaCreateManagedWidget("mdBtn", xmPushButtonWidgetClass, dialog,
XmNlabelString, s1=XmStringCreateSimple(btnLabel),
- XmNuserData, (XtPointer)(i+1), NULL);
+ XmNuserData, (XtPointer)(uintptr_t)(i+1), NULL);
XtAddCallback(btn, XmNactivateCallback, listDialogBtnCB, window);
XmStringFree(s1);
}
@@ -3760,7 +3760,7 @@
returned in w. */
if (XtClass(w) == xmPushButtonWidgetClass) {
XtVaGetValues(w, XmNuserData, &userData, NULL);
- btnNum = (int)userData;
+ btnNum = (int)(uintptr_t)userData;
} else
btnNum = 1;
--- nedit-5.6.orig/source/userCmds.c.org 2009-08-28 23:55:49.000000000 -0400
+++ nedit-5.6.orig/source/userCmds.c 2009-08-28 23:57:11.000000000 -0400
@@ -1116,7 +1116,7 @@
XtVaGetValues(items[n], XmNsubMenuId, &subMenu, NULL);
dimSelDepItemsInMenu(subMenu, menuList, nMenuItems, sensitive);
} else {
- index = (int)userData - 10;
+ index = (int)(uintptr_t)userData - 10;
if (index <0 || index >= nMenuItems)
return;
if (menuList[index]->input == FROM_SELECTION)
@@ -1928,7 +1928,7 @@
XmNlabelString, st1,
XmNacceleratorText, st2,
XmNmnemonic, f->mnemonic,
- XmNuserData, (XtPointer)(index+10), NULL);
+ XmNuserData, (XtPointer)(uintptr_t)(index+10), NULL);
XtAddCallback(btn, XmNactivateCallback, cbRtn, cbArg);
XmStringFree(st1);
XmStringFree(st2);
--- nedit-5.6.orig/source/regularExp.c.org 2009-08-28 23:58:30.000000000 -0400
+++ nedit-5.6.orig/source/regularExp.c 2009-08-28 23:59:02.000000000 -0400
@@ -4157,7 +4157,7 @@
table [*c] = 1;
}
- table [(int) NULL] = 1; /* These */
+ table [(int)(uintptr_t) NULL] = 1; /* These */
table [(int) '\t'] = 1; /* characters */
table [(int) '\n'] = 1; /* are always */
table [(int) ' ' ] = 1; /* delimiters. */
--- nedit-5.6.orig/source/highlight.c.org 2009-08-29 00:01:28.000000000 -0400
+++ nedit-5.6.orig/source/highlight.c 2009-08-29 00:02:16.000000000 -0400
@@ -512,7 +512,7 @@
if (!pattern) {
return NULL;
}
- return (void*)pattern->userStyleIndex;
+ return (void*)(uintptr_t)pattern->userStyleIndex;
}
/*
--- nedit-5.6.orig/source/preferences.c.org 2009-08-29 00:51:27.000000000 -0400
+++ nedit-5.6.orig/source/preferences.c 2009-08-29 00:52:13.000000000 -0400
@@ -1520,7 +1520,7 @@
} else
{
fprintf(stderr, "Could not read additional preferences file: ");
- fprintf(stderr, filename);
+ fprintf(stderr, "%s", filename);
fprintf(stderr, "\n");
}
}
--- nedit-5.6.orig/source/nc.c.org 2009-08-29 00:57:20.000000000 -0400
+++ nedit-5.6.orig/source/nc.c 2009-08-29 00:58:04.000000000 -0400
@@ -503,7 +503,7 @@
/* prompt user whether to start server */
if (!Preferences.autoStart) {
- printf(message);
+ printf("%s", message);
do {
c = getc(stdin);
} while (c == ' ' || c == '\t');