mirror of
https://github.com/void-linux/void-packages.git
synced 2025-07-30 17:33:03 +02:00
id3ted: fix build with taglib2
This commit is contained in:
parent
aad3920aaa
commit
e1cf9fbf20
2 changed files with 48 additions and 1 deletions
47
srcpkgs/id3ted/patches/id3ted-1.0-fix-build-taglib2.patch
Normal file
47
srcpkgs/id3ted/patches/id3ted-1.0-fix-build-taglib2.patch
Normal file
|
@ -0,0 +1,47 @@
|
|||
no upstream PR as repo is archive
|
||||
--- a/fileio.cpp
|
||||
+++ b/fileio.cpp
|
||||
@@ -60,11 +60,11 @@ bool FileIO::isRegular(const char *path) {
|
||||
|
||||
|
||||
bool FileIO::isReadable(const char *path) {
|
||||
- return TagLib::File::isReadable(path);
|
||||
+ return !access(path, R_OK);
|
||||
}
|
||||
|
||||
bool FileIO::isWritable(const char *path) {
|
||||
- return TagLib::File::isWritable(path);
|
||||
+ return !access(path, W_OK);
|
||||
}
|
||||
|
||||
string FileIO::sizeHumanReadable(unsigned long size) {
|
||||
--- a/id3ted.h
|
||||
+++ b/id3ted.h
|
||||
@@ -30,7 +30,6 @@
|
||||
|
||||
using namespace std;
|
||||
using namespace TagLib;
|
||||
-using TagLib::uint;
|
||||
|
||||
void warn(const char* fmt, ...);
|
||||
|
||||
--- a/mp3file.cpp
|
||||
+++ b/mp3file.cpp
|
||||
@@ -343,7 +343,7 @@ bool MP3File::save() {
|
||||
if (tags & 2 && id3v2Tag != NULL && id3v2Tag->isEmpty())
|
||||
strip(2);
|
||||
|
||||
- return file.save(tags, false);
|
||||
+ return file.save();
|
||||
}
|
||||
|
||||
bool MP3File::strip(int tags) {
|
||||
@@ -391,7 +391,7 @@ void MP3File::showInfo() const {
|
||||
break;
|
||||
}
|
||||
|
||||
- int length = properties->length();
|
||||
+ int length = properties->lengthInSeconds();
|
||||
printf("MPEG %s Layer %d %s\n", version, properties->layer(), channelMode);
|
||||
printf("bitrate: %d kBit/s, sample rate: %d Hz, length: %02d:%02d:%02d\n",
|
||||
properties->bitrate(), properties->sampleRate(),
|
|
@ -1,7 +1,7 @@
|
|||
# Template file for 'id3ted'
|
||||
pkgname=id3ted
|
||||
version=1.0
|
||||
revision=2
|
||||
revision=3
|
||||
build_style=gnu-makefile
|
||||
makedepends="file-devel taglib-devel"
|
||||
short_desc="Command line id3 tag editor"
|
||||
|
|
Loading…
Add table
Reference in a new issue