-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
430 changed files
with
59,379 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,81 @@ | ||
#!/bin/sh | ||
|
||
. /etc/profile | ||
oe_setup_addon service.system.acestreammedia | ||
|
||
PATH=/sbin:/bin:/usr/sbin:/usr/bin | ||
|
||
ACEDIR=$(readlink -f $(dirname $0)) | ||
ACECHROOT="androidfs" | ||
ACESTREAM_CACHE="$ACEDIR/$ACECHROOT/storage/.ACEStream" | ||
ACESTREAM_ENGINE="$ACEDIR/$ACECHROOT/acestream.engine" | ||
MOUNT_STATE="$ACEDIR/disk.mount" | ||
LOG="$ACEDIR/aceaddon.log" | ||
|
||
log(){ | ||
IS_DEBUG=$is_debug | ||
[ -z $IS_DEBUG ] && IS_DEBUG="false" | ||
[ $IS_DEBUG == "true" ] && echo "$(date +"%y-%m-%d %T")|"service.system.acestreammedia"|$(basename "$0")|$@" >> $LOG | ||
} | ||
|
||
log "==================== START ACESTREAM ENGINE =======================" | ||
|
||
chmod 755 $ACEDIR/acestream.start | ||
chmod 755 $ACEDIR/acestream.stop | ||
chmod 755 $ACEDIR/mount_disk.sh | ||
chmod 755 $ACEDIR/$ACECHROOT/system/bin/* $ACESTREAM_ENGINE/python/bin/python | ||
|
||
mkdir -p $ACEDIR/$ACECHROOT/system | ||
mkdir -p $ACEDIR/$ACECHROOT/dev | ||
mkdir -p $ACEDIR/$ACECHROOT/proc | ||
mkdir -p $ACEDIR/$ACECHROOT/sys | ||
mkdir -p $ACEDIR/$ACECHROOT/storage | ||
|
||
mount -o bind /dev $ACEDIR/$ACECHROOT/dev &>/dev/null | ||
mount -t proc proc $ACEDIR/$ACECHROOT/proc &>/dev/null | ||
mount -t sysfs sysfs $ACEDIR/$ACECHROOT/sys &>/dev/null | ||
|
||
[ ! -f $ACEDIR/$ACECHROOT/system/etc/resolv.conf ] && cp -L /etc/resolv.conf $ACEDIR/$ACECHROOT/system/etc/resolv.conf | ||
|
||
if [ ! -f $ACEDIR/$ACECHROOT/system/etc/hosts ]; then | ||
cp -L /etc/hosts $ACEDIR/$ACECHROOT/system/etc/hosts | ||
echo "67.215.246.10 router.bittorrent.com" >> $ACEDIR/$ACECHROOT/system/etc/hosts | ||
echo "212.129.33.59 dht.transmissionbt.com" >> $ACEDIR/$ACECHROOT/system/etc/hosts | ||
echo "82.221.103.244 router.utorrent.com" >> $ACEDIR/$ACECHROOT/system/etc/hosts | ||
fi | ||
|
||
DISK_CACHE=$disk_cache | ||
|
||
[ -z "$DISK_CACHE" ] && DISK_CACHE="default (/storage)" | ||
|
||
log "DISK_CACHE=$DISK_CACHE" | ||
|
||
if [ -f "$MOUNT_STATE" ]; then | ||
log "IF UMOUNT(there is a file disk.mount): yes" | ||
rm -f $MOUNT_STATE | ||
umount $ACEDIR/$ACECHROOT/storage &>/dev/null | ||
fi | ||
|
||
log "$DISK_CACHE != default (/storage)" | ||
|
||
if [ "default (/storage)" != "$DISK_CACHE" ]; then | ||
NAME_DISK=$(echo $DISK_CACHE | awk '{ print $1 }') | ||
MOUNT_DISK=$(echo $DISK_CACHE | sed -e 's/.*(\(.*\)).*/\1/') | ||
MOUNT_TYPE=$(/bin/mount | grep "$MOUNT_DISK" | sed -e "s|^.* type ||" | awk '{ print $1 }') | ||
log "MOUNT_DISK=$MOUNT_DISK" | ||
log "NAME_DISK=$NAME_DISK" | ||
log "MOUNT_TYPE=$MOUNT_TYPE" | ||
if [ "$MOUNT_TYPE" == "vfat" -o "$MOUNT_TYPE" == "ext4" -o "$MOUNT_TYPE" == "ext3" -o "$MOUNT_TYPE" == "ext2" ]; then | ||
log "MOUNT DISK: $MOUNT_DISK - MOUNT_TYPE=$MOUNT_TYPE" | ||
/sbin/chroot $ACEDIR/$ACECHROOT /system/bin/busybox mount -t $MOUNT_TYPE $MOUNT_DISK /storage &>/dev/null | ||
echo "$MOUNT_DISK" > $MOUNT_STATE | ||
elif [ "$MOUNT_TYPE" == "cifs" -o "$MOUNT_TYPE" == "nfs" ]; then | ||
log "MOUNT DISK: $MOUNT_DISK - MOUNT_TYPE=$MOUNT_TYPE" | ||
mount -o bind $MOUNT_DISK $ACEDIR/$ACECHROOT/storage &>/dev/null | ||
echo "$MOUNT_DISK" > $MOUNT_STATE | ||
else | ||
log "Error mount disk! No mount typer!" | ||
fi | ||
fi | ||
|
||
chroot $ACEDIR/$ACECHROOT /system/bin/busybox sh -c "/system/bin/acestream.sh" > $ACEDIR/acestream.log 2>&1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
#!/bin/sh | ||
|
||
ACEDIR=$(readlink -f $(dirname $0)) | ||
ACECHROOT="androidfs" | ||
MOUNT_STATE="$ACEDIR/disk.mount" | ||
|
||
pkill -9 -f "/acestream.engine/python/bin/python" &>/dev/null | ||
pkill -9 -f "/system/bin/acestream.sh" &>/dev/null | ||
|
||
|
||
umount $ACEDIR/$ACECHROOT/proc &>/dev/null | ||
umount $ACEDIR/$ACECHROOT/sys &>/dev/null | ||
umount $ACEDIR/$ACECHROOT/dev &>/dev/null | ||
|
||
if [ -f "$MOUNT_STATE" ]; then | ||
rm -f $MOUNT_STATE | ||
umount $ACEDIR/$ACECHROOT/storage &>/dev/null | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
3.1.27.1 |
Binary file not shown.
Binary file added
BIN
+6.51 MB
acestream.engine/androidfs/acestream.engine/acestreamengine/CoreApp.so
Binary file not shown.
Empty file.
Binary file added
BIN
+114 Bytes
acestream.engine/androidfs/acestream.engine/acestreamengine/__init__.pyc
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added
BIN
+25.9 KB
acestream.engine/androidfs/acestream.engine/acestreamengine/pycompat.so
Binary file not shown.
Binary file added
BIN
+13.3 MB
acestream.engine/androidfs/acestream.engine/acestreamengine/pysegmenter.so
Binary file not shown.
Binary file added
BIN
+1.97 MB
acestream.engine/androidfs/acestream.engine/acestreamengine/pywebrtc.so
Binary file not shown.
Binary file added
BIN
+529 KB
acestream.engine/androidfs/acestream.engine/acestreamengine/streamer.so
Binary file not shown.
221 changes: 221 additions & 0 deletions
221
acestream.engine/androidfs/acestream.engine/data/schema_sdb_v6.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,221 @@ | ||
-- TorrentStream SQLite Database | ||
-- Version: 1 | ||
|
||
BEGIN TRANSACTION create_table; | ||
|
||
---------------------------------------- | ||
|
||
CREATE TABLE Category ( | ||
category_id integer PRIMARY KEY NOT NULL, | ||
name text NOT NULL, | ||
description text | ||
); | ||
|
||
---------------------------------------- | ||
|
||
CREATE TABLE MyInfo ( | ||
entry PRIMARY KEY, | ||
value text | ||
); | ||
|
||
---------------------------------------- | ||
|
||
CREATE TABLE Torrent ( | ||
torrent_id integer PRIMARY KEY AUTOINCREMENT NOT NULL, | ||
is_multi integer NOT NULL DEFAULT 0, | ||
infohash text, | ||
`checksum` text NOT NULL, | ||
name text, | ||
torrent_file_name text, | ||
length integer, | ||
creation_date integer, | ||
num_files integer, | ||
thumbnail integer, | ||
insert_time numeric, | ||
secret integer, | ||
relevance numeric DEFAULT 0, | ||
source_id integer, | ||
category_id integer, | ||
status_id integer, | ||
num_seeders integer, | ||
num_leechers integer, | ||
comment text | ||
); | ||
|
||
CREATE INDEX infohash_idx | ||
ON Torrent | ||
(infohash); | ||
|
||
CREATE UNIQUE INDEX torrent_checksum_idx | ||
ON Torrent | ||
(`checksum`); | ||
|
||
CREATE INDEX Torrent_length_idx | ||
ON Torrent | ||
(length); | ||
|
||
CREATE INDEX Torrent_creation_date_idx | ||
ON Torrent | ||
(creation_date); | ||
|
||
CREATE INDEX Torrent_relevance_idx | ||
ON Torrent | ||
(relevance); | ||
|
||
CREATE INDEX Torrent_num_seeders_idx | ||
ON Torrent | ||
(num_seeders); | ||
|
||
CREATE INDEX Torrent_num_leechers_idx | ||
ON Torrent | ||
(num_leechers); | ||
|
||
CREATE INDEX Torrent_name_idx | ||
ON Torrent | ||
(name); | ||
|
||
---------------------------------------- | ||
|
||
CREATE TABLE TorrentSource ( | ||
source_id integer PRIMARY KEY NOT NULL, | ||
name text NOT NULL, | ||
description text | ||
); | ||
|
||
CREATE UNIQUE INDEX torrent_source_idx | ||
ON TorrentSource | ||
(name); | ||
|
||
---------------------------------------- | ||
|
||
CREATE TABLE TorrentStatus ( | ||
status_id integer PRIMARY KEY NOT NULL, | ||
name text NOT NULL, | ||
description text | ||
); | ||
|
||
---------------------------------------- | ||
|
||
CREATE TABLE TorrentTracker ( | ||
torrent_id integer NOT NULL, | ||
tracker text NOT NULL, | ||
announce_tier integer, | ||
ignored_times integer, | ||
retried_times integer, | ||
last_check numeric | ||
); | ||
|
||
CREATE UNIQUE INDEX torrent_tracker_idx | ||
ON TorrentTracker | ||
(torrent_id, tracker); | ||
|
||
---------------------------------------- | ||
--anton_ | ||
CREATE TABLE url2torrent ( | ||
urlhash TEXT PRIMARY KEY NOT NULL, | ||
url TEXT NOT NULL, | ||
infohash TEXT NOT NULL, | ||
updated NUMERIC | ||
); | ||
|
||
CREATE TABLE adid2infohash ( | ||
adid TEXT PRIMARY KEY NOT NULL, | ||
infohash TEXT NOT NULL, | ||
last_seen INTEGER NOT NULL | ||
); | ||
CREATE INDEX adid2infohash_infohash_idx ON adid2infohash (infohash); | ||
|
||
CREATE TABLE ts_players ( | ||
player_id TEXT PRIMARY KEY NOT NULL, | ||
is_multi INTEGER NOT NULL DEFAULT 0, | ||
`checksum` TEXT NOT NULL, | ||
infohash TEXT NULL, | ||
developer_id INTEGER, | ||
affiliate_id INTEGER, | ||
zone_id INTEGER | ||
); | ||
CREATE INDEX ts_players_checksum_idx ON ts_players (`checksum`); | ||
CREATE INDEX ts_players_infohash_idx ON ts_players (infohash); | ||
|
||
CREATE TABLE ts_metadata ( | ||
infohash TEXT PRIMARY KEY NOT NULL, | ||
idx INTEGER NOT NULL, | ||
duration INTEGER, | ||
prebuf_pieces TEXT, | ||
replace_mp4_metatags TEXT | ||
); | ||
|
||
CREATE UNIQUE INDEX ts_metadata_idx ON ts_metadata (infohash, idx); | ||
CREATE INDEX ts_metadata_infohash_idx ON ts_metadata (infohash); | ||
|
||
CREATE TABLE user_profiles ( | ||
`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, | ||
`created` INTEGER NOT NULL, | ||
`modified` INTEGER NOT NULL, | ||
`active` INTEGER NOT NULL | ||
); | ||
|
||
CREATE TABLE user_profile_data ( | ||
`profile_id` INTEGER NOT NULL, | ||
`name` TEXT NOT NULL, | ||
`value` TEXT | ||
); | ||
|
||
CREATE UNIQUE INDEX user_profile_data_idx_profile_param ON user_profile_data (`profile_id`, `name`); | ||
CREATE INDEX user_profile_data_idx_profile ON user_profile_data (`profile_id`); | ||
|
||
CREATE TABLE `gender` ( | ||
`id` INTEGER PRIMARY KEY NOT NULL, | ||
`name` TEXT NOT NULL | ||
); | ||
|
||
CREATE TABLE `age` ( | ||
`id` INTEGER PRIMARY KEY NOT NULL, | ||
`name` TEXT NOT NULL | ||
); | ||
--_anton | ||
---------------------------------------- | ||
|
||
CREATE VIEW CollectedTorrent AS SELECT * FROM Torrent WHERE torrent_file_name IS NOT NULL; | ||
|
||
------------------------------------- | ||
|
||
COMMIT TRANSACTION create_table; | ||
|
||
---------------------------------------- | ||
|
||
BEGIN TRANSACTION init_values; | ||
|
||
INSERT INTO Category VALUES (1, 'Video', 'Video Files'); | ||
INSERT INTO Category VALUES (2, 'VideoClips', 'Video Clips'); | ||
INSERT INTO Category VALUES (3, 'Audio', 'Audio'); | ||
INSERT INTO Category VALUES (4, 'Compressed', 'Compressed'); | ||
INSERT INTO Category VALUES (5, 'Document', 'Documents'); | ||
INSERT INTO Category VALUES (6, 'Picture', 'Pictures'); | ||
INSERT INTO Category VALUES (7, 'xxx', 'XXX'); | ||
INSERT INTO Category VALUES (8, 'other', 'Other'); | ||
|
||
INSERT INTO TorrentStatus VALUES (0, 'unknown', NULL); | ||
INSERT INTO TorrentStatus VALUES (1, 'good', NULL); | ||
INSERT INTO TorrentStatus VALUES (2, 'dead', NULL); | ||
|
||
INSERT INTO TorrentSource VALUES (0, '', 'Unknown'); | ||
INSERT INTO TorrentSource VALUES (1, 'TS', 'Received from other user'); | ||
|
||
INSERT INTO MyInfo VALUES ('version', 6); | ||
|
||
INSERT INTO `gender` VALUES (1, 'gender_male'); | ||
INSERT INTO `gender` VALUES (2, 'gender_female'); | ||
|
||
INSERT INTO `age` VALUES (1, 'age_less_than_13'); | ||
INSERT INTO `age` VALUES (2, 'age_13_17'); | ||
INSERT INTO `age` VALUES (3, 'age_18_21'); | ||
INSERT INTO `age` VALUES (9, 'age_22_25'); | ||
INSERT INTO `age` VALUES (4, 'age_26_30'); | ||
INSERT INTO `age` VALUES (10, 'age_31_36'); | ||
INSERT INTO `age` VALUES (5, 'age_37_44'); | ||
INSERT INTO `age` VALUES (6, 'age_45_54'); | ||
INSERT INTO `age` VALUES (7, 'age_55_64'); | ||
INSERT INTO `age` VALUES (8, 'age_more_than_64'); | ||
|
||
COMMIT TRANSACTION init_values; |
Oops, something went wrong.