#
# spec file for package dj64
#

Name: dj64dev
Version: 0.1.git.236.a62f1ad6
Release: 1%{?dist}
Summary: 64-bit djgpp-compatible dev suite

Group: Development/Libraries

License: GPLv3+
URL: https://github.com/stsp/dj64dev
VCS: git+https://github.com/stsp/dj64dev.git#a62f1ad6b68327d10a689c35a25325fab2b28b14:
Source0: dj64dev-a62f1ad6.tar.gz

BuildRequires: make
BuildRequires: sed
BuildRequires: bash
BuildRequires: gcc
BuildRequires: binutils
BuildRequires: binutils-x86_64-linux-gnu
BuildRequires: coreutils
BuildRequires: elfutils-libelf-devel
BuildRequires: thunk-gen
BuildRequires: pkgconf-pkg-config
BuildRequires: ctags

%description
dj64 is a 64-bit djgpp-compatible dev suite.
%end

%prep
%setup -T -b 0 -q -n dj64dev
%end

%build
make PREFIX=%{_prefix}
%end

%check
%end

%install
make install DESTDIR=%{buildroot} PREFIX=%{_prefix} LIBDIR=%{_libdir}
%end


%package dj64
Summary: dj64 runtime libraries
%description dj64
This package contains runtime libraries for dj64-built programs.
%end

%files dj64
%defattr(-,root,root)
%{_prefix}/i386-pc-dj64/lib64/*.so.*
%{_prefix}/i386-pc-dj64/lib/crt0.elf
%end

%package dj64-devel
Summary: dj64 development tools and headers
Requires: dj64dev-dj64 = 0.1.git.236.a62f1ad6
Requires: thunk-gen
Requires: djstub
Requires: gcc
Requires: binutils
Requires: binutils-x86_64-linux-gnu
Requires: pkgconf-pkg-config
Requires: bash
Requires: sed

%description dj64-devel
This package contains tools and headers for building dj64-enabled programs.
%end

%files dj64-devel
%defattr(-,root,root)
%{_prefix}/i386-pc-dj64/include
%{_prefix}/i386-pc-dj64/lib/*.o
%{_prefix}/i386-pc-dj64/lib64/*.so
%{_prefix}/i386-pc-dj64/share/*
%{_datadir}/pkgconfig/dj64.pc
%{_docdir}/dj64
%end

%package dj64-devel-static
Summary: dj64 static libraries
Requires: dj64dev-dj64-devel = 0.1.git.236.a62f1ad6

%description dj64-devel-static
This package contains static libraries for dj64.
May be needed on non-glibc systems.
%end

%files dj64-devel-static
%defattr(-,root,root)
%{_prefix}/i386-pc-dj64/lib/libc.a
%{_prefix}/i386-pc-dj64/lib64/*.a
%{_datadir}/pkgconfig/dj64_s.pc
%{_datadir}/pkgconfig/dj64static.pc
%end

%package djdev64
Summary: djdev64 runtime libraries

%description djdev64
This package contains runtime libraries for djdev64-enabled DPMI host.
%end

%files djdev64
%defattr(-,root,root)
%{_libdir}/*.so.*
%end

%package djdev64-devel
Summary: djdev64 development libraries and headers
Requires: dj64dev-djdev64 = 0.1.git.236.a62f1ad6

%description djdev64-devel
This package contains development libraries and headers for
djdev64-enabled DPMI host.
%end

%files djdev64-devel
%defattr(-,root,root)
%{_includedir}/djdev64
%{_libdir}/*.so
%{_datadir}/pkgconfig/djdev64.pc
%{_datadir}/pkgconfig/djstub64.pc
%end

%changelog
* Sat Jun 22 2024 Stas Sergeev <stsp@users.sourceforge.net> 0.1-1
(none)
%end