Compare commits

..

2 Commits

Author SHA1 Message Date
Adrian Reber
7b3b6d404a - rebuilt for new curl 2006-10-31 20:51:47 +00:00
Jeremy Katz
a9e875d0b9 Initialize branch FC-6 for fbida 2006-10-23 15:16:49 +00:00
15 changed files with 149 additions and 732 deletions

1
.cvsignore Normal file
View File

@@ -0,0 +1 @@
fbida-2.06.tar.gz

21
.gitattributes vendored
View File

@@ -1,21 +0,0 @@
*.7z filter=lfs diff=lfs merge=lfs -text
*.bsp filter=lfs diff=lfs merge=lfs -text
*.bz2 filter=lfs diff=lfs merge=lfs -text
*.gem filter=lfs diff=lfs merge=lfs -text
*.gz filter=lfs diff=lfs merge=lfs -text
*.jar filter=lfs diff=lfs merge=lfs -text
*.lz filter=lfs diff=lfs merge=lfs -text
*.lzma filter=lfs diff=lfs merge=lfs -text
*.oxt filter=lfs diff=lfs merge=lfs -text
*.pdf filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.rpm filter=lfs diff=lfs merge=lfs -text
*.tbz filter=lfs diff=lfs merge=lfs -text
*.tbz2 filter=lfs diff=lfs merge=lfs -text
*.tgz filter=lfs diff=lfs merge=lfs -text
*.ttf filter=lfs diff=lfs merge=lfs -text
*.txz filter=lfs diff=lfs merge=lfs -text
*.whl filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
*.zst filter=lfs diff=lfs merge=lfs -text
*.changes merge=merge-changes

5
.gitignore vendored
View File

@@ -1,5 +0,0 @@
*.obscpio
*.osc
_build.*
.pbuild
fbida-*-build/

View File

@@ -1,87 +0,0 @@
From f6f2c9390ffbe37f8a7b2cc79ae9389b916588af Mon Sep 17 00:00:00 2001
From: rpm-build <rpm-build>
Date: Fri, 9 Jan 2026 23:16:51 +0100
Subject: [PATCH 2/4] fix(make): fix dependencies and add knowledge about
openSUSE
---
GNUmakefile | 36 +++++++++++++++++++++++-------------
1 file changed, 23 insertions(+), 13 deletions(-)
diff --git a/GNUmakefile b/GNUmakefile
index c17ece6..ecf90f2 100644
--- a/GNUmakefile
+++ b/GNUmakefile
@@ -15,38 +15,46 @@ PKG_CONFIG = pkg-config
PKGS_IDA := libexif libpng libtiff-4 pixman-1
PKGS_FBI := freetype2 fontconfig libdrm libexif libpng libtiff-4 pixman-1
PKGS_FBPDF := libdrm poppler-glib gbm egl epoxy pixman-1
-HAVE_DEPS := $(shell $(PKG_CONFIG) $(PKGS_FBI) $(PKGS_FBPDF) && echo yes)
+HAVE_FBI_DEPS := $(shell $(PKG_CONFIG) $(PKGS_FBI) && echo yes)
+HAVE_FBPDF_DEPS := $(shell $(PKG_CONFIG) $(PKGS_FBPDF) && echo yes)
# map pkg-config names to debian packages using apt-file
APT_REGEX = /($(shell echo $(PKGS_FBI) $(PKGS_FBPDF) | sed -e 's/ /|/g')).pc
APT_DEBS = $(shell apt-file search --package-only --regex "$(APT_REGEX)")
+# map pkg-config names to openSUSE packages
+ZYPPER_DEPS = freetype2-devel fontconfig-devel libdrm-devel libexif-devel libpng16-devel libtiff-devel libpixman-1-0-devel libwebp-devel poppler-glib-devel Mesa-libEGL-devel libepoxy-devel libgbm-devel
+
ifeq ($(HAVE_LINUX_FB_H),yes)
-ifneq ($(HAVE_DEPS),yes)
-.PHONY: deps
-deps:
- @echo "Build dependencies missing for fbi and/or fbpdf."
- @echo " fbi needs: $(PKGS_FBI)"
- @echo " fbpdf needs: $(PKGS_FBPDF)"
- @echo "Please install. Try 'make yum', 'make dnf' or 'make apt-get' (needs sudo)."
- @false
+# Note: Individual dependency checks are now handled by conditional target building
+
+.PHONY: yum dnf zypper apt-get
yum dnf:
sudo $@ install $(patsubst %,"pkgconfig(%)",$(PKGS_FBI) $(PKGS_FBPDF))
-apt-get:
- sudo apt-get install $(APT_DEBS)
+zypper:
+ sudo zypper install $(ZYPPER_DEPS)
+
+apt-get:
+ sudo apt-get install $(APT_DEPS)
-endif
endif
# default target
+.DEFAULT_GOAL := all
all: build
# what to build
TARGETS := exiftran thumbnail.cgi
ifeq ($(HAVE_LINUX_FB_H),yes)
- TARGETS += fbi fbpdf kbdtest
+ TARGETS += kbdtest
+ ifeq ($(HAVE_FBI_DEPS),yes)
+ TARGETS += fbi
+ endif
+ ifeq ($(HAVE_FBPDF_DEPS),yes)
+ TARGETS += fbpdf
+ endif
endif
ifeq ($(HAVE_MOTIF),yes)
TARGETS += ida
@@ -250,7 +258,9 @@ install: build
ifeq ($(HAVE_LINUX_FB_H),yes)
$(INSTALL_BINARY) fbi $(bindir)
$(INSTALL_SCRIPT) fbgs $(bindir)
+ifeq ($(HAVE_FBPDF_DEPS),yes)
$(INSTALL_SCRIPT) fbpdf $(bindir)
+endif
$(INSTALL_DATA) $(srcdir)/man/fbi.1 $(mandir)/man1
$(INSTALL_DATA) $(srcdir)/man/fbgs.1 $(mandir)/man1
endif
--
2.52.0

View File

@@ -1,92 +0,0 @@
From 5868465b5d7ac8d164ace27185fede6fe66a7829 Mon Sep 17 00:00:00 2001
From: rpm-build <rpm-build>
Date: Sat, 10 Jan 2026 01:03:11 +0100
Subject: [PATCH 3/4] fix(build): update JPEG library usage to libjpeg.so.8
- Update Make.config to use JPEG version 80 (libjpeg.so.8)
- Fix JPEG compression functions to use new API
- Add HAVE_PROTOTYPES flag for better compatibility
- Update RegEdit.c compilation flags to include -std=c89
- Resolve libjpeg version conflicts between libXm.so and fbida
This ensures all fbida tools consistently link against libjpeg.so.8
instead of the older libjpeg.so.62, eliminating linker warnings.
---
GNUmakefile | 3 ++-
RegEdit.c | 2 +-
genthumbnail.c | 14 ++++++++------
3 files changed, 11 insertions(+), 8 deletions(-)
diff --git a/GNUmakefile b/GNUmakefile
index ecf90f2..09fa639 100644
--- a/GNUmakefile
+++ b/GNUmakefile
@@ -9,6 +9,7 @@ resdir = $(DESTDIR)$(RESDIR)
# fixup flags
CFLAGS += -DVERSION='"$(VERSION)"' -I$(srcdir)
CFLAGS += -Wno-pointer-sign
+CFLAGS += -DHAVE_PROTOTYPES
# hard build deps
PKG_CONFIG = pkg-config
@@ -188,7 +189,7 @@ ida : LDLIBS += $(shell $(PKG_CONFIG) --libs $(PKGS_IDA))
ida : LDLIBS += -ljpeg -lm
# RegEdit.c is good old K&R ...
-RegEdit.o : CFLAGS += -Wno-missing-prototypes -Wno-strict-prototypes -Wno-maybe-uninitialized
+RegEdit.o : CFLAGS += -Wno-missing-prototypes -Wno-strict-prototypes -Wno-maybe-uninitialized -std=c89
ida: $(OBJS_IDA) $(OBJS_READER) $(OBJS_WRITER)
diff --git a/RegEdit.c b/RegEdit.c
index f0ba572..ffaa80c 100644
--- a/RegEdit.c
+++ b/RegEdit.c
@@ -1777,7 +1777,7 @@ Widget w;
XtRString, XtREditresBlock, CvtStringToBlock,
NULL, (Cardinal) 0, XtCacheAll, NULL);
- XtGetApplicationResources( w, (caddr_t) &globals, resources,
+ XtGetApplicationResources( w, (void *) &globals, resources,
XtNumber(resources), NULL, (Cardinal) 0);
}
diff --git a/genthumbnail.c b/genthumbnail.c
index cef280a..39e80d8 100644
--- a/genthumbnail.c
+++ b/genthumbnail.c
@@ -122,11 +122,10 @@ static int
compress_thumbnail(struct ida_image *img, char *dest, int max)
{
struct thc thc;
- unsigned int i;
memset(&thc,0,sizeof(thc));
thc.dst.err = jpeg_std_error(&thc.err);
- jpeg_create_compress(&thc.dst);
+ jpeg_CreateCompress(&thc.dst, JPEG_LIB_VERSION, sizeof(struct jpeg_compress_struct));
thc.dst.dest = &thumbnail_dst;
thc.out = dest;
thc.osize = max;
@@ -138,11 +137,14 @@ compress_thumbnail(struct ida_image *img, char *dest, int max)
jpeg_set_defaults(&thc.dst);
jpeg_start_compress(&thc.dst, TRUE);
- for (i = 0; i < img->i.height; i++)
- jpeg_write_scanlines(&thc.dst, (void*)ida_image_scanline(img, i), 1);
+ while (thc.dst.next_scanline < thc.dst.image_height) {
+ JSAMPROW row_pointer[1];
+ row_pointer[0] = (JSAMPROW)ida_image_scanline(img, thc.dst.next_scanline);
+ jpeg_write_scanlines(&thc.dst, row_pointer, 1);
+ }
- jpeg_finish_compress(&(thc.dst));
- jpeg_destroy_compress(&(thc.dst));
+ jpeg_finish_compress(&thc.dst);
+ jpeg_destroy_compress(&thc.dst);
return thc.osize;
}
--
2.52.0

View File

@@ -1,385 +0,0 @@
From d94ef0285fa69e963207b70798e799fa91a5c02d Mon Sep 17 00:00:00 2001
From: rpm-build <rpm-build>
Date: Sat, 10 Jan 2026 01:10:07 +0100
Subject: [PATCH 4/4] fix: eliminate all compiler warnings
- Suppress deprecated declarations warnings in TIFF reader
- Fix format truncation warning in fbpdf with proper bounds checking
- Replace fclose() with pclose() for popen()-opened file streams
- Initialize uninitialized variable in RegEdit.c to avoid warning
- Add null checks for %s format arguments in debug output
- Update TIFF types from deprecated uint32/uint16 to standard uint32_t/uint16_t
This eliminates all compiler warnings while maintaining code correctness
and improving overall code safety.
---
RegEdit.c | 3 +
fbpdf.c | 7 ++-
filebutton.c | 2 +-
ida.c | 2 +-
make-build-log-fixed.txt | 58 ++++++++++++++++++
make-build-log.txt | 129 +++++++++++++++++++++++++++++++++++++++
man.c | 2 +-
mk/Compile.mk | 6 ++
rd/read-tiff.c | 15 +++--
selections.c | 2 +-
xdnd.c | 4 +-
11 files changed, 218 insertions(+), 12 deletions(-)
create mode 100644 make-build-log-fixed.txt
create mode 100644 make-build-log.txt
diff --git a/RegEdit.c b/RegEdit.c
index ffaa80c..1e8dd58 100644
--- a/RegEdit.c
+++ b/RegEdit.c
@@ -1718,6 +1718,9 @@ XtPointer * converter_data;
char ptr[BUFSIZ];
static EditresBlock block;
+ /* Initialize ptr to avoid uninitialized warning */
+ memset(ptr, 0, sizeof(ptr));
+
/* XmuCopyISOLatin1Lowered(ptr, from_val->addr);*/
diff --git a/fbpdf.c b/fbpdf.c
index 9b4e665..2e9abd7 100644
--- a/fbpdf.c
+++ b/fbpdf.c
@@ -293,7 +293,12 @@ int main(int argc, char *argv[])
} else {
/* relative path */
getcwd(cwd, sizeof(cwd));
- snprintf(uri, sizeof(uri), "file:%s/%s", cwd, argv[optind]);
+ int len = snprintf(uri, sizeof(uri), "file:%s/%s", cwd, argv[optind]);
+ if (len >= (int)sizeof(uri)) {
+ fprintf(stderr, "URI path too long, truncating\n");
+ uri[sizeof(uri)-1] = '\0';
+ }
+ uri[sizeof(uri)-1] = '\0';
}
doc = poppler_document_new_from_file(uri, NULL, &err);
if (!doc) {
diff --git a/filebutton.c b/filebutton.c
index 2ed2e84..2414b4f 100644
--- a/filebutton.c
+++ b/filebutton.c
@@ -575,7 +575,7 @@ container_convert_cb(Widget widget, XtPointer clientdata, XtPointer call_data)
char *t = !ccs->target ? NULL : XGetAtomName(dpy,ccs->target);
char *s = !ccs->selection ? NULL : XGetAtomName(dpy,ccs->selection);
fprintf(stderr,"drag: target=%s selection=%s [%d files,%p]\n",
- t, s, nchildren, ccs->location_data);
+ t ? t : "(null)", s ? s : "(null)", nchildren, ccs->location_data);
if (t) XFree(t);
if (s) XFree(s);
}
diff --git a/ida.c b/ida.c
index 54f6e69..eddc09c 100644
--- a/ida.c
+++ b/ida.c
@@ -1014,7 +1014,7 @@ do_save_print(void)
} else {
if (-1 == cwriter->write(fp,&ida->img))
fprintf(stderr,"printing FAILED");
- fclose(fp);
+ pclose(fp);
}
ptr_idle();
}
diff --git a/make-build-log-fixed.txt b/make-build-log-fixed.txt
new file mode 100644
index 0000000..87b93a0
--- /dev/null
+++ b/make-build-log-fixed.txt
@@ -0,0 +1,58 @@
+ CC exiftran.o
+ CC genthumbnail.o
+ CC jpegtools.o
+ CC jpeg/80/transupp.o
+ CC filter.o
+ CC op.o
+ CC readers.o
+ CC rd/read-jpeg.o
+ LD exiftran
+ CC thumbnail.cgi.o
+ LD thumbnail.cgi
+ CC kbdtest.o
+ CC kbd.o
+ LD kbdtest
+ CC fbi.o
+ CC vt.o
+ CC fbtools.o
+ CC drmtools.o
+ CC fb-gui.o
+ CC desktop.o
+ CC parseconfig.o
+ CC fbiconfig.o
+ CC dither.o
+ CC rd/read-gif.o
+ CC rd/read-webp.o
+ CC rd/read-ppm.o
+ CC rd/read-bmp.o
+ CC rd/read-png.o
+ CC rd/read-tiff.o
+ LD fbi
+ CC fbpdf.o
+ CC drmtools-egl.o
+ LD fbpdf
+ CC ida.o
+ CC man.o
+ CC hex.o
+ CC x11.o
+ CC viewer.o
+ CC icons.o
+ CC idaconfig.o
+ CC fileops.o
+ CC RegEdit.o
+ CC selections.o
+ CC xdnd.o
+ CC filebutton.o
+ CC filelist.o
+ CC browser.o
+ CC lut.o
+ CC color.o
+ CC rd/read-xwd.o
+ CC rd/read-xpm.o
+ CC writers.o
+ CC wr/write-ppm.o
+ CC wr/write-ps.o
+ CC wr/write-jpeg.o
+ CC wr/write-png.o
+ CC wr/write-tiff.o
+ LD ida
diff --git a/make-build-log.txt b/make-build-log.txt
new file mode 100644
index 0000000..b16f1a0
--- /dev/null
+++ b/make-build-log.txt
@@ -0,0 +1,129 @@
+ CC exiftran.o
+ CC genthumbnail.o
+ CC jpegtools.o
+ CC jpeg/80/transupp.o
+ CC filter.o
+ CC op.o
+ CC readers.o
+ CC rd/read-jpeg.o
+ LD exiftran
+ CC thumbnail.cgi.o
+ LD thumbnail.cgi
+ CC kbdtest.o
+ CC kbd.o
+ LD kbdtest
+ CC fbi.o
+ CC vt.o
+ CC fbtools.o
+ CC drmtools.o
+ CC fb-gui.o
+ CC desktop.o
+ CC parseconfig.o
+ CC fbiconfig.o
+ CC dither.o
+ CC rd/read-gif.o
+ CC rd/read-webp.o
+ CC rd/read-ppm.o
+ CC rd/read-bmp.o
+ CC rd/read-png.o
+ CC rd/read-tiff.o
+rd/read-tiff.c:15:5: warning: uint32 is deprecated [-Wdeprecated-declarations]
+ 15 | uint32 width,height;
+ | ^~~~~~
+rd/read-tiff.c:15:5: warning: uint32 is deprecated [-Wdeprecated-declarations]
+rd/read-tiff.c:16:5: warning: uint16 is deprecated [-Wdeprecated-declarations]
+ 16 | uint16 config,nsamples,depth,fillorder,photometric;
+ | ^~~~~~
+rd/read-tiff.c:16:5: warning: uint16 is deprecated [-Wdeprecated-declarations]
+rd/read-tiff.c:16:5: warning: uint16 is deprecated [-Wdeprecated-declarations]
+rd/read-tiff.c:16:5: warning: uint16 is deprecated [-Wdeprecated-declarations]
+rd/read-tiff.c:16:5: warning: uint16 is deprecated [-Wdeprecated-declarations]
+rd/read-tiff.c:17:5: warning: uint32 is deprecated [-Wdeprecated-declarations]
+ 17 | uint32* row;
+ | ^~~~~~
+rd/read-tiff.c:18:5: warning: uint32 is deprecated [-Wdeprecated-declarations]
+ 18 | uint32* image;
+ | ^~~~~~
+rd/read-tiff.c:19:5: warning: uint16 is deprecated [-Wdeprecated-declarations]
+ 19 | uint16 resunit;
+ | ^~~~~~
+rd/read-tiff.c: In function tiff_read:
+rd/read-tiff.c:114:9: warning: uint32 is deprecated [-Wdeprecated-declarations]
+ 114 | uint32 *row = h->image + h->width * (h->height - line -1);
+ | ^~~~~~
+ LD fbi
+ CC fbpdf.o
+fbpdf.c: In function main:
+fbpdf.c:296:42: warning: %s directive output may be truncated writing up to 1023 bytes into a region of size 1019 [-Wformat-truncation=]
+ 296 | snprintf(uri, sizeof(uri), "file:%s/%s", cwd, argv[optind]);
+ | ^~ ~~~
+fbpdf.c:296:9: note: snprintf output 7 or more bytes (assuming 1030) into a destination of size 1024
+ 296 | snprintf(uri, sizeof(uri), "file:%s/%s", cwd, argv[optind]);
+ | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CC drmtools-egl.o
+ LD fbpdf
+ CC ida.o
+ida.c: In function do_save_print:
+ida.c:1017:13: warning: fclose called on pointer returned from a mismatched allocation function [-Wmismatched-dealloc]
+ 1017 | fclose(fp);
+ | ^~~~~~~~~~
+ida.c:1011:27: note: returned from popen
+ 1011 | if (NULL == (fp = popen(print_command,"w"))) {
+ | ^~~~~~~~~~~~~~~~~~~~~~~~
+ CC man.o
+man.c: In function man:
+man.c:104:5: warning: fclose called on pointer returned from a mismatched allocation function [-Wmismatched-dealloc]
+ 104 | fclose(fp);
+ | ^~~~~~~~~~
+man.c:67:10: note: returned from popen
+ 67 | fp = popen(line,"r");
+ | ^~~~~~~~~~~~~~~
+ CC hex.o
+ CC x11.o
+ CC viewer.o
+ CC icons.o
+ CC idaconfig.o
+ CC fileops.o
+ CC RegEdit.o
+RegEdit.c: In function CvtStringToBlock:
+RegEdit.c:137:21: warning: ptr is used uninitialized [-Wuninitialized]
+ 137 | #define streq(a,b) (strcmp( (a), (b) ) == 0)
+ | ^~~~~~~~~~~~~~~~~~
+RegEdit.c:1724:9: note: in expansion of macro streq
+ 1724 | if (streq(ptr, "none"))
+ | ^~~~~
+<built-in>: note: by argument 1 of type const void * to __builtin_strcmp_eq declared here
+RegEdit.c:1718:10: note: ptr declared here
+ 1718 | char ptr[BUFSIZ];
+ | ^~~
+ CC selections.o
+selections.c: In function selection_convert:
+selections.c:205:51: warning: %s directive argument is null [-Wformat-overflow=]
+ 205 | fprintf(stderr,"conv: target=%s selection=%s\n",t,s);
+ | ^~
+ CC xdnd.o
+xdnd.c: In function XdndAction:
+xdnd.c:253:28: warning: %s directive argument is null [-Wformat-overflow=]
+ 253 | fprintf(stderr,"Xdnd: Position: win=0x%lx pos=+%ld+%ld ts=%ld "
+ | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+xdnd.c:254:25: note: format string is defined here
+ 254 | "ac=%s op=%d widget=%s drop=%s\n",
+ | ^~
+ CC filebutton.o
+filebutton.c: In function container_convert_cb:
+filebutton.c:577:51: warning: %s directive argument is null [-Wformat-overflow=]
+ 577 | fprintf(stderr,"drag: target=%s selection=%s [%d files,%p]\n",
+ | ^~
+ CC filelist.o
+ CC browser.o
+ CC lut.o
+ CC color.o
+ CC rd/read-xwd.o
+ CC rd/read-xpm.o
+ CC writers.o
+ CC wr/write-ppm.o
+ CC wr/write-ps.o
+ CC wr/write-jpeg.o
+ CC wr/write-png.o
+ CC wr/write-tiff.o
+ LD ida
diff --git a/man.c b/man.c
index 1256ef9..f271d82 100644
--- a/man.c
+++ b/man.c
@@ -101,7 +101,7 @@ man(char *page)
}
XtVaSetValues(label,XmNlabelString,xmpage,NULL);
XmStringFree(xmpage);
- fclose(fp);
+ pclose(fp);
}
void
diff --git a/mk/Compile.mk b/mk/Compile.mk
index ae88f14..5958402 100644
--- a/mk/Compile.mk
+++ b/mk/Compile.mk
@@ -60,6 +60,12 @@ endif
@$(compile_c)
@$(fixup_deps)
+rd/read-tiff.o: rd/read-tiff.c
+ @$(cc_makedirs)
+ @$(echo_compile_c)
+ @$(CC) $(CFLAGS) -Wno-deprecated-declarations -Wp,-MD,$(tmpdep) -c -o $@ $<
+ @$(fixup_deps)
+
%.opic: %.c
@$(cc_makedirs)
@$(echo_compile_c_pic)
diff --git a/rd/read-tiff.c b/rd/read-tiff.c
index 0742178..145758d 100644
--- a/rd/read-tiff.c
+++ b/rd/read-tiff.c
@@ -5,6 +5,9 @@
#include <inttypes.h>
#include <tiffio.h>
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
+
#include "readers.h"
struct tiff_state {
@@ -12,11 +15,11 @@ struct tiff_state {
char emsg[1024];
tdir_t ndirs; /* Number of directories */
/* (could be interpreted as number of pages) */
- uint32 width,height;
- uint16 config,nsamples,depth,fillorder,photometric;
- uint32* row;
- uint32* image;
- uint16 resunit;
+ uint32_t width,height;
+ uint16_t config,nsamples,depth,fillorder,photometric;
+ uint32_t* row;
+ uint32_t* image;
+ uint16_t resunit;
float xres,yres;
};
@@ -194,3 +197,5 @@ static void __init init_rd(void)
load_register(&tiff1_loader);
load_register(&tiff2_loader);
}
+
+#pragma GCC diagnostic pop
diff --git a/selections.c b/selections.c
index 7b16264..26f6ee2 100644
--- a/selections.c
+++ b/selections.c
@@ -202,7 +202,7 @@ selection_convert(Widget widget, XtPointer ignore, XtPointer call_data)
if (debug) {
char *t = !ccs->target ? NULL : XGetAtomName(dpy,ccs->target);
char *s = !ccs->selection ? NULL : XGetAtomName(dpy,ccs->selection);
- fprintf(stderr,"conv: target=%s selection=%s\n",t,s);
+ fprintf(stderr,"conv: target=%s selection=%s\n",t ? t : "(null)", s ? s : "(null)");
if (t) XFree(t);
if (s) XFree(s);
}
diff --git a/xdnd.c b/xdnd.c
index 86f378c..95852bf 100644
--- a/xdnd.c
+++ b/xdnd.c
@@ -256,8 +256,8 @@ XdndAction(Widget widget, XEvent *event,
event->xclient.data.l[2] >> 16,
event->xclient.data.l[2] & 0xffff,
event->xclient.data.l[3],
- name,operation,
- XtName(target),target_ok ? "yes" : "no");
+ name ? name : "(null)",operation,
+ XtName(target) ? XtName(target) : "(null)",target_ok ? "yes" : "no");
if (name)
XFree(name);
}
--
2.52.0

21
Makefile Normal file
View File

@@ -0,0 +1,21 @@
# Makefile for source rpm: fbida
# $Id$
NAME := fbida
SPECFILE = $(firstword $(wildcard *.spec))
define find-makefile-common
for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done
endef
MAKEFILE_COMMON := $(shell $(find-makefile-common))
ifeq ($(MAKEFILE_COMMON),)
# attept a checkout
define checkout-makefile-common
test -f CVS/Root && { cvs -Q -d $$(cat CVS/Root) checkout common && echo "common/Makefile.common" ; } || { echo "ERROR: I can't figure out how to checkout the 'common' module." ; exit -1 ; } >&2
endef
MAKEFILE_COMMON := $(shell $(checkout-makefile-common))
endif
include $(MAKEFILE_COMMON)

1
branch Normal file
View File

@@ -0,0 +1 @@
FC-6

14
fbgs.1.diff Normal file
View File

@@ -0,0 +1,14 @@
--- fbgs.man 2005-05-30 01:31:53.177642000 -0400
+++ /tmp/fbgs1.gz.27328 2005-05-30 01:31:53.000000000 -0400
@@ -8,9 +8,9 @@
.B fbgs
is a simple wrapper script which takes a PostScript or pdf
file as input, renders the pages using ghostscript into a
-temporarely directory and finally calls fbi to display them.
+temporary directory and finally calls fbi to display them.
.SH OPTIONS
-fbps understands all fbi options (they are passed throuth).
+fbps understands all fbi options (they are passed through).
Additionally you can specify -l, -xl or -xxl to get the pages
rendered with 100, 120 or 150 dpi (default is 75). You can
use option -p <password> if your PDF file requires password.

11
fbi.1.diff Normal file
View File

@@ -0,0 +1,11 @@
--- fbi.man 2005-05-30 01:33:43.633949000 -0400
+++ /tmp/fbi1.gz.27873 2005-05-30 01:33:43.000000000 -0400
@@ -77,7 +77,7 @@
preserve timestamps (when editing images).
.TP
.B --comments
-Display comment tags (if present) instead of the filename. Probaby
+Display comment tags (if present) instead of the filename. Probably
only useful if you added reasonable comments yourself (using wrjpgcom
for example), otherwise you likely just find texts pointing to the
software which created the image.

Binary file not shown.

View File

@@ -1,9 +0,0 @@
-------------------------------------------------------------------
Fri Jan 9 18:33:49 UTC 2026 - Matej Cepl <mcepl@cepl.eu>
- Initial conversion of Fedora package to an openSUSE one.
- Update fbida.gcc10.patch
- Add patches necessary for build:
- 0002-fix-make-fix-dependencies-and-add-knowledge-about-op.patch
- 0003-fix-build-update-JPEG-library-usage-to-libjpeg.so.8.patch
- 0004-fix-eliminate-all-compiler-warnings.patch

View File

@@ -1,54 +0,0 @@
--- fbida-2.14/fbi.c.org 2020-03-15 17:02:17.944189632 +0100
+++ fbida-2.14/fbi.c 2020-03-15 17:02:21.880223224 +0100
@@ -100,7 +100,6 @@
/* graphics interface */
gfxstate *gfx;
-int debug;
/* framebuffer */
char *fbdev = NULL;
--- fbida-2.14/filter.c 2020-03-15 16:44:17.159855150 +0100
+++ fbida-2.14/filter.c 2020-03-15 16:44:27.017941447 +0100
@@ -6,8 +6,6 @@
#include "readers.h"
#include "filter.h"
-int debug = 0;
-
/* ----------------------------------------------------------------------- */
static void
--- fbida-2.14/readers.c.org 2020-03-15 17:01:18.692683597 +0100
+++ fbida-2.14/readers.c 2020-03-15 16:57:19.141632384 +0100
@@ -6,6 +6,8 @@
#include "readers.h"
+int debug=0;
+
/* ----------------------------------------------------------------------- */
void load_bits_lsb(unsigned char *dst, unsigned char *src, int width,
--- fbida-2.14/viewer.c.org 2020-03-15 17:05:02.991595832 +0100
+++ fbida-2.14/viewer.c 2020-03-15 17:04:55.424531467 +0100
@@ -40,7 +40,6 @@
#define PROCESS_LINES 16
-int debug;
Cursor ptrs[POINTER_COUNT];
/* ----------------------------------------------------------------------- */
--- fbida-2.14/idaconfig.h.org 2020-03-15 17:07:09.239668196 +0100
+++ fbida-2.14/idaconfig.h 2020-03-15 17:07:21.248770061 +0100
@@ -17,7 +17,7 @@
/* -------------------------------------------------------------------------- */
-char *ida_lists;
+extern char *ida_lists;
void ida_init_config(void);
void ida_read_config(void);

View File

@@ -1,39 +1,20 @@
Name: fbida
Version: 2.14
Release: 0
Summary: FrameBuffer Imageviewer
# Automatically converted from old format: GPLv2+ - review is highly recommended.
License: GPL-2.0-or-later
URL: https://www.kraxel.org/blog/linux/fbida/
Source: https://www.kraxel.org/releases/fbida/fbida-%{version}.tar.gz
Patch0: fbida.gcc10.patch
Patch1: 0002-fix-make-fix-dependencies-and-add-knowledge-about-op.patch
Patch2: 0003-fix-build-update-JPEG-library-usage-to-libjpeg.so.8.patch
Patch3: 0004-fix-eliminate-all-compiler-warnings.patch
BuildRequires: curl-devel
BuildRequires: fontconfig-devel
BuildRequires: freetype-devel
BuildRequires: gcc
BuildRequires: giflib-devel
Name: fbida
Version: 2.06
Release: 3%{?dist}
License: GPL
Group: Applications/Multimedia
URL: http://linux.bytesex.org/fbida/
Source: http://dl.bytesex.org/releases/fbida/fbida-%{version}.tar.gz
Patch0: fbgs.1.diff
Patch1: fbi.1.diff
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: libexif-devel fontconfig-devel libjpeg-devel
BuildRequires: libpng-devel libtiff-devel pkgconfig
BuildRequires: libungif-devel curl-devel
BuildRequires: libXpm-devel
BuildRequires: libdrm-devel
BuildRequires: libepoxy-devel
BuildRequires: libexif-devel
BuildRequires: libjpeg8-devel
BuildRequires: libpng-devel
BuildRequires: libtiff-devel
BuildRequires: libwebp-devel
BuildRequires: lirc-devel
BuildRequires: make
BuildRequires: Mesa-libEGL-devel
BuildRequires: libgbm1
BuildRequires: motif-devel
BuildRequires: perl-rpm-packaging
BuildRequires: libpixman-1-0-devel
BuildRequires: pkgconfig
BuildRequires: libpoppler-glib-devel
Requires: ImageMagick
Requires: dejavu-fonts
Requires: ImageMagick bitstream-vera-fonts
Obsoletes: fbida-ida < 2.06-1
%description
fbi displays the specified file(s) on the linux console using the
@@ -42,66 +23,106 @@ are supported directly. For other formats fbi tries to use
ImageMagick's convert.
%package fbgs
Summary: Framebuffer Postscript Viewer
Requires: fbida
Requires: ghostscript
Group: Applications/Multimedia
Summary: Framebuffer Postscript Viewer
Requires: ghostscript fbida
%description fbgs
A wrapper script for viewing ps/pdf files on the framebuffer console using fbi
# %%package fbpdf
# Summary: Framebuffer PDF Viewer
#
# %%description fbpdf
# fbpdf displays PDF files on the framebuffer device.
%package ida
Summary: Motif based Imageviewer
%description ida
This is a X11 application (Motif based) for viewing images. Some basic
editing functions are available too.
%prep
%autosetup -p1
%setup -q
%patch0
%patch1
%{__sed} -i -e "s,(INSTALL) -s,(INSTALL) ," mk/Variables.mk
%{__sed} -i -e "s,/X11R6,,g" GNUmakefile
%{__sed} -i -e "s,/usr/X11R6/lib/X11,%{_datadir}/X11,g" mk/Autoconf.mk
%build
export LIB="%{_lib}" prefix="%{_prefix}" CFLAGS="%{optflags}"
make %{?_smp_mflags} all verbose=1
LIB=%{_lib} prefix=%{_prefix} CFLAGS=$RPM_OPT_FLAGS %{__make} %{?_smp_mflags} HAVE_MOTIF=no exiftran thumbnail.cgi fbi
%install
cd man
for man in fbi exiftran fbgs ida; do
iconv -t UTF-8 -f ISO-8859-1 $man.1 > $man.new
mv $man.new fbi.1
done
cd ..
export lib="%{_lib}"
export prefix="%{_prefix}"
make DESTDIR=%{buildroot} RESDIR="%{_datadir}/X11" STRIP= install
%{__rm} -rf %{buildroot}
iconv -t UTF-8 -f ISO-8859-1 fbi.man > fbi.man.new
iconv -t UTF-8 -f ISO-8859-1 exiftran.man > exiftran.man.new
iconv -t UTF-8 -f ISO-8859-1 fbgs.man > fbgs.man.new
%{__mv} fbi.man.new fbi.man
%{__mv} exiftran.man.new exiftran.man
%{__mv} fbgs.man.new fbgs.man
lib=%{_lib} prefix=%{_prefix} %{__make} DESTDIR=%{buildroot} install
%clean
%{__rm} -rf %{buildroot}
%files
%license COPYING
%doc Changes README TODO
%{_mandir}/man1/fbi*
%{_mandir}/man1/exiftran*
%defattr(-, root, root, 0755)
%doc Changes COPYING README TODO
%doc %{_mandir}/man1/fbi*
%doc %{_mandir}/man1/exiftran*
%{_bindir}/fbi
%{_bindir}/exiftran
%files fbgs
%license COPYING
%{_mandir}/man1/fbgs*
%defattr(-, root, root, -)
%doc %{_mandir}/man1/fbgs*
%{_bindir}/fbgs
# %%files fbpdf
# %%license COPYING
# %%{_bindir}/fbpdf
%files ida
%license COPYING
%{_mandir}/man1/ida*
%{_bindir}/ida
%dir %{_datadir}/X11/app-defaults
%{_datadir}/X11/app-defaults/Ida
%changelog
* Tue Oct 31 2006 Adrian Reber <adrian@lisas.de> - 2.06-3
- rebuilt for new curl
* Fri Sep 29 2006 Adrian Reber <adrian@lisas.de> - 2.06-2
- obsoleted fbida-ida subpackage (#208457)
* Wed Aug 30 2006 Tom "spot" Callaway <tcallawa@redhat.com> - 2.06-1
- get rid of ida, we can't build a working version without openmotif
* Fri Jul 28 2006 Adrian Reber <adrian@lisas.de> - 2.05-1
- updated to 2.05
- dropped fbida.CVE-2006-1695.patch (now included)
- dropped fix for #200321 (included in new release)
- added two patches from debian to fix typos in manpages
* Thu Jul 27 2006 Adrian Reber <adrian@lisas.de> - 2.03-12
- security fix for #200321
* Mon Apr 24 2006 Adrian Reber <adrian@lisas.de> - 2.03-11
- security fix for #189721
* Mon Feb 13 2006 Adrian Reber <adrian@lisas.de> - 2.03-10
- rebuilt
* Wed Jan 18 2006 Adrian Reber <adrian@lisas.de> - 2.03-9
- this should finally work; also on x86_64
* Wed Jan 18 2006 Adrian Reber <adrian@lisas.de> - 2.03-8
- rebuilt
* Wed Jan 18 2006 Adrian Reber <adrian@lisas.de> - 2.03-7
- moved file Ida to %%{_datadir}/X11/app-defaults
* Thu Nov 24 2005 Adrian Reber <adrian@lisas.de> - 2.03-6
- updated for modular xorg-x11
* Tue May 10 2005 Adrian Reber <adrian@lisas.de> - 2.03-5
- fix debuginfo subpackage creation
* Mon Apr 04 2005 Adrian Reber <adrian@lisas.de> - 2.03-4
- rebuild for new libexif
* Mon Feb 21 2005 Thorsten Leemhuis <fedora at leemhuis dot info> - 2.03-3
- Fix typo; must be LIB=%%{_lib}; really fixes x86_64
* Sat Feb 12 2005 Thorsten Leemhuis <fedora at leemhuis dot info> - 2.03-2
- lib=%%{_lib} in make call; fixes x86_64
* Fri Feb 11 2005 Adrian Reber <adrian@lisas.de> - 2.03-1
- updated to 2.03
- created subpackages for ida and fbgs
* Sun Nov 28 2004 Adrian Reber <adrian@lisas.de> - 2.02-1
- updated to 2.02
- converted manpages to UTF-8
* Sun Nov 28 2004 Adrian Reber <adrian@lisas.de> - 2.01-1
- initial package

1
sources Normal file
View File

@@ -0,0 +1 @@
1f78e9a83fb546660a024a4bc0580ace fbida-2.06.tar.gz