Compare commits

..

No commits in common. "rawhide" and "f39" have entirely different histories.

2 changed files with 11 additions and 69 deletions

View file

@ -1,54 +0,0 @@
diff -U 3 -dHrN a/libwcs/dateutil.c b/libwcs/dateutil.c
--- a/libwcs/dateutil.c 2021-09-15 23:45:06.000000000 +0200
+++ b/libwcs/dateutil.c 2025-01-24 09:38:40.402443820 +0100
@@ -314,6 +314,8 @@
* Return Mod of floating point number
*/
+#define _GNU_SOURCE
+
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
diff -U 3 -dHrN a/libwcs/imgetwcs.c b/libwcs/imgetwcs.c
--- a/libwcs/imgetwcs.c 2016-06-24 21:23:06.000000000 +0200
+++ b/libwcs/imgetwcs.c 2025-01-24 09:40:12.971028438 +0100
@@ -31,6 +31,7 @@
#include <stdlib.h>
#include <math.h>
#include <string.h>
+#include <strings.h>
#include "wcs.h"
#include "lwcs.h"
diff -U 3 -dHrN a/libwcs/webread.c b/libwcs/webread.c
--- a/libwcs/webread.c 2022-02-04 22:08:59.000000000 +0100
+++ b/libwcs/webread.c 2025-01-24 09:37:25.750042386 +0100
@@ -32,6 +32,7 @@
#include <stdlib.h>
#include <unistd.h>
#include <string.h>
+#include <strings.h>
#include <math.h>
#include <ctype.h>
#include "wcs.h"
@@ -976,7 +977,7 @@
memset(adrinet, 0, sizeof(struct sockaddr_in));
adrinet->sin_family = AF_INET;
adrinet->sin_port = htons(port);
- memcpy(&adrinet->sin_addr, hp->h_addr, hp->h_length);
+ memcpy(&adrinet->sin_addr, hp->h_addr_list[0], hp->h_length);
return type;
}
diff -U 3 -dHrN a/Makefile b/Makefile
--- a/Makefile 2025-01-22 08:49:29.246196532 +0100
+++ b/Makefile 2025-01-24 09:31:30.842906462 +0100
@@ -1,4 +1,7 @@
CC= gcc
+
+CFLAGS += -std=c99 -D_XOPEN_SOURCE=500
+
LIBWCS = libwcs/libwcstools.so
LIBS = -L libwcs -lwcstools -lm
#LIBS = $(LIBWCS) -lm -lnsl -lsocket

View file

@ -1,13 +1,8 @@
# https://fedoraproject.org/wiki/Changes/EncourageI686LeafRemoval
ExcludeArch: %{ix86}
%global build_type_safety_c 0
Name: wcstools
Version: 3.9.7
Release: %autorelease
Summary: Software utilities to display and manipulate the WCS of a FITS image
License: GPL-2.0-or-later
License: GPLv2+
URL: http://tdc-www.harvard.edu/wcstools
Source0: http://tdc-www.harvard.edu/software/wcstools/%{name}-%{version}.tar.gz
@ -23,10 +18,6 @@ Patch: wcstools-3.9.7_rename-libwcs-to-libwcstools.patch
# see also fedora#1450190
Patch: wcstools-3.9.7_rename-binaries.patch
# Since there's no way to reach out upstream other than email
# and I don't get replies, this patch tries to fix build with GCC15
Patch: fix_gcc15-c++23.patch
%description
Wcstools is a set of software utilities, written in C, which create,
display and manipulate the world coordinate system of a FITS or IRAF
@ -36,10 +27,8 @@ search star catalogs and manipulate images.
%package libs
Summary: Wcstools shared library
# most files have LGPL-2.0-or-later header
# COPYING is LGPL-2.1-only
License: LGPL-2.0-or-later AND LGPL-2.1-only
Summary: Wcstools shared library
License: LGPLv2+
%description libs
Shared library necessary to run wcstools and programs based on libwcs.
@ -47,7 +36,7 @@ Shared library necessary to run wcstools and programs based on libwcs.
%package devel
Summary: Libraries, includes, etc. used to develop an application with wcstools
License: LGPL-2.0-or-later AND LGPL-2.1-only
License: LGPLv2+
Requires: %{name}-libs%{_isa} = %{version}-%{release}
%description devel
This are the files needed to develop an application using wcstools.
@ -61,6 +50,13 @@ grep -rl '59 Temple Place, Suite 330, Boston, MA 02111-1307 USA' --include=*.{
%build
%if 0%{?epel} || 0%{?fedora} < 36
CFLAGS="$RPM_OPT_FLAGS"
CPPFLAGS="$RPM_OPT_FLAGS"
export CFLAGS
export CPPFLAGS
%endif
%make_build