Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WIP for sndio RPM SPEC #219

Open
wants to merge 5 commits into
base: wip-testing
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions packages/sndio/SOURCES/sndio-sgug-fix.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
diff --git a/configure b/configure
index a0a0c7d..a5862b0 100755
--- configure
+++ configure
@@ -112,7 +112,7 @@ case `uname` in
rmidi=no
user=sndiod
so_link="libsndio.so"
- defs='-D__sgi_irix'
+ defs='-D__sgi_irix -D_SGI_COMPILER_VERSION'
Copy link
Collaborator Author

@Jenna64bit Jenna64bit Sep 8, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

SGUG GCC, it turns out, is not mipspro - but all the macros check for both of these defines. It compiles well with, but is very unhappy without as we're missing lots of variable declarations.

esac

# shell word separator (none)
58 changes: 58 additions & 0 deletions packages/sndio/SPECS/sndio.spec
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
Summary: OpenBSD SNDIO audio daemon ported to IRix by TruHobbyist
Name: sndio
Version: 1.8.1
Release: 1
License: BSD
Group: System
Source0: https://gitea.irixce.org/TruHobbyist/sndio/sndio.tar.gz
# Note: cloned locally, moved to "sndiod-1.8.1" tar'd & gzipped and named sndio.tar.gz
# put that in $rpmbuild/SOURCES
Patch0: sndio-sgug-fix.patch

%description
Audio daemon from the BSD folks, modified to be compatible with SGI/Irix systems.

%prep
%setup -q
%autopatch -p0

%build
# Not using Macro as it passes flags that get rejected, these are otherwise the same as defaults
./configure --prefix=/usr/sgug --libdir=/usr/sgug/lib32 --pkgconfdir=/usr/sgug/lib32/pkgconfig
make

%install
rm -rf %{buildroot}
%make_install prefix=${RPM_BUILD_ROOT}%{_prefix}
## TODO
## ADD SERVICES here
## contrib/init.d.sndiod.sgi
## ADD sndiod USER during %pre

%clean
rm -rf %{buildroot}

%files
%defattr(-,root,root,-)
%{_bindir}/aucat
%{_bindir}/midicat
%{_bindir}/sndioctl
%{_bindir}/sndiod
%{_includedir}/sndio.h
%{_libdir}/pkgconfig/sndio.pc
%{_libdir}/libsndio.so
%{_libdir}/libsndio.so.7.2
%doc /usr/sgug/share/man/man1/aucat.1.gz
%doc /usr/sgug/share/man/man1/midicat.1.gz
%doc /usr/sgug/share/man/man1/sndioctl.1.gz
%doc /usr/sgug/share/man/man3/mio_*.3.gz
%doc /usr/sgug/share/man/man3/sio*.3.gz
%doc /usr/sgug/share/man/man7/sndio.7.gz
%doc /usr/sgug/share/man/man8/sndiod.8.gz


# No devel package, this thing's like two megabytes and I'm lazy, you get all of it

%changelog
* Wed Sep 7 2022 Jenna16bit jenna16bit@github
Add initial version by TruHobbyist, modified slightly for the SGUG compiler environment by Jenna16bit