* commit 'af0d8ed819cf5eaf9b77bde80c0ef87a9d690d5d': Get rid of libqemu library.
This commit is contained in:
committed by
Android Git Automerger
commit
dc6e4e64de
@@ -7,7 +7,6 @@ $(call emugl-import,libOpenglSystemCommon libGLESv1_enc lib_renderControl_enc)
|
||||
LOCAL_CFLAGS += -DLOG_TAG=\"GLES_emulation\" -DGL_GLEXT_PROTOTYPES
|
||||
|
||||
LOCAL_SRC_FILES := gl.cpp
|
||||
LOCAL_STATIC_LIBRARIES += libqemu
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_SHARED_LIBRARIES)/egl
|
||||
|
||||
$(call emugl-end-module)
|
||||
@@ -44,7 +43,6 @@ $(call emugl-end-module)
|
||||
#
|
||||
# LOCAL_STATIC_LIBRARIES := \
|
||||
# libOpenglCodecCommon \
|
||||
# libqemu
|
||||
#
|
||||
# LOCAL_SHARED_LIBRARIES := \
|
||||
# libcutils \
|
||||
|
||||
@@ -7,7 +7,6 @@ $(call emugl-import,libOpenglSystemCommon libGLESv2_enc lib_renderControl_enc)
|
||||
LOCAL_CFLAGS += -DLOG_TAG=\"GLESv2_emulation\" -DGL_GLEXT_PROTOTYPES
|
||||
|
||||
LOCAL_SRC_FILES := gl2.cpp
|
||||
LOCAL_STATIC_LIBRARIES += libqemu
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_SHARED_LIBRARIES)/egl
|
||||
|
||||
$(call emugl-end-module)
|
||||
|
||||
@@ -10,6 +10,4 @@ LOCAL_SRC_FILES := \
|
||||
|
||||
$(call emugl-export,C_INCLUDES,$(LOCAL_PATH))
|
||||
|
||||
LOCAL_STATIC_LIBRARIES += libqemu
|
||||
|
||||
$(call emugl-end-module)
|
||||
|
||||
@@ -37,8 +37,7 @@ LOCAL_MODULE_CLASS := SHARED_LIBRARIES
|
||||
LOCAL_PRELINK_MODULE := false
|
||||
|
||||
LOCAL_STATIC_LIBRARIES := \
|
||||
libOpenglCodecCommon \
|
||||
libqemu
|
||||
libOpenglCodecCommon
|
||||
|
||||
LOCAL_SHARED_LIBRARIES := \
|
||||
libcutils \
|
||||
|
||||
@@ -31,8 +31,7 @@ LOCAL_MODULE_PATH = $(TARGET_OUT_SHARED_LIBRARIES)/hw
|
||||
LOCAL_MODULE := gralloc.goldfish
|
||||
|
||||
LOCAL_STATIC_LIBRARIES := \
|
||||
libOpenglCodecCommon \
|
||||
libqemu
|
||||
libOpenglCodecCommon
|
||||
|
||||
LOCAL_SHARED_LIBRARIES := \
|
||||
libcutils \
|
||||
|
||||
@@ -164,8 +164,7 @@ LOCAL_SHARED_LIBRARIES := libdl \
|
||||
libOpenglSystemCommon \
|
||||
libut_rendercontrol_enc
|
||||
|
||||
LOCAL_STATIC_LIBRARIES := libOpenglCodecCommon \
|
||||
libqemu
|
||||
LOCAL_STATIC_LIBRARIES := libOpenglCodecCommon
|
||||
|
||||
include $(BUILD_SHARED_LIBRARY)
|
||||
|
||||
|
||||
@@ -1,15 +0,0 @@
|
||||
LOCAL_PATH := $(call my-dir)
|
||||
|
||||
# The main libqemud library
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := libqemu
|
||||
LOCAL_SRC_FILES := libqemu.c
|
||||
LOCAL_MODULE_TAGS := debug
|
||||
include $(BUILD_STATIC_LIBRARY)
|
||||
|
||||
# Define BUILD_LIBQEMUD_TESTS to 'true' in your environment
|
||||
# to generate the following test programs. You must be on Linux!
|
||||
#
|
||||
ifeq (true-linux,$(strip $(BUILD_LIBQEMU_TESTS)-$(HOST_OS)))
|
||||
include $(LOCAL_PATH)/tests.mk
|
||||
endif # BUILD_LIBQEMUD_TESTS == true
|
||||
@@ -1,81 +0,0 @@
|
||||
/*
|
||||
* Copyright (C) 2011 The Android Open Source Project
|
||||
*
|
||||
* 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.
|
||||
*/
|
||||
|
||||
/* Set to 1 to enable debugging */
|
||||
#define DEBUG 0
|
||||
|
||||
#if DEBUG >= 1
|
||||
# define D(...) fprintf(stderr,"libqemud:" __VA_ARGS__), fprintf(stderr, "\n")
|
||||
#endif
|
||||
|
||||
#include <unistd.h>
|
||||
#include <fcntl.h>
|
||||
#include <sys/mman.h>
|
||||
#include <hardware/qemud.h>
|
||||
#include <hardware/qemu_pipe.h>
|
||||
#include <pthread.h> /* for pthread_once() */
|
||||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
|
||||
/* Used for debugging */
|
||||
|
||||
#ifndef D
|
||||
# define D(...) do{}while(0)
|
||||
#endif
|
||||
|
||||
/* Try to open a qemud pipe, 'pipeName' must be a generic pipe service
|
||||
* name (e.g. "opengles" or "camera"). The emulator will be in charge of
|
||||
* connecting the corresponding pipe/client to an internal service or an
|
||||
* external socket, these details are hidden from the caller.
|
||||
*
|
||||
* Return a new QemuPipe pointer, or NULL in case of error
|
||||
*/
|
||||
int
|
||||
qemu_pipe_open(const char* pipeName)
|
||||
{
|
||||
char buff[256];
|
||||
int buffLen;
|
||||
int fd, ret;
|
||||
|
||||
if (pipeName == NULL || pipeName[0] == '\0') {
|
||||
errno = EINVAL;
|
||||
return -1;
|
||||
}
|
||||
|
||||
snprintf(buff, sizeof buff, "pipe:%s", pipeName);
|
||||
|
||||
fd = open("/dev/qemu_pipe", O_RDWR);
|
||||
if (fd < 0) {
|
||||
D("%s: Could not open /dev/qemu_pipe: %s", __FUNCTION__, strerror(errno));
|
||||
errno = ENOSYS;
|
||||
return -1;
|
||||
}
|
||||
|
||||
buffLen = strlen(buff);
|
||||
|
||||
ret = TEMP_FAILURE_RETRY(write(fd, buff, buffLen+1));
|
||||
if (ret != buffLen+1) {
|
||||
D("%s: Could not connect to %s pipe service: %s", __FUNCTION__, pipeName, strerror(errno));
|
||||
if (ret == 0) {
|
||||
errno = ECONNRESET;
|
||||
} else if (ret > 0) {
|
||||
errno = EINVAL;
|
||||
}
|
||||
return -1;
|
||||
}
|
||||
|
||||
return fd;
|
||||
}
|
||||
@@ -19,12 +19,12 @@ include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := test-libqemu-1
|
||||
LOCAL_SRC_FILES := test_guest_1.c test_util.c
|
||||
LOCAL_MODULE_TAGS := debug
|
||||
LOCAL_STATIC_LIBRARIES := libqemu libcutils
|
||||
LOCAL_STATIC_LIBRARIES := libcutils
|
||||
include $(BUILD_EXECUTABLE)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := test-libqemu-2
|
||||
LOCAL_SRC_FILES := test_guest_2.c test_util.c
|
||||
LOCAL_MODULE_TAGS := debug
|
||||
LOCAL_STATIC_LIBRARIES := libqemu libcutils
|
||||
LOCAL_STATIC_LIBRARIES := libcutils
|
||||
include $(BUILD_EXECUTABLE)
|
||||
|
||||
Reference in New Issue
Block a user