Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add basic rate conversion #3

Merged
merged 35 commits into from
Sep 24, 2023
Merged

Add basic rate conversion #3

merged 35 commits into from
Sep 24, 2023

Conversation

virtualdesigner
Copy link
Collaborator

Added minimal prototype as mentioned in the issue #1

Screen.Recording.2023-09-03.at.12.26.56.PM.mov

@kirillt
Copy link
Member

kirillt commented Sep 3, 2023

Thank you @virtualdesigner, could you also provide detailed build instructions in README?

I try this:

yarn
yarn tauri dev

But it crashes:

The following warnings were emitted during compilation:

warning: `PKG_CONFIG_ALLOW_SYSTEM_CFLAGS="1" "pkg-config" "--libs" "--cflags" "javascriptcoregtk-4.1" "javascriptcoregtk-4.1 >= 2.38"` did not exit successfully: exit status: 1

error: failed to run custom build command for `javascriptcore-rs-sys v1.0.0`

Caused by:
  process didn't exit successfully: `/tmp/ARK-Builders/ARK-Rate-Desktop/src-tauri/target/debug/build/javascriptcore-rs-sys-6f7b0409cd3c8a1b/build-script-build` (exit status: 1)
  --- stdout
  cargo:rerun-if-env-changed=JAVASCRIPTCOREGTK_4.1_NO_PKG_CONFIG
  cargo:rerun-if-env-changed=PKG_CONFIG_x86_64-unknown-linux-gnu
  cargo:rerun-if-env-changed=PKG_CONFIG_x86_64_unknown_linux_gnu
  cargo:rerun-if-env-changed=HOST_PKG_CONFIG
  cargo:rerun-if-env-changed=PKG_CONFIG
  cargo:rerun-if-env-changed=PKG_CONFIG_PATH_x86_64-unknown-linux-gnu
  cargo:rerun-if-env-changed=PKG_CONFIG_PATH_x86_64_unknown_linux_gnu
  cargo:rerun-if-env-changed=HOST_PKG_CONFIG_PATH
  cargo:rerun-if-env-changed=PKG_CONFIG_PATH
  cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR_x86_64-unknown-linux-gnu
  cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR_x86_64_unknown_linux_gnu
  cargo:rerun-if-env-changed=HOST_PKG_CONFIG_LIBDIR
  cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR
  cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR_x86_64-unknown-linux-gnu
  cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR_x86_64_unknown_linux_gnu
  cargo:rerun-if-env-changed=HOST_PKG_CONFIG_SYSROOT_DIR
  cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR
  cargo:warning=`PKG_CONFIG_ALLOW_SYSTEM_CFLAGS="1" "pkg-config" "--libs" "--cflags" "javascriptcoregtk-4.1" "javascriptcoregtk-4.1 >= 2.38"` did not exit successfully: exit status: 1
  error: could not find system library 'javascriptcoregtk-4.1' required by the 'javascriptcore-rs-sys' crate

  --- stderr
  Package javascriptcoregtk-4.1 was not found in the pkg-config search path.
  Perhaps you should add the directory containing `javascriptcoregtk-4.1.pc'
  to the PKG_CONFIG_PATH environment variable
  Package 'javascriptcoregtk-4.1', required by 'virtual:world', not found
  Package 'javascriptcoregtk-4.1', required by 'virtual:world', not found

warning: build failed, waiting for other jobs to finish...

error Command failed with exit code 101.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

@virtualdesigner
Copy link
Collaborator Author

Thank you @virtualdesigner, could you also provide detailed build instructions in README?

I try this:

yarn
yarn tauri dev

But it crashes:

The following warnings were emitted during compilation:

warning: `PKG_CONFIG_ALLOW_SYSTEM_CFLAGS="1" "pkg-config" "--libs" "--cflags" "javascriptcoregtk-4.1" "javascriptcoregtk-4.1 >= 2.38"` did not exit successfully: exit status: 1

error: failed to run custom build command for `javascriptcore-rs-sys v1.0.0`

Caused by:
  process didn't exit successfully: `/tmp/ARK-Builders/ARK-Rate-Desktop/src-tauri/target/debug/build/javascriptcore-rs-sys-6f7b0409cd3c8a1b/build-script-build` (exit status: 1)
  --- stdout
  cargo:rerun-if-env-changed=JAVASCRIPTCOREGTK_4.1_NO_PKG_CONFIG
  cargo:rerun-if-env-changed=PKG_CONFIG_x86_64-unknown-linux-gnu
  cargo:rerun-if-env-changed=PKG_CONFIG_x86_64_unknown_linux_gnu
  cargo:rerun-if-env-changed=HOST_PKG_CONFIG
  cargo:rerun-if-env-changed=PKG_CONFIG
  cargo:rerun-if-env-changed=PKG_CONFIG_PATH_x86_64-unknown-linux-gnu
  cargo:rerun-if-env-changed=PKG_CONFIG_PATH_x86_64_unknown_linux_gnu
  cargo:rerun-if-env-changed=HOST_PKG_CONFIG_PATH
  cargo:rerun-if-env-changed=PKG_CONFIG_PATH
  cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR_x86_64-unknown-linux-gnu
  cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR_x86_64_unknown_linux_gnu
  cargo:rerun-if-env-changed=HOST_PKG_CONFIG_LIBDIR
  cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR
  cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR_x86_64-unknown-linux-gnu
  cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR_x86_64_unknown_linux_gnu
  cargo:rerun-if-env-changed=HOST_PKG_CONFIG_SYSROOT_DIR
  cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR
  cargo:warning=`PKG_CONFIG_ALLOW_SYSTEM_CFLAGS="1" "pkg-config" "--libs" "--cflags" "javascriptcoregtk-4.1" "javascriptcoregtk-4.1 >= 2.38"` did not exit successfully: exit status: 1
  error: could not find system library 'javascriptcoregtk-4.1' required by the 'javascriptcore-rs-sys' crate

  --- stderr
  Package javascriptcoregtk-4.1 was not found in the pkg-config search path.
  Perhaps you should add the directory containing `javascriptcoregtk-4.1.pc'
  to the PKG_CONFIG_PATH environment variable
  Package 'javascriptcoregtk-4.1', required by 'virtual:world', not found
  Package 'javascriptcoregtk-4.1', required by 'virtual:world', not found

warning: build failed, waiting for other jobs to finish...

error Command failed with exit code 101.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

@kirillt I've added some instructions to install the app. We need to install some OS-specific dependencies before getting started. Can you please try out the steps and let me know how it goes?

@kirillt
Copy link
Member

kirillt commented Sep 4, 2023

@virtualdesigner the steps seem to be the same (yarn and yarn tauri dev). Do I need to install Tauri Bundler? That's something new, I guess, since it wasn't necessary before (https://github.com/ARK-Builders/ark-shelf-desktop).

@kirillt
Copy link
Member

kirillt commented Sep 4, 2023

It seems that the bundler is only needed for building a package. Right now, yarn tauri dev crashes, so I can't run the project.

But the video looks cool!

@virtualdesigner
Copy link
Collaborator Author

virtualdesigner commented Sep 4, 2023

@kirillt I've added more details in the readme for installing the prerequisites.
From the error message, I guess you'd need to install the missing package javascriptcore-rs-sys.

@kirillt
Copy link
Member

kirillt commented Sep 4, 2023

Thanks @virtualdesigner, now it's good. On my laptop it's still crashing, but I believe it's something specific to my installation of Fedora Linux.

I think we should complete these 2 steps before merge:

@kirillt
Copy link
Member

kirillt commented Sep 4, 2023

For Linux, AppImage is fine (no need to build .dep or .rpm). I'm not sure about Windows and macOS, is it same complexity? @virtualdesigner

src-tauri/src/lib.rs Outdated Show resolved Hide resolved
package.json Outdated Show resolved Hide resolved
public/tauri.svg Outdated Show resolved Hide resolved
src-tauri/Cargo.toml Outdated Show resolved Hide resolved
src-tauri/src/lib.rs Outdated Show resolved Hide resolved
src-tauri/src/lib.rs Outdated Show resolved Hide resolved
src/context/CurrencyContext.tsx Outdated Show resolved Hide resolved
src/context/CurrencyContext.tsx Outdated Show resolved Hide resolved
@kirillt
Copy link
Member

kirillt commented Sep 16, 2023

Latest AppImage can't start with this error:

`Err` value: Os { code: 30, kind: ReadOnlyFilesystem, message: "Read-only file system" }'

@kirillt
Copy link
Member

kirillt commented Sep 23, 2023

@virtualdesigner It worked on my laptop, great!

Could you also update .github/workflows/build.yml?

  • Bump version of actions/checkout
  • Replace deprecated actions-rs/toolchain with newer dtolnay/rust-toolchain

Here is an example: https://github.com/ARK-Builders/ARK-Shelf-Desktop/blob/main/.github/workflows/build.yml

@kirillt kirillt self-requested a review September 24, 2023 15:00
Copy link
Member

@kirillt kirillt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good job, thanks

@kirillt kirillt merged commit 3c35c67 into main Sep 24, 2023
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants