M7350v1_en_gpl

This commit is contained in:
T
2024-09-09 08:52:07 +00:00
commit f9cc65cfda
65988 changed files with 26357421 additions and 0 deletions
+29
View File
@@ -0,0 +1,29 @@
# Copyright (C) 2008 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.
ifneq ($(TARGET_SIMULATOR),true)
ifeq ($(TARGET_ARCH),arm)
LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)
LOCAL_SRC_FILES := duadummy.c
LOCAL_MODULE := libduadummy
LOCAL_MODULE_TAGS := eng
LOCAL_C_INCLUDES += bootable/recovery
include $(BUILD_STATIC_LIBRARY)
endif # TARGET_ARCH == arm
endif # !TARGET_SIMULATOR
+31
View File
@@ -0,0 +1,31 @@
AM_CFLAGS := -Wundef \
-Wstrict-prototypes \
-Wno-trigraphs \
-g -O0 \
-fno-inline \
-fno-short-enums \
-fpic
AM_CPPFLAGS := \
-I.
AM_LDFLAGS := -shared -version-info 1:0:0
c_sources := duadummy.c
library_includedir := $(pkgincludedir)
library_include_HEADERS := $(h_sources)
lib_LTLIBRARIES := libduadummy.la
if USE_GLIB
libduadummy_la_SOURCES := $(c_sources) $(h_sources)
libduadummy_la_CFLAGS := $(AM_CFLAGS) -DUSE_GLIB @GLIB_CFLAGS@
libduadummy_la_CPPFLAGS := $(AM_CPPFLAGS) -DUSE_GLIB @GLIB_CFLAGS@
libduadummy_la_LIBADD := -lm -lpthread @GLIB_LIBS@
libduadummy_la_LDFLAGS := -all-static
else
libduadummy_la_SOURCES := $(c_sources) $(h_sources)
libduadummy_la_CFLAGS := $(AM_CFLAGS)
libduadummy_la_CPPFLAGS := $(AM_CPPFLAGS)
libduadummy_la_LIBADD := -lm -lpthread
libduadummy_la_LDFLAGS := -all-static
endif
+52
View File
@@ -0,0 +1,52 @@
/* Copyright (c) 2011, The Linux Foundation. All rights reserved.
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
* met:
* * Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* * Redistributions in binary form must reproduce the above
* copyright notice, this list of conditions and the following
* disclaimer in the documentation and/or other materials provided
* with the distribution.
* * Neither the name of The Linux Foundation nor the names of its
* contributors may be used to endorse or promote products derived
* from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED
* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT
* ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS
* BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
* BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
* WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
* IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#include <errno.h>
#include <libgen.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/stat.h>
#include <sys/statfs.h>
#include <sys/types.h>
#include "mincrypt/sha.h"
#include "edify/expr.h"
typedef ssize_t (*SinkFn)(unsigned char*, ssize_t, void*);
// delta update
int ApplyIPDiffPatch(const unsigned char* old_data, ssize_t old_size,
const Value* patch, ssize_t patch_offset,
SinkFn sink, void* token, SHA_CTX* ctx){
return -1;
}
int ipth_UpdateOneFile(const unsigned char* old_buf, ssize_t old_len,
const Value* patch, ssize_t patch_offset,
unsigned char** new_buf, ssize_t* new_len){
return -1;
}