several fixes for libjpeg related issues:
1. enable usage of libjpeg when libjpeg_turbo is not available; 2. remove forward declaration of some jpeg types since libjpeg and libjpeg_turbo have them defined differently; 3. pull in libjpeg code; Review URL: http://webrtc-codereview.appspot.com/80003 git-svn-id: http://webrtc.googlecode.com/svn/trunk@230 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
parent
0c52e935e2
commit
dd8076044a
3
DEPS
3
DEPS
@ -30,6 +30,9 @@ deps = {
|
||||
"trunk/third_party/libjpeg_turbo/":
|
||||
Var("chromium_trunk") + "/deps/third_party/libjpeg_turbo@78340",
|
||||
|
||||
"trunk/third_party/libjpeg/":
|
||||
Var("chromium_trunk") + "/src/third_party/libjpeg@" + Var("chromium_revision"),
|
||||
|
||||
"trunk/third_party/yasm/":
|
||||
Var("chromium_trunk") + "/src/third_party/yasm@" + Var("chromium_revision"),
|
||||
|
||||
|
@ -14,16 +14,6 @@
|
||||
|
||||
#include "data_manager.h"
|
||||
|
||||
#ifdef ANDROID
|
||||
extern "C" {
|
||||
#endif
|
||||
#include "jpeglib.h"
|
||||
#ifdef ANDROID
|
||||
}
|
||||
#endif
|
||||
#include "jmorecfg.h"
|
||||
|
||||
|
||||
namespace webrtc
|
||||
{
|
||||
|
||||
|
@ -16,13 +16,9 @@
|
||||
#define WEBRTC_COMMON_VIDEO_JPEG_DATA_MANAGER
|
||||
|
||||
#include <stdio.h>
|
||||
|
||||
// jpeg forward declaration
|
||||
struct jpeg_source_mgr;
|
||||
typedef unsigned char JOCTET;
|
||||
typedef int boolean;
|
||||
typedef struct jpeg_decompress_struct* j_decompress_ptr;
|
||||
typedef struct jpeg_compress_struct* j_compress_ptr;
|
||||
extern "C" {
|
||||
#include "jpeglib.h"
|
||||
}
|
||||
|
||||
namespace webrtc
|
||||
{
|
||||
|
@ -22,13 +22,9 @@
|
||||
#if defined(WIN32)
|
||||
#include <basetsd.h>
|
||||
#endif
|
||||
#ifdef ANDROID
|
||||
extern "C" {
|
||||
#endif
|
||||
#include "jpeglib.h"
|
||||
#ifdef ANDROID
|
||||
}
|
||||
#endif
|
||||
#include <setjmp.h>
|
||||
|
||||
|
||||
|
@ -10,6 +10,9 @@
|
||||
'includes': [
|
||||
'../../../../common_settings.gypi', # Common settings
|
||||
],
|
||||
'variables': {
|
||||
'use_libjpeg_turbo%': '<(use_libjpeg_turbo)',
|
||||
},
|
||||
'targets': [
|
||||
{
|
||||
'target_name': 'webrtc_jpeg',
|
||||
@ -31,28 +34,20 @@
|
||||
'conditions': [
|
||||
['build_with_chromium==1', {
|
||||
'dependencies': [
|
||||
'../../../../../libjpeg_turbo/libjpeg.gyp:libjpeg',
|
||||
'<(libjpeg_gyp_path):libjpeg',
|
||||
],
|
||||
'include_dirs': [
|
||||
'../../../../../libjpeg_turbo',
|
||||
}, {
|
||||
'conditions': [
|
||||
['use_libjpeg_turbo==1', {
|
||||
'dependencies': [
|
||||
'../../../../../third_party/libjpeg_turbo/libjpeg.gyp:libjpeg',
|
||||
],
|
||||
}, {
|
||||
'dependencies': [
|
||||
'../../../../../third_party/libjpeg/libjpeg.gyp:libjpeg',
|
||||
],
|
||||
}],
|
||||
],
|
||||
'direct_dependent_settings': {
|
||||
'include_dirs': [
|
||||
'../../../../../libjpeg_turbo',
|
||||
],
|
||||
},
|
||||
},{
|
||||
'dependencies': [
|
||||
'../../../../../third_party/libjpeg_turbo/libjpeg.gyp:libjpeg',
|
||||
],
|
||||
'include_dirs': [
|
||||
'../../../../third_party/libjpeg_turbo',
|
||||
],
|
||||
'direct_dependent_settings': {
|
||||
'include_dirs': [
|
||||
'../../../../third_party/libjpeg_turbo',
|
||||
],
|
||||
},
|
||||
}],
|
||||
],
|
||||
'sources': [
|
||||
|
Loading…
x
Reference in New Issue
Block a user