qtkeychain 0.8.0 (new formula)
Closes #23327. Signed-off-by: ilovezfs <ilovezfs@icloud.com>
This commit is contained in:
parent
66c9024f18
commit
d494cb4eff
1 changed files with 29 additions and 0 deletions
29
Formula/qtkeychain.rb
Normal file
29
Formula/qtkeychain.rb
Normal file
|
@ -0,0 +1,29 @@
|
|||
class Qtkeychain < Formula
|
||||
desc "Platform-independent Qt API for storing passwords securely"
|
||||
homepage "https://github.com/frankosterfeld/qtkeychain"
|
||||
url "https://github.com/frankosterfeld/qtkeychain/archive/v0.8.0.tar.gz"
|
||||
sha256 "b492f603197538bc04b2714105b1ab2b327a9a98d400d53d9a7cb70edd2db12f"
|
||||
|
||||
depends_on "cmake" => :build
|
||||
depends_on "qt"
|
||||
|
||||
def install
|
||||
system "cmake", ".", "-DBUILD_TRANSLATIONS=OFF", *std_cmake_args
|
||||
system "make", "install"
|
||||
end
|
||||
|
||||
test do
|
||||
(testpath/"test.cpp").write <<~EOS
|
||||
#include <qt5keychain/keychain.h>
|
||||
int main() {
|
||||
QKeychain::ReadPasswordJob job(QLatin1String(""));
|
||||
return 0;
|
||||
}
|
||||
EOS
|
||||
system ENV.cxx, "test.cpp", "-o", "test", "-std=c++11", "-I#{include}",
|
||||
"-L#{lib}", "-lqt5keychain",
|
||||
"-I#{Formula["qt"].opt_include}",
|
||||
"-F#{Formula["qt"].opt_lib}", "-framework", "QtCore"
|
||||
system "./test"
|
||||
end
|
||||
end
|
Loading…
Reference in a new issue