You are not logged in.
Hello, I am trying to cross-compile the in_adlib.dll for winamp/xmplay in Arch with mingw, from the latest git release.
The packages build properly but I only see in_adlib.a but no in_adlib.dll in the library folder.
Here are the package builds I created. I'm sure they can be improved since I am new to cross-compiling in Linux.
Adplug winamp depens on adplug, which in turn depends on libbinio.
I am also testing only with i686 because Winamp is 32-bit only.
Libbinio
pkgname=mingw-w64-libbinio
_pkgname=libbinio
pkgver=1.4
pkgrel=1
pkgdesc="Binary I/O C++ class library"
url="https://github.com/adplug/libbinio"
arch=('any')
license=('GPL')
depends=('mingw-w64-gcc')
options=('!buildflags' '!strip' 'staticlibs')
source=("git://github.com/adplug/libbinio.git")
md5sums=('SKIP')
_architectures="i686-w64-mingw32"
prepare() {
cd "${srcdir}/${_pkgname}"
autoreconf -fiv
aclocal
automake
}
build() {
cd "${srcdir}/${_pkgname}"
for _arch in ${_architectures}; do
mkdir -p build-${_arch} && pushd build-${_arch}
${_arch}-configure \
--prefix=/usr/${_arch} \
--infodir=/usr/${_arch}/share/info \
--enable-maintainer-mode \
..
make
popd
done
}
package() {
for _arch in ${_architectures}; do
cd "${srcdir}/${_pkgname}/build-${_arch}"
make DESTDIR="${pkgdir}" install
# ${_arch}-strip --strip-unneeded "$pkgdir"/usr/${_arch}/bin/*.dll
${_arch}-strip -g "$pkgdir"/usr/${_arch}/lib/*.a
rm "$pkgdir/usr/${_arch}/share/info/dir"
done
}
Adplug
pkgname=mingw-w64-adplug
_pkgname=adplug
pkgver=20190602
pkgrel=1
pkgdesc="AdLib sound player library"
url="http://adplug.github.io"
arch=('any')
license=('LGPL')
depends=('mingw-w64-libbinio')
provides=('mingw-w64-adplug')
conflicts=('mingw-w64-adplug')
options=('!buildflags' '!strip' 'staticlibs')
source=("git://github.com/adplug/adplug.git")
md5sums=('SKIP')
_architectures="i686-w64-mingw32"
prepare() {
cd "${srcdir}/${_pkgname}"
autoreconf -fiv
aclocal
automake
}
build() {
cd "${srcdir}/${_pkgname}"
for _arch in ${_architectures}; do
mkdir -p build-${_arch} && pushd build-${_arch}
${_arch}-configure \
--prefix=/usr/${_arch} \
--enable-maintainer-mode \
..
make
popd
done
}
package() {
for _arch in ${_architectures}; do
cd "${srcdir}/${_pkgname}/build-${_arch}"
make DESTDIR="${pkgdir}" install
# ${_arch}-strip --strip-unneeded "$pkgdir"/usr/${_arch}/bin/*.dll
${_arch}-strip --strip-unneeded "$pkgdir"/usr/${_arch}/bin/*.exe
${_arch}-strip -g "$pkgdir"/usr/${_arch}/lib/*.a
rm "$pkgdir/usr/${_arch}/share/info/dir"
done
}
Adplug-Winamp
pkgname=mingw-w64-adplugwinamp
_pkgname=winamp
pkgver=20190602
pkgrel=1
pkgdesc="AdPlug plugin for Winamp"
url="http://adplug.github.io"
arch=('any')
license=('LGPL')
depends=('mingw-w64-adplug')
provides=('mingw-w64-adplugwinamp')
conflicts=('mingw-w64-adplugwinamp')
options=('!buildflags' '!strip' 'staticlibs')
source=("git://github.com/adplug/winamp.git")
md5sums=('SKIP')
_architectures="i686-w64-mingw32"
prepare() {
cd "${srcdir}/${_pkgname}"
autoreconf -fiv
aclocal
automake
# Replace max(1 with max((long) 1
sed -i 's/max(1/max((long) 1/g' "${srcdir}/${_pkgname}/src/callback.cpp"
}
build() {
cd "${srcdir}/${_pkgname}"
for _arch in ${_architectures}; do
mkdir -p build-${_arch} && pushd build-${_arch}
${_arch}-configure \
--prefix=/usr/${_arch} \
--enable-maintainer-mode \
..
make
popd
done
}
package() {
for _arch in ${_architectures}; do
cd "${srcdir}/${_pkgname}/build-${_arch}"
make DESTDIR="${pkgdir}" install
# ${_arch}-strip --strip-unneeded "$pkgdir"/usr/${_arch}/bin/*.dll
${_arch}-strip -g "$pkgdir"/usr/${_arch}/lib/*.a
# rm "$pkgdir/usr/${_arch}/share/info/dir"
done
}
EDIT: I meant xmplay not xmms
Last edited by Yoyo2k (2019-06-08 00:23:38)
Offline
I managed to get a working compile of in_adlib.dll.
But I also had to place libadplug-2-3-2-beta-0.dll, libgcc_s_sjlj-1.dll, and libstdc++-6.dll from the mingw i686 bin folder into my xmplay plugins folder.
Libbinio
pkgname=mingw-w64-libbinio-git
_pkgname=libbinio
pkgver=20190607
pkgrel=1
pkgdesc="Binary I/O C++ class library"
url="http://adplug.github.io/libbinio"
arch=('any')
license=('GPL')
depends=('mingw-w64-gcc')
provides=('mingw-w64-libbinio')
conflicts=('mingw-w64-libbinio')
options=('!buildflags' '!strip' 'staticlibs')
source=("git://github.com/adplug/libbinio.git")
md5sums=('SKIP')
_architectures="i686-w64-mingw32 x86_64-w64-mingw32"
prepare() {
cd "${srcdir}/${_pkgname}"
autoreconf -fiv
aclocal
automake
sed -i 's/allow_undefined=yes/allow_undefined=no/g' "${srcdir}/${_pkgname}/ltmain.sh"
}
build() {
cd "${srcdir}/${_pkgname}"
for _arch in ${_architectures}; do
mkdir -p build-${_arch} && pushd build-${_arch}
${_arch}-configure \
--prefix=/usr/${_arch} \
--infodir=/usr/${_arch}/share/info \
--enable-maintainer-mode \
--enable-shared=yes \
--enable-static=no \
..
make
popd
done
}
package() {
for _arch in ${_architectures}; do
cd "${srcdir}/${_pkgname}/build-${_arch}"
make DESTDIR="${pkgdir}" install
${_arch}-strip --strip-unneeded "$pkgdir"/usr/${_arch}/bin/*.dll
${_arch}-strip -g "$pkgdir"/usr/${_arch}/lib/*.a
rm "$pkgdir/usr/${_arch}/share/info/dir"
done
}
Adplug
pkgname=mingw-w64-adplug-git
_pkgname=adplug
pkgver=20190607
pkgrel=1
pkgdesc="AdLib sound player library"
url="http://adplug.github.io"
arch=('any')
license=('LGPL')
depends=('mingw-w64-libbinio')
provides=('mingw-w64-adplug')
conflicts=('mingw-w64-adplug')
options=('!buildflags' '!strip' 'staticlibs')
source=("git://github.com/adplug/adplug.git")
md5sums=('SKIP')
_architectures="i686-w64-mingw32 x86_64-w64-mingw32"
prepare() {
cd "${srcdir}/${_pkgname}"
autoreconf -fiv
aclocal
automake
sed -i 's/allow_undefined=yes/allow_undefined=no/g' "${srcdir}/${_pkgname}/ltmain.sh"
}
build() {
cd "${srcdir}/${_pkgname}"
for _arch in ${_architectures}; do
mkdir -p build-${_arch} && pushd build-${_arch}
${_arch}-configure \
--prefix=/usr/${_arch} \
--enable-maintainer-mode \
--enable-shared=yes \
--enable-static=no \
..
make
popd
done
}
package() {
for _arch in ${_architectures}; do
cd "${srcdir}/${_pkgname}/build-${_arch}"
make DESTDIR="${pkgdir}" install
${_arch}-strip --strip-unneeded "$pkgdir"/usr/${_arch}/bin/*.dll
${_arch}-strip --strip-unneeded "$pkgdir"/usr/${_arch}/bin/*.exe
${_arch}-strip -g "$pkgdir"/usr/${_arch}/lib/*.a
rm "$pkgdir/usr/${_arch}/share/info/dir"
done
}
Adplug-Winamp
pkgname=mingw-w64-adplugwinamp-git
_pkgname=winamp
pkgver=20190607
pkgrel=1
pkgdesc="AdPlug plugin for Winamp"
url="http://adplug.github.io"
arch=('any')
license=('LGPL')
depends=('mingw-w64-adplug')
provides=('mingw-w64-adplugwinamp')
conflicts=('mingw-w64-adplugwinamp')
options=('!buildflags' '!strip' 'staticlibs')
source=("git://github.com/adplug/winamp.git")
md5sums=('SKIP')
prepare() {
cd "${srcdir}/${_pkgname}"
autoreconf -fiv
aclocal
automake
sed -i 's/allow_undefined=yes/allow_undefined=no/g' "${srcdir}/${_pkgname}/ltmain.sh"
# Replace max(1 with max((long) 1
sed -i 's/max(1/max((long) 1/g' "${srcdir}/${_pkgname}/src/callback.cpp"
}
build() {
cd "${srcdir}/${_pkgname}"
mkdir -p build-i686-w64-mingw32 && pushd build-i686-w64-mingw32
i686-w64-mingw32-configure \
--prefix=/usr/i686-w64-mingw32 \
--enable-maintainer-mode \
--enable-shared=yes \
--enable-static=no \
..
# Only way I could figure out how to add lshlwapi
sed -i 's/-lkernel32/-lkernel32 -lshlwapi/g' "${srcdir}/${_pkgname}/build-i686-w64-mingw32/libtool"
make
popd
}
package() {
cd "${srcdir}/${_pkgname}/build-i686-w64-mingw32"
make DESTDIR="${pkgdir}" install
i686-w64-mingw32-strip --strip-unneeded "$pkgdir"/usr/i686-w64-mingw32/lib/*.dll
i686-w64-mingw32-strip -g "$pkgdir"/usr/i686-w64-mingw32/lib/*.a
}
Offline