libmm-log dependency remove 74/42174/4 submit/tizen/20150703.020912
authorji.yong.seo <ji.yong.seo@samsung.com>
Wed, 24 Jun 2015 06:13:56 +0000 (15:13 +0900)
committerji.yong.seo <ji.yong.seo@samsung.com>
Wed, 24 Jun 2015 08:04:48 +0000 (17:04 +0900)
Signed-off-by: ji.yong.seo <ji.yong.seo@samsung.com>
Change-Id: I66bce9afc1ce53bfd1a57c1cba6f8a138db252ea

35 files changed:
codecs/ffmpeg/Makefile.am
codecs/ffmpeg/mm_file_codec_dummy.c
codecs/ffmpeg/mm_file_codecs.c
configure.ac
formats/ffmpeg/Makefile.am
formats/ffmpeg/mm_file_format_aac.c
formats/ffmpeg/mm_file_format_amr.c
formats/ffmpeg/mm_file_format_dummy.c
formats/ffmpeg/mm_file_format_ffmpeg.c
formats/ffmpeg/mm_file_format_ffmpeg_mem.c
formats/ffmpeg/mm_file_format_frame.c
formats/ffmpeg/mm_file_format_imelody.c
formats/ffmpeg/mm_file_format_midi.c
formats/ffmpeg/mm_file_format_mmf.c
formats/ffmpeg/mm_file_format_mp3.c
formats/ffmpeg/mm_file_format_tag_id3.c
formats/ffmpeg/mm_file_format_tags.c
formats/ffmpeg/mm_file_format_wav.c
formats/ffmpeg/mm_file_formats.c
include/mm_file_debug.h [new file with mode: 0755]
mm-fileinfo.pc.in [changed mode: 0644->0755]
mm_file.c
packaging/libmm-fileinfo.spec
utils/Makefile.am
utils/mm_file_util_io.c
utils/mm_file_util_io_file.c
utils/mm_file_util_io_mem.c
utils/mm_file_util_io_mmap.c
utils/mm_file_util_list.c
utils/mm_file_util_locale.c
utils/mm_file_util_mime.c
utils/mm_file_util_print.c
utils/mm_file_util_string.c
utils/mm_file_util_tag.c
utils/mm_file_util_validity.c

index 8fbbb10..97c4433 100755 (executable)
@@ -18,7 +18,7 @@ libmmfile_codecs_la_CFLAGS = -I$(srcdir)/include \
                         -D_FILE_OFFSET_BITS=64
 
 libmmfile_codecs_la_LIBADD = $(MMCOMMON_LIBS)  \
-                            $(top_builddir)/utils/libmmfile_utils.la 
+                            $(top_builddir)/utils/libmmfile_utils.la
 
-libmmfile_codecs_la_CFLAGS += $(MMLOG_CFLAGS) -DMMF_LOG_OWNER=0x040 -DMMF_DEBUG_PREFIX=\"MMF-FILE-CODEC-FFMPEG\"
-libmmfile_codecs_la_LIBADD += $(MMLOG_LIBS)
+libmmfile_codecs_la_CFLAGS += $(DLOG_CFLAGS)
+libmmfile_codecs_la_LIBADD += $(DLOG_LIBS)
index 989084d..a6469cf 100755 (executable)
@@ -24,7 +24,7 @@
 
 #include <mm_error.h>
 
-#include "mm_debug.h"
+#include "mm_file_debug.h"
 
 #include "mm_file_codec_private.h"
 #include "mm_file_codec_dummy.h"
index dc9cc89..ddd828a 100755 (executable)
@@ -22,7 +22,7 @@
 #include <string.h>
 #include <stdlib.h>
 
-#include "mm_debug.h"
+#include "mm_file_debug.h"
 #include "mm_file_utils.h"
 #include "mm_file_codec_private.h"
 
index 0109c79..9c192e6 100755 (executable)
@@ -55,11 +55,9 @@ AC_SUBST(MMCOMMON_LIBS)
 #AC_SUBST(MMMHAL_CFLAGS)
 #AC_SUBST(MMMHAL_LIBS)
 
-PKG_CHECK_MODULES(MMLOG,mm-log)
-AC_SUBST(MMLOG_CFLAGS)
-AC_SUBST(MMLOG_LIBS)
-
-
+PKG_CHECK_MODULES(DLOG,dlog)
+AC_SUBST(DLOG_CFLAGS)
+AC_SUBST(DLOG_LIBS)
 
 PKG_CHECK_MODULES(GLIB, glib-2.0)
 AC_SUBST(GLIB_CFLAGS)
index 380277c..b921cb5 100755 (executable)
@@ -69,8 +69,8 @@ if USE_DRM
 libmmfile_formats_la_LIBADD += $(DRMCLIENT_LIBS) $(DRMTRUSTTED_LIBS)
 endif
 
-libmmfile_formats_la_CFLAGS += $(MMLOG_CFLAGS) -DMMF_LOG_OWNER=0x040 -DMMF_DEBUG_PREFIX=\"MMF-FILE-FORMAT-FFMPEG\"
-libmmfile_formats_la_LIBADD += $(MMLOG_LIBS)
+libmmfile_formats_la_CFLAGS += $(DLOG_CFLAGS)
+libmmfile_formats_la_LIBADD += $(DLOG_LIBS)
 
 libmmfile_formats_la_CFLAGS += -D__MMFILE_FFMPEG_V100__
 libmmfile_formats_la_CFLAGS += -D__MMFILE_FFMPEG_V085__
index 095efff..d337aac 100755 (executable)
  *
  */
 
-#include <stdio.h> 
+#include <stdio.h>
 #include <string.h>    /*memcmp*/
 #include <stdlib.h>    /*malloc*/
 
 #include <mm_error.h>
 
-#include "mm_debug.h"
+#include "mm_file_debug.h"
 #include "mm_file_utils.h"
 #include "mm_file_format_private.h"
 #include "mm_file_format_aac.h"
@@ -33,7 +33,7 @@
 
 // Internal Error Type
 #define MMFILE_AAC_PARSER_FILE_END 2
-  
+
 // Media specific definations
 #define MMFILE_AAC_ADIF_HEADER_MAX_SIZE 30
 #define MMFILE_AAC_ADTS_HEADER_MAX_SIZE 7
index d15cf62..2a7f473 100755 (executable)
  *
  */
 
-#include <stdio.h>  
+#include <stdio.h>
 #include <string.h>    /*memcmp*/
 #include <stdlib.h>    /*malloc*/
 
 
 #include <mm_error.h>
-#include "mm_debug.h"
+#include "mm_file_debug.h"
 
 #include "mm_file_utils.h"
 #include "mm_file_format_private.h"
index b8f7a19..1e567e0 100755 (executable)
@@ -24,7 +24,7 @@
 
 #include <mm_error.h>
 
-#include "mm_debug.h"
+#include "mm_file_debug.h"
 
 #include "mm_file_format_private.h"
 #include "mm_file_format_dummy.h"
index a79e25a..75ad103 100755 (executable)
@@ -35,7 +35,7 @@
 #include <drm_client.h>
 #endif
 
-#include "mm_debug.h"
+#include "mm_file_debug.h"
 #include "mm_file_formats.h"
 #include "mm_file_utils.h"
 #include "mm_file_format_ffmpeg.h"
index 4014126..0fbe8a3 100755 (executable)
  * limitations under the License.
  *
  */
+
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
 
 #include <libavformat/avformat.h>
 #include <libavformat/avio.h>
-#include "mm_debug.h"
+#include "mm_file_debug.h"
 #include "mm_file_utils.h"
 #include "mm_file_format_ffmpeg_mem.h"
 
index a976c3d..3a2b6af 100755 (executable)
@@ -24,7 +24,7 @@
 #include <libswscale/swscale.h>
 
 #include <mm_types.h>
-#include "mm_debug.h"
+#include "mm_file_debug.h"
 #include "mm_file_formats.h"
 #include "mm_file_utils.h"
 #include "mm_file_format_ffmpeg_mem.h"
index c78aa4a..239e6b5 100755 (executable)
@@ -23,7 +23,7 @@
 #include <string.h>    /*memcmp*/
 #include <stdlib.h>    /*malloc*/
 
-#include "mm_debug.h"
+#include "mm_file_debug.h"
 #include "mm_file_utils.h"
 #include "mm_file_format_private.h"
 #include "mm_file_format_imelody.h"
index 8c6d345..1443422 100755 (executable)
  * limitations under the License.
  *
  */
+
 #include <string.h>    /*memcmp*/
 #include <stdio.h>
 #include <stdlib.h>    /*malloc*/
 #include <mm_error.h>
 
-#include "mm_debug.h"
+#include "mm_file_debug.h"
 #include "mm_file_utils.h"
 #include "mm_file_format_private.h"
 #include "mm_file_format_midi.h"
index ab15333..62017a1 100755 (executable)
@@ -22,7 +22,7 @@
 #include <string.h>    /*memcmp*/
 #include <stdlib.h>    /*malloc*/
 
-#include "mm_debug.h"
+#include "mm_file_debug.h"
 
 #include "mm_file_utils.h"
 #include "mm_file_format_mmf.h"
index b3c65d3..94be471 100755 (executable)
@@ -27,7 +27,7 @@
 
 #include <stdlib.h>    /*malloc*/
 
-#include "mm_debug.h"
+#include "mm_file_debug.h"
 #include "mm_file_utils.h"
 #include "mm_file_format_private.h"
 #include "mm_file_format_audio.h"
index 9a96ca7..a575563 100755 (executable)
@@ -21,7 +21,7 @@
 
 #include <string.h>
 #include <stdlib.h>
-#include "mm_debug.h"
+#include "mm_file_debug.h"
 #include "mm_file_format_tag_id3.h"
 
 #define MMFILE_ID3V1TAG_SIZE 128
index f1c2bf2..73b0009 100755 (executable)
@@ -21,7 +21,7 @@
 
 #include <string.h>
 #include <stdlib.h>
-#include "mm_debug.h"
+#include "mm_file_debug.h"
 #include "mm_file_utils.h"
 #include "mm_file_format_tag_id3.h"
 #include "mm_file_format_tags.h"
index 0e045c6..b9d26fb 100755 (executable)
@@ -23,7 +23,7 @@
 #include <stdlib.h>    /*malloc*/
 
 #include <mm_error.h>
-#include "mm_debug.h"
+#include "mm_file_debug.h"
 
 #include "mm_file_utils.h"
 #include "mm_file_format_private.h"
index 556c057..a53dffd 100755 (executable)
@@ -28,7 +28,7 @@
 #endif
 
 
-#include "mm_debug.h"
+#include "mm_file_debug.h"
 #include "mm_file_format_private.h"
 #include "mm_file_utils.h"
 
diff --git a/include/mm_file_debug.h b/include/mm_file_debug.h
new file mode 100755 (executable)
index 0000000..bc5dc2b
--- /dev/null
@@ -0,0 +1,106 @@
+/*
+ * libmm-fileinfo
+ *
+ * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * Contact: Haejeong Kim <backto.kim@samsung.com>
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ */
+
+#ifndef _MMFILE_DEBUG_H_
+#define _MMFILE_DEBUG_H_
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#include <dlog.h>
+
+#ifdef LOG_TAG
+#undef LOG_TAG
+#endif
+
+#define LOG_TAG "MM_FILEINFO"
+
+/*#define LOG_COLOR */
+
+#ifdef LOG_COLOR
+#define FONT_COLOR_RESET    "\033[0m"
+#define FONT_COLOR_RED      "\033[31m"
+#define FONT_COLOR_GREEN    "\033[32m"
+#define FONT_COLOR_YELLOW   "\033[33m"
+#define FONT_COLOR_BLUE     "\033[34m"
+#define FONT_COLOR_PURPLE   "\033[35m"
+#define FONT_COLOR_CYAN     "\033[36m"
+#define FONT_COLOR_GRAY     "\033[37m"
+
+#define debug_log(fmt, arg...) do { \
+                       LOGD(FONT_COLOR_RESET fmt, ##arg); \
+               } while (0)
+
+#define debug_msg(fmt, arg...) do { \
+                       LOGD(FONT_COLOR_RESET fmt, ##arg); \
+               } while (0)
+
+#define debug_warning(fmt, arg...) do { \
+                       LOGW(FONT_COLOR_GREEN fmt, ##arg); \
+               } while (0)
+
+#define debug_error(fmt, arg...) do { \
+                       LOGE(FONT_COLOR_RED fmt, ##arg); \
+               } while (0)
+
+#define debug_fenter() do { \
+                       LOGE(FONT_COLOR_RESET "<ENTER> \n");     \
+               } while (0)
+
+#define debug_fleave() do { \
+                       LOGE(FONT_COLOR_RESET "<LEAVE> \n");     \
+               } while (0)
+
+#else
+
+#define debug_log(fmt, arg...) do { \
+                       LOGD(" "fmt"", ##arg);     \
+               } while (0)
+
+#define debug_msg(fmt, arg...) do { \
+                       LOGD(" "fmt"", ##arg);     \
+               } while (0)
+
+#define debug_warning(fmt, arg...) do { \
+                       LOGW(" "fmt"", ##arg);     \
+               } while (0)
+
+#define debug_error(fmt, arg...) do { \
+                       LOGE(" "fmt"", ##arg);     \
+               } while (0)
+
+#define debug_fenter() do { \
+                       LOGE("<ENTER> \n");     \
+               } while (0)
+
+#define debug_fleave() do { \
+                       LOGE("<LEAVE> \n");     \
+               } while (0)
+#endif
+
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* _MMFILE_DEBUG_H_ */
+
old mode 100644 (file)
new mode 100755 (executable)
index d39e454..e534571
@@ -5,7 +5,7 @@ includedir = @includedir@
 
 Name : mm-fileinfo
 Description : Multimedia Framework FileInfo Library
-Requires : mm-log mm-common glib-2.0
+Requires : dlog mm-common glib-2.0
 Version : @VERSION@
 Libs : -L${libdir} -lmmffile -lmmfile_utils
-Cflags : -I${includedir}/mmf -D__MMFILE_DYN_LOADING__ 
+Cflags : -I${includedir}/mmf -D__MMFILE_DYN_LOADING__
index e7484d6..ad38d0f 100755 (executable)
--- a/mm_file.c
+++ b/mm_file.c
@@ -32,9 +32,9 @@
 
 /* internal MM header files */
 #include <mm_attrs_private.h>
-#include <mm_debug.h>
 
 /* internal MM File headers */
+#include "mm_file_debug.h"
 #include "mm_file_formats.h"
 #include "mm_file_format_frame.h"
 #include "mm_file_codecs.h"
index 8b3810e..a75fca1 100755 (executable)
@@ -1,6 +1,6 @@
 Name:      libmm-fileinfo
 Summary:    Media Fileinfo
-Version:    0.6.31
+Version:    0.6.32
 Release:    0
 Group:      System/Libraries
 License:    Apache-2.0
@@ -10,7 +10,7 @@ Requires(post): /sbin/ldconfig
 Requires(postun): /sbin/ldconfig
 
 BuildRequires: pkgconfig(mm-common)
-BuildRequires: pkgconfig(mm-log)
+BuildRequires: pkgconfig(dlog)
 BuildRequires: pkgconfig(libswscale)
 BuildRequires: pkgconfig(glib-2.0)
 BuildRequires: pkgconfig(libavcodec)
index 43a6cb3..c423a0c 100755 (executable)
@@ -14,7 +14,7 @@ libmmfile_utils_la_SOURCES = mm_file_util_memory.c \
                           mm_file_util_locale.c \
                           mm_file_util_validity.c \
                           mm_file_util_tag.c
-                       
+
 libmmfile_utils_la_CFLAGS = -I$(srcdir)/include \
                       -I$(srcdir)/../include \
                       $(MMCOMMON_CFLAGS) \
@@ -24,17 +24,17 @@ libmmfile_utils_la_CFLAGS = -I$(srcdir)/include \
                       $(VCONF_CFLAGS)
 if USE_TESTMODE
 libmmfile_utils_la_CFLAGS += -D__MMFILE_TEST_MODE__
-endif  
+endif
 
 libmmfile_utils_la_LIBADD = $(MMCOMMON_LIBS) \
                            $(ICU_LIBS) \
                            $(VCONF_LIBS)
 
 if USE_DRM
-libmmfile_utils_la_SOURCES += mm_file_util_io_drm.c 
+libmmfile_utils_la_SOURCES += mm_file_util_io_drm.c
 libmmfile_utils_la_CFLAGS += $(DRMCLIENT_CFLAGS) $(DRMTRUSTED_CFLAGS) -DDRM_SUPPORT
 libmmfile_utils_la_LIBADD += $(DRMCLIENT_LIBS) $(DRMTRUSTED_LIBS)
 endif
 
-libmmfile_utils_la_CFLAGS += $(MMLOG_CFLAGS) -DMMF_LOG_OWNER=0x040 -DMMF_DEBUG_PREFIX=\"MMF-FILE-UTILS\"
-libmmfile_utils_la_LIBADD += $(MMLOG_LIBS)
+libmmfile_utils_la_CFLAGS += $(DLOG_CFLAGS)
+libmmfile_utils_la_LIBADD += $(DLOG_LIBS)
index f915b5a..f5f8b21 100755 (executable)
@@ -23,7 +23,7 @@
 #include <string.h>
 #include <stdlib.h>
 #include <ctype.h>
-#include "mm_debug.h"
+#include "mm_file_debug.h"
 #include "mm_file_utils.h"
 
 static unsigned char is_little_endian = 0;
index aca9ba1..091e569 100755 (executable)
@@ -27,7 +27,7 @@
 #include <string.h>
 #include <unistd.h>
 
-#include "mm_debug.h"
+#include "mm_file_debug.h"
 #include "mm_file_utils.h"
 
 typedef struct mmfileiodata
index f8f48d5..d65f071 100755 (executable)
  * limitations under the License.
  *
  */
+
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
 
-#include "mm_debug.h"
+#include "mm_file_debug.h"
 #include "mm_file_utils.h"
 
 
index cf4025e..4a59ef4 100755 (executable)
@@ -30,7 +30,7 @@
 #include <sys/stat.h>
 #include <fcntl.h>
 
-#include "mm_debug.h"
+#include "mm_file_debug.h"
 #include "mm_file_utils.h"
 
 
index 09ced62..6b00f23 100755 (executable)
  */
 
 #include <glib.h>
-#include <mm_debug.h>
+#include "mm_file_debug.h"
 #include "mm_file_utils.h"
 
-EXPORT_API 
+EXPORT_API
 MMFileList mmfile_list_alloc ()
 {
     return g_list_alloc ();
index a8bba4e..60cd630 100755 (executable)
@@ -18,8 +18,8 @@
  * limitations under the License.
  *
  */
-#include <stdlib.h> 
+
+#include <stdlib.h>
 #include <string.h>
 #include <vconf.h>
 
@@ -27,7 +27,7 @@
 #include <gconf/gconf-client.h>
 #endif
 
-#include "mm_debug.h"
+#include "mm_file_debug.h"
 #include "mm_file_utils.h"
 
 /* This macro is the same with global-gconf.h */
index 6e447e8..54ebd9d 100755 (executable)
 
 #include <stdlib.h>
 #include <string.h>
-#include "mm_debug.h"
+#include "mm_file_debug.h"
 #include "mm_file_utils.h"
 
 typedef struct _mmfileavmimetype
 {
-    char    mimetype[MMFILE_MIMETYPE_MAX_LEN];    
+    char    mimetype[MMFILE_MIMETYPE_MAX_LEN];
     char    ffmpegFormat[MMFILE_FILE_FMT_MAX_LEN];
     char    extension[MMFILE_FILE_EXT_MAX_LEN];
 } MMFileAVMimeType;
index 7aa888f..7e75587 100755 (executable)
@@ -19,7 +19,7 @@
  *
  */
 
-#include "mm_debug.h"
+#include "mm_file_debug.h"
 #include "mm_file_utils.h"
 
 EXPORT_API
index 41432f1..786ea97 100755 (executable)
  * limitations under the License.
  *
  */
-#include <stdlib.h> 
+
+#include <stdlib.h>
 #include <string.h>
 #include <glib.h>
 #include <unicode/ucsdet.h>
-#include "mm_debug.h"
+#include "mm_file_debug.h"
 #include "mm_file_utils.h"
 
 #ifdef __MMFILE_MEM_TRACE__
index d33475b..cce975c 100755 (executable)
@@ -25,7 +25,7 @@
 #include <ctype.h>
 #include <vconf.h>
 
-#include "mm_debug.h"
+#include "mm_file_debug.h"
 #include "mm_file_utils.h"
 
 #define ENABLE_ITUNES_META             //All itunes metadata extracted by ffmpeg. see mov_read_udta_string() but Some cover art not support.
index 6f48dbd..fb50357 100755 (executable)
@@ -22,7 +22,7 @@
 #include <string.h>    /*memcmp*/
 #include <stdlib.h>    /*malloc*/
 #include <mm_error.h>
-#include <mm_debug.h>
+#include "mm_file_debug.h"
 #include "mm_file_utils.h"
 
 /* Description of return value