Compare commits
5 Commits
main
...
what-if-dh
Author | SHA1 | Date | |
---|---|---|---|
ee0aac8877 | |||
641c699720 | |||
aa1ad0a080 | |||
1bc492aef1 | |||
928ff690d2 |
3
.gitmodules
vendored
3
.gitmodules
vendored
@ -22,3 +22,6 @@
|
||||
[submodule "deps/openssl_src"]
|
||||
path = deps/openssl_src
|
||||
url = https://github.com/openssl/openssl.git
|
||||
[submodule "deps/dht"]
|
||||
path = deps/dht
|
||||
url = https://github.com/jech/dht.git
|
||||
|
26
GNUmakefile
26
GNUmakefile
@ -3,9 +3,9 @@
|
||||
MAKEFLAGS += --warn-undefined-variables
|
||||
MAKEFLAGS += --no-builtin-rules
|
||||
|
||||
VERSION_CODE := 24
|
||||
VERSION_NUMBER := 0.0.21
|
||||
VERSION_NAME := What are we even doing here?
|
||||
VERSION_CODE := 25
|
||||
VERSION_NUMBER := 0.0.22-wip
|
||||
VERSION_NAME := This looks like a good place.
|
||||
|
||||
SQLITE_URL := https://www.sqlite.org/2024/sqlite-amalgamation-3460000.zip
|
||||
LIBUV_URL := https://dist.libuv.org/dist/v1.48.0/libuv-v1.48.0.tar.gz
|
||||
@ -250,6 +250,7 @@ APP_OBJS := $(call get_objs,APP_SOURCES)
|
||||
$(APP_OBJS): CFLAGS += \
|
||||
-Ideps/base64c/include \
|
||||
-Ideps/crypt_blowfish \
|
||||
-Ideps/dht \
|
||||
-Ideps/libbacktrace \
|
||||
-Ideps/libsodium \
|
||||
-Ideps/libsodium/src/libsodium/include \
|
||||
@ -587,6 +588,9 @@ $(MINIUNZIP_OBJS): CFLAGS += \
|
||||
-Ideps/zlib \
|
||||
-Wno-maybe-uninitialized
|
||||
|
||||
DHT_SOURCES := deps/dht/dht.c
|
||||
DHT_OBJS := $(call get_objs,DHT_SOURCES)
|
||||
|
||||
LDFLAGS += \
|
||||
-pthread \
|
||||
-lm
|
||||
@ -633,6 +637,7 @@ all: $(BUILD_TYPES)
|
||||
ALL_APP_OBJS := \
|
||||
$(APP_OBJS) \
|
||||
$(BLOWFISH_OBJS) \
|
||||
$(DHT_OBJS) \
|
||||
$(LIBBACKTRACE_OBJS) \
|
||||
$(MINIUNZIP_OBJS) \
|
||||
$(PICOHTTPPARSER_OBJS) \
|
||||
@ -675,6 +680,15 @@ src/version.h : $(firstword $(MAKEFILE_LIST))
|
||||
@echo "#define VERSION_NUMBER \"$(VERSION_NUMBER)\"" > $@
|
||||
@echo "#define VERSION_NAME \"$(VERSION_NAME)\"" >> $@
|
||||
|
||||
src/android/AndroidManifest.xml : $(firstword $(MAKEFILE_LIST))
|
||||
@echo "[android_version] $@"
|
||||
@sed -i \
|
||||
-e 's/versionCode=".*"/versionCode="$(VERSION_CODE)"/' \
|
||||
-e 's/versionName=".*"/versionName="$(VERSION_NUMBER)"/' \
|
||||
-e 's/android:minSdkVersion="[[:digit:]]*"/android:minSdkVersion="$(ANDROID_MIN_SDK_VERSION)"/' \
|
||||
-e 's/android:targetSdkVersion="[[:digit:]]*"/android:targetSdkVersion="$(ANDROID_TARGET_SDK_VERSION)"/' \
|
||||
$@
|
||||
|
||||
# Android support.
|
||||
out/res/layout_activity_main.xml.flat: src/android/res/layout/activity_main.xml
|
||||
@mkdir -p $(dir $@)
|
||||
@ -690,8 +704,6 @@ out/apk/res.apk out/gen/com/unprompted/tildefriends/R.java: out/res/layout_activ
|
||||
@echo [aapt2 link] res.apk
|
||||
@mkdir -p out/apk/
|
||||
@$(ANDROID_BUILD_TOOLS)/aapt2 link -I $(ANDROID_PLATFORM)/android.jar out/res/layout_activity_main.xml.flat out/res/drawable_icon.xml.flat \
|
||||
--version-code $(VERSION_CODE) \
|
||||
--version-name $(VERSION_NUMBER) \
|
||||
--min-sdk-version $(ANDROID_MIN_SDK_VERSION) \
|
||||
--target-sdk-version $(ANDROID_TARGET_SDK_VERSION) \
|
||||
--manifest src/android/AndroidManifest.xml \
|
||||
@ -702,8 +714,6 @@ out/apk/res.fdroid.apk out/gen_fdroid/com/unprompted/tildefriends/R.java: out/re
|
||||
@echo [aapt2 link] res.fdroid.apk
|
||||
@mkdir -p out/apk/
|
||||
@$(ANDROID_BUILD_TOOLS)/aapt2 link -I $(ANDROID_PLATFORM)/android.jar out/res/layout_activity_main.xml.flat out/res/drawable_icon.xml.flat \
|
||||
--version-code $(VERSION_CODE) \
|
||||
--version-name $(VERSION_NUMBER) \
|
||||
--min-sdk-version $(ANDROID_MIN_SDK_VERSION) \
|
||||
--target-sdk-version $(ANDROID_TARGET_SDK_VERSION) \
|
||||
--rename-manifest-package com.unprompted.tildefriends.fdroid \
|
||||
@ -753,8 +763,6 @@ out/TildeFriends.aab: out/apk/classes.dex $(filter-out %debug%, $(ANDROID_TARGET
|
||||
@mkdir -p out/aab/staging
|
||||
@$(ANDROID_BUILD_TOOLS)/aapt2 link --proto-format -o out/aab/temporary.apk \
|
||||
-I $(ANDROID_PLATFORM)/android.jar \
|
||||
--version-code $(VERSION_CODE) \
|
||||
--version-name $(VERSION_NUMBER) \
|
||||
--min-sdk-version $(ANDROID_MIN_SDK_VERSION) \
|
||||
--target-sdk-version $(ANDROID_TARGET_SDK_VERSION) \
|
||||
--manifest src/android/AndroidManifest.xml \
|
||||
|
1
deps/dht
vendored
Submodule
1
deps/dht
vendored
Submodule
@ -0,0 +1 @@
|
||||
Subproject commit 111230894416d400c9a1e038a033586bfeaafc93
|
2
deps/libbacktrace
vendored
2
deps/libbacktrace
vendored
@ -1 +1 @@
|
||||
Subproject commit 7e2b7da3d6568d2e4e78658f22e701746a48d7e1
|
||||
Subproject commit 0dd27b95f9f2c11b4a89db5f185a888af912838e
|
BIN
metadata/en-US/images/icon.png
Normal file
BIN
metadata/en-US/images/icon.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 52 KiB |
Binary file not shown.
After Width: | Height: | Size: 298 KiB |
Binary file not shown.
After Width: | Height: | Size: 275 KiB |
Binary file not shown.
After Width: | Height: | Size: 186 KiB |
@ -4,6 +4,8 @@
|
||||
<uses-permission android:name="android.permission.INTERNET"/>
|
||||
<application
|
||||
android:label="Tilde Friends"
|
||||
android:versionCode="25"
|
||||
android:versionName="0.0.22-wip"
|
||||
android:usesCleartextTraffic="true"
|
||||
android:debuggable="false">
|
||||
<meta-data android:name="android.max_aspect" android:value="2.1"/>
|
||||
|
34
src/dht.c
Normal file
34
src/dht.c
Normal file
@ -0,0 +1,34 @@
|
||||
#include <stddef.h>
|
||||
#include <stdio.h>
|
||||
|
||||
#if defined(_WIN32)
|
||||
#define WIN32_LEAN_AND_MEAN
|
||||
#include <winsock2.h>
|
||||
#include <windows.h>
|
||||
#include <winsock.h>
|
||||
#include <ws2tcpip.h>
|
||||
#else
|
||||
#include <netinet/in.h>
|
||||
#include <sys/socket.h>
|
||||
#endif
|
||||
|
||||
#include "dht.h"
|
||||
|
||||
int dht_sendto(int sockfd, const void *buf, int len, int flags, const struct sockaddr *to, int tolen)
|
||||
{
|
||||
return -1;
|
||||
}
|
||||
|
||||
int dht_blacklisted(const struct sockaddr *sa, int salen)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
void dht_hash(void *hash_return, int hash_size, const void *v1, int len1, const void *v2, int len2, const void *v3, int len3)
|
||||
{
|
||||
}
|
||||
|
||||
int dht_random_bytes(void *buf, size_t size)
|
||||
{
|
||||
return 0;
|
||||
}
|
@ -1,2 +1,2 @@
|
||||
#define VERSION_NUMBER "0.0.21"
|
||||
#define VERSION_NAME "What are we even doing here?"
|
||||
#define VERSION_NUMBER "0.0.22-wip"
|
||||
#define VERSION_NAME "This looks like a good place."
|
||||
|
Loading…
Reference in New Issue
Block a user