diff --git a/README.md b/README.md index 15d8530..a966c73 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,4 @@ # xfractint +Fractint is a freeware fractal generator created for IBMPC's and compatible computers. It is the most versatile and extensive fractal program available for any price. The authors (of which I am not one), work very hard to keep it that way. It has many great features and it is constantly being upgraded and improved by the Stone Soup team. Keep this link as a reference to stay up-to-date with the latest developments. + diff --git a/xfractint-20.2.04-gcc4.patch b/xfractint-20.2.04-gcc4.patch new file mode 100644 index 0000000..778d145 --- /dev/null +++ b/xfractint-20.2.04-gcc4.patch @@ -0,0 +1,590 @@ +diff -u xfractint-20.2.04.orig/editpal.c xfractint-20.2.04/editpal.c +--- xfractint-20.2.04.orig/editpal.c 2005-09-21 23:02:30.000000000 +0200 ++++ xfractint-20.2.04/editpal.c 2005-09-21 23:38:25.000000000 +0200 +@@ -114,11 +114,7 @@ + #endif + + #include +-#ifndef XFRACT + #include +-#else +-#include +-#endif + + #ifdef __TURBOC__ + # include /* to get mem...() declarations */ +@@ -410,31 +406,14 @@ + } + + +-#ifndef XFRACT + static void displayf(int x, int y, int fg, int bg, char *format, ...) +-#else +-static void displayf(va_alist) +-va_dcl +-#endif + { + char buff[81]; + int ctr; + + va_list arg_list; + +-#ifndef XFRACT + va_start(arg_list, format); +-#else +- int x,y,fg,bg; +- char *format; +- +- va_start(arg_list); +- x = va_arg(arg_list,int); +- y = va_arg(arg_list,int); +- fg = va_arg(arg_list,int); +- bg = va_arg(arg_list,int); +- format = va_arg(arg_list,char *); +-#endif + vsprintf(buff, format, arg_list); + va_end(arg_list); + +diff -u xfractint-20.2.04.orig/fracsubr.c xfractint-20.2.04/fracsubr.c +--- xfractint-20.2.04.orig/fracsubr.c 2005-09-21 23:02:30.000000000 +0200 ++++ xfractint-20.2.04/fracsubr.c 2005-09-21 23:38:25.000000000 +0200 +@@ -3,12 +3,8 @@ + FRACTALS.C, i.e. which are non-fractal-specific fractal engine subroutines. + */ + +-#ifndef XFRACT + #include + #include +-#else +-#include +-#endif + #include + #include + /* see Fractint.c for a description of the "include" hierarchy */ +@@ -1058,27 +1054,14 @@ + + */ + +-#ifndef XFRACT + int put_resume(int len, ...) +-#else +-int put_resume(va_alist) +-va_dcl +-#endif + { + va_list arg_marker; /* variable arg list */ + BYTE *source_ptr; +-#ifdef XFRACT +- int len; +-#endif + + if (resume_info == 0) + return(-1); +-#ifndef XFRACT + va_start(arg_marker,len); +-#else +- va_start(arg_marker); +- len = va_arg(arg_marker,int); +-#endif + while (len) + { + source_ptr = (BYTE *)va_arg(arg_marker,char *); +@@ -1109,27 +1092,14 @@ + return(0); + } + +-#ifndef XFRACT + int get_resume(int len, ...) +-#else +-int get_resume(va_alist) +-va_dcl +-#endif + { + va_list arg_marker; /* variable arg list */ + BYTE *dest_ptr; +-#ifdef XFRACT +- int len; +-#endif + + if (resume_info == 0) + return(-1); +-#ifndef XFRACT + va_start(arg_marker,len); +-#else +- va_start(arg_marker); +- len = va_arg(arg_marker,int); +-#endif + while (len) + { + dest_ptr = (BYTE *)va_arg(arg_marker,char *); +diff -u xfractint-20.2.04.orig/fractint.c xfractint-20.2.04/fractint.c +--- xfractint-20.2.04.orig/fractint.c 2005-09-21 23:02:30.000000000 +0200 ++++ xfractint-20.2.04/fractint.c 2005-09-21 23:39:13.000000000 +0200 +@@ -6,14 +6,12 @@ + #include + #include + #include +-#ifndef XFRACT +-#include ++#include + #include +-#else +-#include +-#endif + #include + ++#define SRCDIR /usr/share/xfractint/ ++ + /* #include hierarchy for fractint is a follows: + Each module should include port.h as the first fractint specific + include. port.h includes , , , +@@ -554,12 +552,7 @@ + timer(1,NULL,int width) decoder + timer(2) encoder + */ +-#ifndef XFRACT + int timer(int timertype,int(*subrtn)(),...) +-#else +-int timer(va_alist) +-va_dcl +-#endif + { + va_list arg_marker; /* variable arg list */ + char *timestring; +@@ -569,15 +562,7 @@ + int i; + int do_bench; + +-#ifndef XFRACT + va_start(arg_marker,subrtn); +-#else +- int timertype; +- int (*subrtn)(); +- va_start(arg_marker); +- timertype = va_arg(arg_marker, int); +- subrtn = (int (*)())va_arg(arg_marker, int *); +-#endif + + do_bench = timerflag; /* record time? */ + if (timertype == 2) /* encoder, record time only if debug=200 */ +diff -u xfractint-20.2.04.orig/framain2.c xfractint-20.2.04/framain2.c +--- xfractint-20.2.04.orig/framain2.c 2005-09-21 23:02:30.000000000 +0200 ++++ xfractint-20.2.04/framain2.c 2005-09-21 23:38:25.000000000 +0200 +@@ -1,11 +1,7 @@ + #include + #include +-#ifndef XFRACT +-#include ++#include + #include +-#else +-#include +-#endif + #include + /* see Fractint.c for a description of the "include" hierarchy */ + #include "port.h" +diff -u xfractint-20.2.04.orig/hc.c xfractint-20.2.04/hc.c +--- xfractint-20.2.04.orig/hc.c 2005-09-21 23:02:30.000000000 +0200 ++++ xfractint-20.2.04/hc.c 2005-09-21 23:38:25.000000000 +0200 +@@ -52,13 +52,9 @@ + #define INCLUDE_COMMON /* tell helpcom.h to include common code */ + + +-#ifndef XFRACT +-#include ++#include + #include +-#else +-#include + #define strupr strlwr +-#endif + #include + #include + #include +@@ -104,8 +100,8 @@ + #define DEFAULT_EXE_FNAME "fractint.exe" + #define DEFAULT_DOC_FNAME "fractint.doc" + +-#define TEMP_FNAME "HC.$$$" +-#define SWAP_FNAME "HCSWAP.$$$" ++#define TEMP_FNAME "HC.tmp" ++#define SWAP_FNAME "HCSWAP.tmp" + + #define MAX_ERRORS (25) /* stop after this many errors */ + #define MAX_WARNINGS (25) /* stop after this many warnings */ +@@ -301,24 +297,11 @@ + } + + +-#ifndef XFRACT + void fatal(int diff, char *format, ...) +-#else +-void fatal(va_alist) +- va_dcl +-#endif + { + va_list arg; + +-#ifndef XFRACT +- va_start(arg, format); +-#else +- int diff; +- char *format; +- va_start(arg); +- diff = va_arg(arg,int); +- format = va_arg(arg,char *); +-#endif ++ va_start(arg,format); + + print_msg("Fatal", srcline-diff, format, arg); + va_end(arg); +@@ -330,24 +313,11 @@ + } + + +-#ifndef XFRACT + void error(int diff, char *format, ...) +-#else +-void error(va_alist) +- va_dcl +-#endif + { + va_list arg; + +-#ifndef XFRACT + va_start(arg, format); +-#else +- int diff; +- char *format; +- va_start(arg); +- diff = va_arg(arg,int); +- format = va_arg(arg,char *); +-#endif + print_msg("Error", srcline-diff, format, arg); + va_end(arg); + +@@ -356,23 +326,10 @@ + } + + +-#ifndef XFRACT + void warn(int diff, char *format, ...) +-#else +-void warn(va_alist) +- va_dcl +-#endif + { + va_list arg; +-#ifndef XFRACT + va_start(arg, format); +-#else +- int diff; +- char *format; +- va_start(arg); +- diff = va_arg(arg, int); +- format = va_arg(arg, char *); +-#endif + print_msg("Warning", srcline-diff, format, arg); + va_end(arg); + +@@ -381,47 +338,22 @@ + } + + +-#ifndef XFRACT + void notice(char *format, ...) +-#else +-void notice(va_alist) +- va_dcl +-#endif + { + va_list arg; +-#ifndef XFRACT + va_start(arg, format); +-#else +- char *format; +- +- va_start(arg); +- format = va_arg(arg,char *); +-#endif + print_msg("Note", srcline, format, arg); + va_end(arg); + } + + +-#ifndef XFRACT + void msg(char *format, ...) +-#else +-void msg(va_alist) +-va_dcl +-#endif + { + va_list arg; +-#ifdef XFRACT +- char *format; +-#endif + + if (quiet_mode) + return; +-#ifndef XFRACT + va_start(arg, format); +-#else +- va_start(arg); +- format = va_arg(arg,char *); +-#endif + print_msg(NULL, 0, format, arg); + va_end(arg); + } +@@ -3103,8 +3035,9 @@ + } + + fprintf(file, "\n\n"); +- } + ++ } ++ + + void write_hdr(char *fname) + { +@@ -3134,7 +3067,8 @@ + + _write_hdr(fname, temp); + +- fclose(temp); ++// fclose(temp); ++ + temp = fopen(TEMP_FNAME, "rt"); + + if (temp == NULL) +diff -u xfractint-20.2.04.orig/helpdefs.h xfractint-20.2.04/helpdefs.h +--- xfractint-20.2.04.orig/helpdefs.h 2005-09-21 23:02:30.000000000 +0200 ++++ xfractint-20.2.04/helpdefs.h 2005-09-21 23:38:25.000000000 +0200 +@@ -1,10 +1,10 @@ + + /* +- * .h ++ * helpdefs.h + * + * Contains #defines for help. + * +- * Generated by HC from: .src ++ * Generated by HC from: help.src + * + */ + +diff -u xfractint-20.2.04.orig/jiim.c xfractint-20.2.04/jiim.c +--- xfractint-20.2.04.orig/jiim.c 2005-09-21 23:02:30.000000000 +0200 ++++ xfractint-20.2.04/jiim.c 2005-09-21 23:38:25.000000000 +0200 +@@ -40,11 +40,7 @@ + + #include + +-#ifndef XFRACT + #include +-#else +-#include +-#endif + + #ifdef __TURBOC__ + # include /* to get mem...() declarations */ +diff -u xfractint-20.2.04.orig/memory.c xfractint-20.2.04/memory.c +--- xfractint-20.2.04.orig/memory.c 2005-09-21 23:02:30.000000000 +0200 ++++ xfractint-20.2.04/memory.c 2005-09-21 23:38:25.000000000 +0200 +@@ -1,12 +1,8 @@ + #include + #include + #include +-#ifndef XFRACT +-#include ++#include + #include +-#else +-#include +-#endif + #include + + #include "port.h" +diff -u xfractint-20.2.04.orig/miscovl.c xfractint-20.2.04/miscovl.c +--- xfractint-20.2.04.orig/miscovl.c 2005-09-21 23:02:30.000000000 +0200 ++++ xfractint-20.2.04/miscovl.c 2005-09-21 23:38:25.000000000 +0200 +@@ -5,14 +5,9 @@ + #include + #include + #include +-#ifndef XFRACT + #include +-#include + #include +-#include +-#else +-#include +-#endif ++#include + /* see Fractint.c for a description of the "include" hierarchy */ + #include "port.h" + #include "prototyp.h" +@@ -24,12 +19,8 @@ + static void write_batch_parms(char *colorinf,int colorsonly, int maxcolor,int i, int j); + static void expand_comments(char far *target, char far *source); + +-#ifndef XFRACT + static void put_parm(char *parm,...); +-#else +-static void put_parm(); +-extern int fake_lut; +-#endif ++extern int fake_lut; + + static void put_parm_line(void); + static int getprec(double,double,double); +@@ -1200,24 +1191,13 @@ + } + } + +-#ifndef XFRACT + static void put_parm(char *parm,...) +-#else +-static void put_parm(va_alist) +-va_dcl +-#endif + { + char *bufptr; + va_list args; + +-#ifndef XFRACT + va_start(args,parm); +-#else +- char * parm; + +- va_start(args); +- parm = va_arg(args,char *); +-#endif + if (*parm == ' ' /* starting a new parm */ + && wbdata->len == 0) /* skip leading space */ + ++parm; +diff -u xfractint-20.2.04.orig/miscres.c xfractint-20.2.04/miscres.c +--- xfractint-20.2.04.orig/miscres.c 2005-09-21 23:02:30.000000000 +0200 ++++ xfractint-20.2.04/miscres.c 2005-09-21 23:38:25.000000000 +0200 +@@ -6,12 +6,8 @@ + #include + #include + #include +-#ifndef XFRACT + #include +-#include +-#else +-#include +-#endif ++#include + /*#ifdef __TURBOC__ + #include + #endif */ +diff -u xfractint-20.2.04.orig/printer.c xfractint-20.2.04/printer.c +--- xfractint-20.2.04.orig/printer.c 2005-09-21 23:02:30.000000000 +0200 ++++ xfractint-20.2.04/printer.c 2005-09-21 23:38:25.000000000 +0200 +@@ -87,12 +87,7 @@ + #include + #include + +-#ifndef XFRACT +-#include + #include +-#else +-#include +-#endif + + #include + +@@ -136,11 +131,7 @@ + + /******** PROTOTYPES ********/ + +-#ifndef XFRACT + static void Printer_printf(char far *fmt,...); +-#else +-static void Printer_printf(); +-#endif + static int _fastcall printer(int c); + static void _fastcall print_title(int,int,char *); + static void printer_reset(void); +@@ -1339,25 +1330,14 @@ + + /* This function prints a string to the the printer with BIOS calls. */ + +-#ifndef XFRACT + static void Printer_printf(char far *fmt,...) +-#else +-static void Printer_printf(va_alist) +-va_dcl +-#endif + { + int i; + char s[500]; + int x=0; + va_list arg; + +-#ifndef XFRACT + va_start(arg,fmt); +-#else +-char far *fmt; +-va_start(arg); +-fmt = va_arg(arg,char far *); +-#endif + + { + /* copy far to near string */ +diff -u xfractint-20.2.04.orig/prompts1.c xfractint-20.2.04/prompts1.c +--- xfractint-20.2.04.orig/prompts1.c 2005-09-21 23:02:30.000000000 +0200 ++++ xfractint-20.2.04/prompts1.c 2005-09-21 23:38:25.000000000 +0200 +@@ -1980,8 +1980,8 @@ + /* subrtn of get_file_entry, separated so that storage gets freed up */ + { + #ifdef XFRACT +- static FCODE o_instr[]={"Press "FK_F6" to select different file, "FK_F2" for details, +-"FK_F4" to toggle sort "}; ++ static FCODE o_instr[]={"Press "FK_F6" to select different file, "FK_F2" for details," ++FK_F4" to toggle sort "}; + /* keep the above split on two lines, the carriage return is needed to keep the + line length < 80 characters */ + #else +diff -u xfractint-20.2.04.orig/prototyp.h xfractint-20.2.04/prototyp.h +--- xfractint-20.2.04.orig/prototyp.h 2005-09-21 23:02:30.000000000 +0200 ++++ xfractint-20.2.04/prototyp.h 2005-09-21 23:38:47.000000000 +0200 +@@ -2,7 +2,7 @@ + #define PROTOTYP_H + + /* includes needed to define the prototypes */ +- ++#define SRCDIR "/usr/share/xfractint" + #include "mpmath.h" + #include "big.h" + #include "fractint.h" +@@ -367,13 +367,8 @@ + + extern void calcfracinit(void); + extern void adjust_corner(void); +-#ifndef XFRACT + extern int put_resume(int ,... ); + extern int get_resume(int ,... ); +-#else +-extern int put_resume(); +-extern int get_resume(); +-#endif + extern int alloc_resume(int ,int ); + extern int start_resume(void); + extern void end_resume(void); +@@ -604,14 +599,8 @@ + extern int pot_line(BYTE *,int ); + extern int sound_line(BYTE *,int ); + extern int sound_line(unsigned char *pixels,int linelen); +-#ifndef XFRACT + extern int timer(int,int (*subrtn)(),...); +-extern int _cdecl _matherr(struct exception *); +-#else +-extern int timer(); + extern int XZoomWaiting; +-#endif +- + + extern void clear_zoombox(void); + extern void flip_image(int kbdchar); diff --git a/xfractint-icon-16x16.png b/xfractint-icon-16x16.png new file mode 100644 index 0000000..63cd664 Binary files /dev/null and b/xfractint-icon-16x16.png differ diff --git a/xfractint-icon-32x32.png b/xfractint-icon-32x32.png new file mode 100644 index 0000000..40d3936 Binary files /dev/null and b/xfractint-icon-32x32.png differ diff --git a/xfractint.spec b/xfractint.spec new file mode 100644 index 0000000..3077cbd --- /dev/null +++ b/xfractint.spec @@ -0,0 +1,80 @@ +Name: xfractint +Version: 20.2.04 +Release: 3mamba +Summary: A freeware fractal generator +Group: Graphical Desktop/Applications/Educational +Vendor: openmamba +Distribution: openmamba +Packager: Silvan Calarco +URL: http://spanky.triumf.ca/www/fractint/fractint.html +Source: http://www.sdboyd56.com/xfractint/xfract%{version}.zip +Source1: http://www.sdboyd56.com/xfractint/Xfractint_maps.tar.bz2 +Source2: xfractint-icon-16x16.png +Source3: xfractint-icon-32x32.png +Patch0: xfractint-20.2.04-gcc4.patch +License: Freeware +BuildRoot: %{_tmppath}/%{name}-%{version}-root +## AUTOBUILDREQ-BEGIN +BuildRequires: glibc-devel +BuildRequires: libncurses-devel +BuildRequires: libX11-devel +## AUTOBUILDREQ-END + +%description +Fractint is a freeware fractal generator created for IBMPC's and compatible computers. It is the most versatile and extensive fractal program available for any price. The authors (of which I am not one), work very hard to keep it that way. It has many great features and it is constantly being upgraded and improved by the Stone Soup team. Keep this link as a reference to stay up-to-date with the latest developments. + +%prep +%setup -q -c -a1 +%patch0 -p1 + +%build +%make + +%install +[ "%{buildroot}" != / ] && rm -rf %{buildroot} +mkdir -p %{buildroot}{%{_bindir},%{_mandir}/man1,%{_datadir}/%{name}} +make install \ + BINDIR=%{buildroot}%{_bindir} \ + MANDIR=%{buildroot}%{_mandir}/man1 \ + SRCDIR=%{buildroot}%{_datadir}/%{name} + +# Create the system menu entry +mkdir -p %{buildroot}%{_datadir}/applications +cat > %{buildroot}%{_datadir}/applications/%{name}.desktop << EOF +[Desktop Entry] +Name=%{name} +GenericName=A fractal generator +GenericName[it]=Un generatore di frattali +Exec=konsole --notoolbar --nomenubar -e xfractint +Icon=xfractint +Terminal=0 +Type=Application +Categories=Education;Math; +X-KDE-StartupNotify=false +EOF + +install -D -m 0755 %{SOURCE2} %{buildroot}%{_datadir}/icons/hicolor/16x16/apps/xfractint.png +install -D -m 0755 %{SOURCE3} %{buildroot}%{_datadir}/icons/hicolor/32x32/apps/xfractint.png + +%clean +[ "%{buildroot}" != / ] && rm -rf %{buildroot} + +%files +%defattr(-,root,root) +%{_bindir}/xfractint +%{_mandir}/man1/xfractint.* +%dir %{_datadir}/%{name} +%{_datadir}/%{name}/* +%{_datadir}/applications/xfractint.desktop +%{_datadir}/icons/hicolor/*/apps/xfractint.png + +%changelog +* Fri Aug 23 2013 Automatic Build System 20.2.04-3mamba +- automatic rebuild by autodist + +* Tue Aug 26 2008 Tiziana Ferro 20.2.04-2mamba +- update system menu entry, vendor, distribution, mantainer +- added buildrequirements + +* Wed Sep 21 2005 Silvan Calarco 0.2.04-1qilnx +- package created by autospec