Migrated project to C
This commit is contained in:
parent
2833cacac3
commit
8bcc0cdaaa
8 changed files with 35 additions and 18 deletions
3
.gitignore
vendored
3
.gitignore
vendored
|
@ -54,3 +54,6 @@ dkms.conf
|
||||||
|
|
||||||
# Executables
|
# Executables
|
||||||
**.fap
|
**.fap
|
||||||
|
|
||||||
|
# Cache
|
||||||
|
**.ufbt/
|
|
@ -8,21 +8,10 @@ WORKDIR /tmp/src
|
||||||
|
|
||||||
## Installing Requisites
|
## Installing Requisites
|
||||||
RUN apt update -y
|
RUN apt update -y
|
||||||
RUN apt install -y wget curl build-essential pkg-config libssl-dev
|
RUN apt install -y curl wget python3 python3-pip
|
||||||
|
|
||||||
## Downloading RUSTUP
|
## Downloading uFBT
|
||||||
RUN wget https://sh.rustup.rs -O /tmp/rustup.sh
|
RUN pip install ufbt --break-system-packages
|
||||||
RUN chmod +x /tmp/rustup.sh
|
|
||||||
RUN /tmp/rustup.sh -y
|
|
||||||
RUN chmod +x /root/.cargo/env
|
|
||||||
RUN /root/.cargo/env
|
|
||||||
|
|
||||||
## Downloading rustup requirements
|
|
||||||
RUN /root/.cargo/bin/rustup toolchain install nightly
|
|
||||||
RUN /root/.cargo/bin/cargo install cargo-generate
|
|
||||||
|
|
||||||
## Flipper-Zero Build Target
|
|
||||||
RUN /root/.cargo/bin/rustup target add --toolchain nightly thumbv7em-none-eabihf
|
|
||||||
|
|
||||||
## Copying compile script
|
## Copying compile script
|
||||||
COPY docker/flipper-dev.sh /bin/flipper-dev.sh
|
COPY docker/flipper-dev.sh /bin/flipper-dev.sh
|
||||||
|
|
|
@ -3,7 +3,7 @@ cp -r /src/. ./
|
||||||
cp -r /src/* ./
|
cp -r /src/* ./
|
||||||
|
|
||||||
# Building the Project
|
# Building the Project
|
||||||
/root/.cargo/bin/cargo build --target thumbv7em-none-eabihf
|
ufbt
|
||||||
|
|
||||||
# Copy the .FAP file to the app directory
|
# Copy the .FAP file to the app directory
|
||||||
cp ./target/thumbv7em-none-eabihf/debug/*.fap /app/
|
cp dist/*.fap /app/
|
14
project/application.fam
Normal file
14
project/application.fam
Normal file
|
@ -0,0 +1,14 @@
|
||||||
|
App(
|
||||||
|
appid="flippypass", # Must be unique
|
||||||
|
name="Flippy Pass", # Displayed in menus
|
||||||
|
apptype=FlipperAppType.EXTERNAL,
|
||||||
|
entry_point="flippypass_app",
|
||||||
|
stack_size=2 * 1024,
|
||||||
|
fap_category="Tools",
|
||||||
|
# Optional values
|
||||||
|
fap_version="0.1",
|
||||||
|
fap_icon="flippypass.png", # 10x10 1-bit PNG
|
||||||
|
fap_description="A Password Manager for the Flipper-Zero",
|
||||||
|
fap_author="OBJNULL",
|
||||||
|
fap_weburl="https://git.objnull.net/objnull/FlippyPass"
|
||||||
|
)
|
11
project/flippypass.c
Normal file
11
project/flippypass.c
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
// Libraries
|
||||||
|
#include <furi.h>
|
||||||
|
|
||||||
|
// Entry Point
|
||||||
|
int32_t flippypass_app(void* p) {
|
||||||
|
// Not using P Parameter
|
||||||
|
UNUSED(p);
|
||||||
|
|
||||||
|
// Exit App
|
||||||
|
return 0;
|
||||||
|
}
|
BIN
project/flippypass.png
Normal file
BIN
project/flippypass.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 111 B |
|
@ -1,7 +1,7 @@
|
||||||
clear
|
clear
|
||||||
echo "Building Project"
|
|
||||||
docker run --rm -it \
|
docker run --rm -it \
|
||||||
-e USER=$USER \
|
-e USER=$USER \
|
||||||
-v "$PWD/project:/src:ro,z" \
|
-v "$PWD/project:/src:ro,z" \
|
||||||
-v "$PWD/build:/app:Z" \
|
-v "$PWD/build:/app:Z" \
|
||||||
flipper-dev
|
-v "$PWD/.ufbt:/root/.ufbt:Z" \
|
||||||
|
flipper-dev $@
|
Loading…
Reference in a new issue