mirror of
https://github.com/openbsd/ports.git
synced 2026-06-17 23:13:55 +02:00
Update adplay to 1.9.
This commit is contained in:
@@ -1,8 +1,7 @@
|
||||
COMMENT = console-based OPL2 audio player
|
||||
|
||||
V = 1.8.1
|
||||
V = 1.9
|
||||
DISTNAME = adplay-${V}
|
||||
REVISION = 2
|
||||
|
||||
CATEGORIES = audio
|
||||
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
SHA256 (adplay-1.8.1.tar.bz2) = 6za9anBmmAzltyqnEKeE37N6D/5t/FBqXu72x0he39U=
|
||||
SIZE (adplay-1.8.1.tar.bz2) = 323128
|
||||
SHA256 (adplay-1.9.tar.bz2) = lJsmGAkqOq5cJ4qY36MjETDvNaeRs6/KoOvkVEPOgsg=
|
||||
SIZE (adplay-1.9.tar.bz2) = 354805
|
||||
|
||||
@@ -3,50 +3,56 @@ Stop hardcoding -lstdc++.
|
||||
Index: configure
|
||||
--- configure.orig
|
||||
+++ configure
|
||||
@@ -17017,47 +17017,6 @@ ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAG
|
||||
@@ -20041,53 +20041,6 @@ ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAG
|
||||
ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
|
||||
|
||||
|
||||
-# Nothing works without these libraries...
|
||||
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lstdc++" >&5
|
||||
-$as_echo_n "checking for main in -lstdc++... " >&6; }
|
||||
-if ${ac_cv_lib_stdcpp_main+:} false; then :
|
||||
- $as_echo_n "(cached) " >&6
|
||||
-else
|
||||
- ac_check_lib_save_LIBS=$LIBS
|
||||
-{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for main in -lstdc++" >&5
|
||||
-printf %s "checking for main in -lstdc++... " >&6; }
|
||||
-if test ${ac_cv_lib_stdcpp_main+y}
|
||||
-then :
|
||||
- printf %s "(cached) " >&6
|
||||
-else case e in #(
|
||||
- e) ac_check_lib_save_LIBS=$LIBS
|
||||
-LIBS="-lstdc++ $LIBS"
|
||||
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
||||
-/* end confdefs.h. */
|
||||
-
|
||||
-
|
||||
-namespace conftest {
|
||||
- extern "C" int main ();
|
||||
-}
|
||||
-int
|
||||
-main ()
|
||||
-main (void)
|
||||
-{
|
||||
-return main ();
|
||||
-return conftest::main ();
|
||||
- ;
|
||||
- return 0;
|
||||
-}
|
||||
-_ACEOF
|
||||
-if ac_fn_cxx_try_link "$LINENO"; then :
|
||||
-if ac_fn_cxx_try_link "$LINENO"
|
||||
-then :
|
||||
- ac_cv_lib_stdcpp_main=yes
|
||||
-else
|
||||
- ac_cv_lib_stdcpp_main=no
|
||||
-else case e in #(
|
||||
- e) ac_cv_lib_stdcpp_main=no ;;
|
||||
-esac
|
||||
-fi
|
||||
-rm -f core conftest.err conftest.$ac_objext \
|
||||
-rm -f core conftest.err conftest.$ac_objext conftest.beam \
|
||||
- conftest$ac_exeext conftest.$ac_ext
|
||||
-LIBS=$ac_check_lib_save_LIBS
|
||||
-LIBS=$ac_check_lib_save_LIBS ;;
|
||||
-esac
|
||||
-fi
|
||||
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_stdcpp_main" >&5
|
||||
-$as_echo "$ac_cv_lib_stdcpp_main" >&6; }
|
||||
-if test "x$ac_cv_lib_stdcpp_main" = xyes; then :
|
||||
- cat >>confdefs.h <<_ACEOF
|
||||
-#define HAVE_LIBSTDC__ 1
|
||||
-_ACEOF
|
||||
-{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_stdcpp_main" >&5
|
||||
-printf "%s\n" "$ac_cv_lib_stdcpp_main" >&6; }
|
||||
-if test "x$ac_cv_lib_stdcpp_main" = xyes
|
||||
-then :
|
||||
- printf "%s\n" "#define HAVE_LIBSTDC__ 1" >>confdefs.h
|
||||
-
|
||||
- LIBS="-lstdc++ $LIBS"
|
||||
-
|
||||
-else
|
||||
- as_fn_error $? "libstdc++ not installed" "$LINENO" 5
|
||||
-else case e in #(
|
||||
- e) as_fn_error $? "libstdc++ not installed" "$LINENO" 5 ;;
|
||||
-esac
|
||||
-fi
|
||||
|
||||
|
||||
|
||||
@@ -1,23 +0,0 @@
|
||||
commit 95d47d7dcf65a4f0e7371f193c8d936b4e1adc77
|
||||
|
||||
Rename min/max macros to uppercase
|
||||
|
||||
Index: src/defines.h
|
||||
--- src/defines.h.orig
|
||||
+++ src/defines.h
|
||||
@@ -34,11 +34,11 @@
|
||||
#define MSG_NOTE 3
|
||||
#define MSG_DEBUG 4
|
||||
|
||||
-#ifndef min
|
||||
-# define min(a,b) (((a) < (b)) ? (a) : (b))
|
||||
+#ifndef MIN
|
||||
+# define MIN(a,b) (((a) < (b)) ? (a) : (b))
|
||||
#endif
|
||||
-#ifndef max
|
||||
-# define max(a,b) (((a) > (b)) ? (a) : (b))
|
||||
+#ifndef MAX
|
||||
+# define MAX(a,b) (((a) > (b)) ? (a) : (b))
|
||||
#endif
|
||||
|
||||
/***** Global functions *****/
|
||||
@@ -1,21 +0,0 @@
|
||||
commit 95d47d7dcf65a4f0e7371f193c8d936b4e1adc77
|
||||
|
||||
Rename min/max macros to uppercase
|
||||
|
||||
Index: src/output.cc
|
||||
--- src/output.cc.orig
|
||||
+++ src/output.cc
|
||||
@@ -70,11 +70,11 @@ void EmuPlayer::frame()
|
||||
minicnt += freq;
|
||||
playing = p->update();
|
||||
}
|
||||
- i = min(towrite, (long)(minicnt / p->getrefresh() + 4) & ~3);
|
||||
+ i = MIN(towrite, (long)(minicnt / p->getrefresh() + 4) & ~3);
|
||||
opl->update((short *)pos, i);
|
||||
pos += i * getsampsize(); towrite -= i;
|
||||
i = (long)(p->getrefresh() * i);
|
||||
- minicnt -= max(1, i);
|
||||
+ minicnt -= MAX(1, i);
|
||||
}
|
||||
|
||||
// call output driver
|
||||
@@ -1,16 +0,0 @@
|
||||
commit 95d47d7dcf65a4f0e7371f193c8d936b4e1adc77
|
||||
|
||||
Rename min/max macros to uppercase
|
||||
|
||||
Index: src/sdl.cc
|
||||
--- src/sdl.cc.orig
|
||||
+++ src/sdl.cc
|
||||
@@ -75,7 +75,7 @@ void SDLPlayer::callback(void *userdata, Uint8 *audiob
|
||||
minicnt += self->spec.freq;
|
||||
self->playing = self->p->update();
|
||||
}
|
||||
- i = min(towrite, (long)(minicnt / self->p->getrefresh() + 4) & ~3);
|
||||
+ i = MIN(towrite, (long)(minicnt / self->p->getrefresh() + 4) & ~3);
|
||||
self->opl->update((short *)pos, i);
|
||||
pos += i * self->getsampsize(); towrite -= i;
|
||||
minicnt -= (long)(self->p->getrefresh() * i);
|
||||
Reference in New Issue
Block a user