Fix the problem of linking taglib2 on 32 bit architectures

if taglib is not built with large files support.

Signed-off-by: Slávek Banko <slavek.banko@axis.cz>
pull/29/head
Slávek Banko 4 weeks ago
parent 906eb9cec6
commit bee4995859
No known key found for this signature in database
GPG Key ID: 608F5293A04BE668

@ -42,6 +42,29 @@ else( )
tde_message_fatal( "taglib is required, but not found on your system" )
endif( )
tde_save_and_set( CMAKE_REQUIRED_DEFINITIONS "${LARGEFILES_DEFINITIONS}" )
tde_save_and_set( CMAKE_REQUIRED_INCLUDES "${TAGLIB_INCLUDE_DIRS}" )
tde_save_and_set( CMAKE_REQUIRED_LIBRARIES "${TAGLIB_LIBRARIES}" )
check_cxx_source_compiles( "
#include <taglib.h>
#include <id3v1tag.h>
int main( int, char** )
{
off_t tagOffset = 0;
TagLib::File *testFile = nullptr;
TagLib::ID3v1::Tag *id3tag = new TagLib::ID3v1::Tag(testFile, tagOffset);
return 0;
}
"
TAGLIB_LARGE_FILES_SUPPORT
)
tde_restore( CMAKE_REQUIRED_DEFINITIONS )
tde_restore( CMAKE_REQUIRED_INCLUDES )
tde_restore( CMAKE_REQUIRED_LIBRARIES )
##### check for cdda interface and paranoia

@ -10,3 +10,6 @@
// Define if you have int and long types
#cmakedefine SIZEOF_INT @SIZEOF_INT@
#cmakedefine SIZEOF_LONG @SIZEOF_LONG@
// Define if taglib can be built with large files support
#cmakedefine TAGLIB_LARGE_FILES_SUPPORT 1

@ -19,6 +19,14 @@
* USA *
***************************************************************************/
#include "config.h"
#if !defined(TAGLIB_LARGE_FILES_SUPPORT)
#undef _LARGE_FILES
#undef _LARGEFILE_SOURCE
#undef _FILE_OFFSET_BITS
#endif
#include <tbytevectorlist.h>
#include <tstring.h>
#include "asffile.h"

@ -12,6 +12,10 @@ link_directories(
${TDE_LIB_DIR}
)
if( NOT TAGLIB_LARGE_FILES_SUPPORT )
add_definitions( -U_LARGE_FILES -U_LARGEFILE_SOURCE -U_FILE_OFFSET_BITS )
endif()
##### pluginloader

@ -26,6 +26,15 @@
* https://common.helixcommunity.org/nonav/2003/HCS_SDK_r5/helixsdk.htm *
* *
***************************************************************************/
#include "config.h"
#if !defined(TAGLIB_LARGE_FILES_SUPPORT)
#undef _LARGE_FILES
#undef _LARGEFILE_SOURCE
#undef _FILE_OFFSET_BITS
#endif
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>

@ -23,6 +23,14 @@
* MA 02110-1301 USA *
***************************************************************************/
#include "config.h"
#if !defined(TAGLIB_LARGE_FILES_SUPPORT)
#undef _LARGE_FILES
#undef _LARGEFILE_SOURCE
#undef _FILE_OFFSET_BITS
#endif
#include <tbytevector.h>
#include <tstring.h>
#if 0

@ -23,6 +23,14 @@
* MA 02110-1301 USA *
***************************************************************************/
#include "config.h"
#if !defined(TAGLIB_LARGE_FILES_SUPPORT)
#undef _LARGE_FILES
#undef _LARGEFILE_SOURCE
#undef _FILE_OFFSET_BITS
#endif
#include <tbytevector.h>
#include <tstring.h>
#if 0

Loading…
Cancel
Save