rpms/z88dk/F-11 z88dk-1.9-64bit.patch, NONE, 1.1 .cvsignore, 1.4, 1.5 sources, 1.4, 1.5 z88dk.spec, 1.18, 1.19 z88dk-1.7-64bit.patch, 1.1, NONE

Kevin Kofler kkofler at fedoraproject.org
Tue Jul 21 03:31:28 UTC 2009


Author: kkofler

Update of /cvs/pkgs/rpms/z88dk/F-11
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv12727/F-11

Modified Files:
	.cvsignore sources z88dk.spec 
Added Files:
	z88dk-1.9-64bit.patch 
Removed Files:
	z88dk-1.7-64bit.patch 
Log Message:
Sync from devel:

* Tue Jul 21 2009 Kevin Kofler <Kevin at tigcc.ticalc.org> - 1.9-1
- update to 1.9 (#512391)
- update 64bit patch (one issue fixed upstream, many left)

z88dk-1.9-64bit.patch:
 copt/copt.c      |    4 ++--
 sccz80/io.c      |    4 ++--
 sccz80/io.h      |    4 ++--
 sccz80/primary.c |    4 ++--
 z80asm/config.h  |    7 +++++++
 z80asm/modlink.c |   30 +++++++++++++++---------------
 z80asm/symbol.h  |    2 +-
 z80asm/z80asm.c  |    2 +-
 z80asm/z80pass.c |    4 ++--
 9 files changed, 34 insertions(+), 27 deletions(-)

--- NEW FILE z88dk-1.9-64bit.patch ---
diff -ur z88dk/src/copt/copt.c z88dk-64bit/src/copt/copt.c
--- z88dk/src/copt/copt.c	2002-09-15 19:10:07.000000000 +0200
+++ z88dk-64bit/src/copt/copt.c	2009-07-21 05:11:59.000000000 +0200
@@ -507,12 +507,12 @@
 		/* check for activation rules */
 		if (o->o_new && strcmp(o->o_new->l_text, "%activate\n") == 0) {
 			/* we have to prevent repeated activation of rules */
-			char signature[160];
+			char signature[240];
 			struct lnode *lnp;
 			struct onode *nn, *last;
 			int skip = 0;
 			/* since we 'install()' strings, we can compare pointers */
-			sprintf(signature, "%s%08x%08x%08x%08x%08x%08x%08x%08x%08x%08x\n",
+			sprintf(signature, (sizeof(char*)>4)?"%s%016lx%016lx%016lx%016lx%016lx%016lx%016lx%016lx%016lx%016lx\n":"%s%08lx%08lx%08lx%08lx%08lx%08lx%08lx%08lx%08lx%08lx\n",
 				activated,
 				vars[0], vars[1], vars[2], vars[3], vars[4],
 				vars[5], vars[6], vars[7], vars[8], vars[9]);
diff -ur z88dk/src/sccz80/io.c z88dk-64bit/src/sccz80/io.c
--- z88dk/src/sccz80/io.c	2009-06-21 23:16:52.000000000 +0200
+++ z88dk-64bit/src/sccz80/io.c	2009-07-21 05:11:59.000000000 +0200
@@ -334,7 +334,7 @@
 }
 
 
-void outdec(long number)
+void outdec(int number)
 {
         if ( number < 0 ) {
 		number=-number;
@@ -344,7 +344,7 @@
         outd2(number);
 }
 
-void outd2(long n)
+void outd2(int n)
 {
         if ( n > 9 ) {
                 outd2(n/10) ;
diff -ur z88dk/src/sccz80/io.h z88dk-64bit/src/sccz80/io.h
--- z88dk/src/sccz80/io.h	2009-06-21 23:16:52.000000000 +0200
+++ z88dk-64bit/src/sccz80/io.h	2009-07-21 05:11:59.000000000 +0200
@@ -26,8 +26,8 @@
 extern void ol(char *ptr);
 extern void ot(char *ptr);
 extern void blanks(void);
-extern void outdec(long number);
-extern void outd2(long n);
+extern void outdec(int number);
+extern void outd2(int n);
 extern void queuelabel(int);
 
 typedef struct {
diff -ur z88dk/src/sccz80/primary.c z88dk-64bit/src/sccz80/primary.c
--- z88dk/src/sccz80/primary.c	2007-07-05 20:39:00.000000000 +0200
+++ z88dk-64bit/src/sccz80/primary.c	2009-07-21 05:11:59.000000000 +0200
@@ -739,7 +739,7 @@
 	SYMBOL  *ptr;
     char    temp_type;
     int     itag;
-    char    nam[20];
+    char    nam[26];
 
 
 
@@ -794,7 +794,7 @@
  * returning pointers - to do this, we will define dummy symbols in
  * the local symbol table so that they do what we want them to do!
  */
-    sprintf(nam,"0dptr%d",(int)locptr);
+    sprintf(nam,"0dptr%lu",(unsigned long)locptr);
     temp_type = ( (lval->c_flags&FARPTR) ? CPTR : CINT );
     itag=0;
     if ( lval->c_tag) 
diff -ur z88dk/src/z80asm/config.h z88dk-64bit/src/z80asm/config.h
--- z88dk/src/z80asm/config.h	2007-06-24 18:41:41.000000000 +0200
+++ z88dk-64bit/src/z80asm/config.h	2009-07-21 05:11:59.000000000 +0200
@@ -64,6 +64,12 @@
 #define MAXCODESIZE 65536
 #endif
 
+#ifdef __linux__
+#include <endian.h>
+#if __BYTE_ORDER == __BIG_ENDIAN
+#define ENDIAN 1
+#endif
+#else
 /* Some clever config-ing if we're using GNUC */
 #ifdef __BIG_ENDIAN__
 /* Sadly the compiler on OS-X falls over with the #if below... */
@@ -75,3 +81,4 @@
 #endif
 #endif	/* __GNUC__ */
 #endif
+#endif
diff -ur z88dk/src/z80asm/modlink.c z88dk-64bit/src/z80asm/modlink.c
--- z88dk/src/z80asm/modlink.c	2002-11-05 12:45:56.000000000 +0100
+++ z88dk-64bit/src/z80asm/modlink.c	2009-07-21 05:11:59.000000000 +0200
@@ -106,11 +106,11 @@
 int LinkLibModule (struct libfile *library, long curmodule, char *modname);
 int SearchLibfile (struct libfile *curlib, char *modname);
 char *ReadName (void);
-long ReadLong (FILE * fileid);
+int ReadLong (FILE * fileid);
 void redefinedmsg (void);
 void CreateLib (void);
 void SearchLibraries (char *modname);
-void WriteLong (long fptr, FILE * fileid);
+void WriteLong (int fptr, FILE * fileid);
 void LinkModules (void);
 void ModuleExpr (void);
 void CreateBinFile (void);
@@ -160,7 +160,7 @@
 ReadNames (long nextname, long endnames)
 {
   char scope, symtype;
-  long value;
+  int value;
   symbol *foundsymbol;
 
   do
@@ -509,7 +509,7 @@
   while (CURRENTMODULE != lastobjmodule->nextmodule);	/* parse only object modules, not added library modules */
 
   if (verbose == ON)
-    printf ("Code size of linked modules is %d bytes\n", CODESIZE);
+    printf ("Code size of linked modules is %lu bytes\n", (unsigned long) CODESIZE);
 
   if (ASMERROR == OFF)
     ModuleExpr ();		/*  Evaluate expressions in  all modules */
@@ -531,7 +531,7 @@
 int 
 LinkModule (char *filename, long fptr_base)
 {
-  long fptr_namedecl, fptr_modname, fptr_modcode, fptr_libnmdecl;
+  int fptr_namedecl, fptr_modname, fptr_modcode, fptr_libnmdecl;
   size_t lowbyte, highbyte, size;
   int flag = 0;
 
@@ -661,7 +661,7 @@
 SearchLibfile (struct libfile *curlib, char *modname)
 {
 
-  long currentlibmodule, modulesize, fptr_mname;
+  int currentlibmodule, modulesize, fptr_mname;
   int flag;
   char *mname;
 
@@ -755,8 +755,8 @@
 void 
 ModuleExpr (void)
 {
-  long fptr_namedecl, fptr_modname, fptr_exprdecl, fptr_libnmdecl;
-  long fptr_base;
+  int fptr_namedecl, fptr_modname, fptr_exprdecl, fptr_libnmdecl;
+  int fptr_base;
   struct linkedmod *curlink;
 
   if (verbose)
@@ -837,7 +837,7 @@
 	  *(reloctable + 3) = (unsigned short) sizeof_reloctable / 256U;/* total size of relocation table elements */
 
 	  fwrite (reloctable, 1U, sizeof_reloctable + 4, binaryfile);	/* write relocation table, inclusive 4 byte header */
-	  printf ("Relocation header is %d bytes.\n", sizeof_relocroutine + sizeof_reloctable + 4);
+	  printf ("Relocation header is %lu bytes.\n", (unsigned long) (sizeof_relocroutine + sizeof_reloctable + 4));
 	  fwrite (codearea, sizeof (char), CODESIZE, binaryfile);	/* write code as one big chunk */
 	  fclose (binaryfile);
 	}
@@ -880,9 +880,9 @@
 void 
 CreateLib (void)
 {
-  long Codesize;
+  int Codesize;
   FILE *objectfile = NULL;
-  long fptr;
+  int fptr;
   char *filebuffer, *fname;
 
   if (verbose)
@@ -1035,13 +1035,13 @@
 
 
 
-long 
+int 
 ReadLong (FILE * fileid)
 {
 
 #ifdef ENDIAN			/* high byte, low byte order... */
   int i;
-  unsigned long c, fptr = 0;
+  unsigned int c, fptr = 0;
 
   for (i = 1; i <= 3; i++)
     {
@@ -1052,7 +1052,7 @@
 
   return fptr;
 #else /* low byte, high byte order...    */
-  long fptr = 0;
+  int fptr = 0;
 
   /* long is *at least* 4 bytes long, and we have to write exactly 4 bytes */
   fread (&fptr, 4, 1, fileid);
@@ -1063,7 +1063,7 @@
 
 
 void 
-WriteLong (long fptr, FILE * fileid)
+WriteLong (int fptr, FILE * fileid)
 {
 #ifdef ENDIAN			/* high byte, low byte order... */
   int i;
diff -ur z88dk/src/z80asm/symbol.h z88dk-64bit/src/z80asm/symbol.h
--- z88dk/src/z80asm/symbol.h	2003-10-11 17:41:04.000000000 +0200
+++ z88dk-64bit/src/z80asm/symbol.h	2009-07-21 05:11:59.000000000 +0200
@@ -113,7 +113,7 @@
 
 struct libfile      { struct libfile    *nextlib;           /* pointer to next library file in list */
                       char              *libfilename;       /* filename of library (incl. extension) */
-                      long              nextobjfile;        /* file pointer to next object file in library */
+                      int               nextobjfile;        /* file pointer to next object file in library */
                     };
 
 struct linklist     { struct linkedmod  *firstlink;         /* pointer to first linked object module */
diff -ur z88dk/src/z80asm/z80asm.c z88dk-64bit/src/z80asm/z80asm.c
--- z88dk/src/z80asm/z80asm.c	2009-06-23 00:12:53.000000000 +0200
+++ z88dk-64bit/src/z80asm/z80asm.c	2009-07-21 05:11:59.000000000 +0200
@@ -834,7 +834,7 @@
     }
   if (*flagid == 'r')
     {
-      sscanf (flagid + 1, "%x", &EXPLICIT_ORIGIN);
+      sscanf (flagid + 1, "%lx", &EXPLICIT_ORIGIN);
       deforigin = ON;		/* explicit origin has been defined */
       return;
     }
diff -ur z88dk/src/z80asm/z80pass.c z88dk-64bit/src/z80asm/z80pass.c
--- z88dk/src/z80asm/z80pass.c	2002-05-11 22:09:38.000000000 +0200
+++ z88dk-64bit/src/z80asm/z80pass.c	2009-07-21 05:11:59.000000000 +0200
@@ -853,9 +853,9 @@
   fprintf (listfile, "%*.*s", 122 - strlen (_prog_name) - strlen (_version) - strlen (_copyright) - 3, strlen (date), date);
 #else
   fprintf (listfile, "%s", copyrightmsg);
-  fprintf (listfile, "%*.*s", (int) 122 - strlen (copyrightmsg), (int) strlen (date), date);
+  fprintf (listfile, "%*.*s", (int) (122 - strlen (copyrightmsg)), (int) strlen (date), date);
 #endif
-  fprintf (listfile, "Page %03d%*s'%s'\n\n\n", ++PAGENR, (int) 122 - 9 - 2 - strlen (lstfilename), "", lstfilename);
+  fprintf (listfile, "Page %03d%*s'%s'\n\n\n", ++PAGENR, (int) (122 - 9 - 2 - strlen (lstfilename)), "", lstfilename);
 }
 
 


Index: .cvsignore
===================================================================
RCS file: /cvs/pkgs/rpms/z88dk/F-11/.cvsignore,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -p -r1.4 -r1.5
--- .cvsignore	10 Mar 2008 23:13:46 -0000	1.4
+++ .cvsignore	21 Jul 2009 03:31:27 -0000	1.5
@@ -1 +1 @@
-z88dk-src-1.8.tgz
+z88dk-src-1.9.tgz


Index: sources
===================================================================
RCS file: /cvs/pkgs/rpms/z88dk/F-11/sources,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -p -r1.4 -r1.5
--- sources	10 Mar 2008 23:13:46 -0000	1.4
+++ sources	21 Jul 2009 03:31:28 -0000	1.5
@@ -1 +1 @@
-f3a762cb6263430f76163e3e85fa1102  z88dk-src-1.8.tgz
+405de32baa962e30b8951270f5a4799d  z88dk-src-1.9.tgz


Index: z88dk.spec
===================================================================
RCS file: /cvs/pkgs/rpms/z88dk/F-11/z88dk.spec,v
retrieving revision 1.18
retrieving revision 1.19
diff -u -p -r1.18 -r1.19
--- z88dk.spec	10 Apr 2009 00:04:22 -0000	1.18
+++ z88dk.spec	21 Jul 2009 03:31:28 -0000	1.19
@@ -1,13 +1,13 @@
 Summary: A Z80 cross compiler
 Name: z88dk
-Version: 1.8
-Release: 3%{?dist}
+Version: 1.9
+Release: 1%{?dist}
 License: Artistic clarified
 Group: Development/Tools
 Source: http://downloads.sourceforge.net/z88dk/z88dk-src-%{version}.tgz
 Patch0: z88dk-1.8-makefile-usr-share.patch
 Patch1: z88dk-1.8-makefile-fixes.patch
-Patch2: z88dk-1.7-64bit.patch
+Patch2: z88dk-1.9-64bit.patch
 Patch3: z88dk-1.8-getline-name-conflict.patch
 URL: http://z88dk.sourceforge.net/
 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
@@ -80,6 +80,10 @@ export ZCCCFG=%{_datadir}/z88dk-%{versio
 %{_mandir}/man3z/
 
 %changelog
+* Tue Jul 21 2009 Kevin Kofler <Kevin at tigcc.ticalc.org> - 1.9-1
+- update to 1.9 (#512391)
+- update 64bit patch (one issue fixed upstream, many left)
+
 * Fri Apr 10 2009 Kevin Kofler <Kevin at tigcc.ticalc.org> - 1.8-3
 - fix name conflict with the getline function in POSIX 2008
 


--- z88dk-1.7-64bit.patch DELETED ---




More information about the fedora-extras-commits mailing list