@@ -25,7 +25,7 @@ pub fn run(args: Args) {
2525 let alpine_public_key = cmd ! ( "pass" , "tangram/keys/alpine.public.rsa" )
2626 . read ( )
2727 . unwrap ( ) ;
28- let alpine_private_key = cmd ! ( "pass" , "tangram/keys/alpine.public .rsa" )
28+ let alpine_private_key = cmd ! ( "pass" , "tangram/keys/alpine.private .rsa" )
2929 . read ( )
3030 . unwrap ( ) ;
3131 let deb_public_key = cmd ! ( "pass" , "tangram/keys/deb.public.gpg" ) . read ( ) . unwrap ( ) ;
@@ -89,7 +89,7 @@ fn alpine(
8989 alpine_public_key_path : & Path ,
9090 alpine_private_key_path : & Path ,
9191) -> Result < ( ) > {
92- for arch in [ Arch :: X8664 , Arch :: AArch64 ] {
92+ for target in [ Target :: X8664UnknownLinuxMusl ] {
9393 let repo_path = pkgs_path. join ( "stable" ) . join ( "alpine" ) ;
9494 std:: fs:: create_dir_all ( & repo_path) . unwrap ( ) ;
9595 std:: fs:: copy ( alpine_public_key_path, repo_path. join ( "tangram.rsa" ) ) . unwrap ( ) ;
@@ -106,39 +106,36 @@ fn alpine(
106106 arch={arch}
107107 license="MIT"
108108 source="tangram"
109- \n
109+ options="!strip"
110+
110111 check() {{
111112 :
112113 }}
113- \n
114+
114115 package() {{
115116 install -D -m 755 "$srcdir"/tangram "$pkgdir"/usr/bin/tangram
116117 }}
117118 "# ,
118119 version = args. version,
119- arch = match arch {
120+ arch = match target . arch( ) {
120121 Arch :: X8664 => "x86_64" ,
121122 Arch :: AArch64 => "aarch64" ,
122123 Arch :: Wasm32 => unreachable!( ) ,
123124 } ,
124125 ) ;
125126 std:: fs:: write ( & apkbuild_path, & apkbuild) . unwrap ( ) ;
126127 let tangram_cli_dst_path = repo_path. join ( "tangram" ) ;
127- let target = match arch {
128- Arch :: X8664 => Target :: X8664UnknownLinuxGnu ,
129- Arch :: AArch64 => Target :: AArch64UnknownLinuxGnu ,
130- Arch :: Wasm32 => unreachable ! ( ) ,
131- } ;
132128 let tangram_cli_path = dist_path
133129 . join ( target. as_str ( ) )
134130 . join ( TargetFileNames :: for_target ( target) . tangram_cli_file_name ) ;
135131 std:: fs:: copy ( tangram_cli_path, & tangram_cli_dst_path) . unwrap ( ) ;
136132 let script = r#"
133+ set -e
137134 apk add build-base abuild
138- echo "PACKAGER_PUBKEY=/tangram .public.rsa" >> /etc/abuild.conf
139- echo "PACKAGER_PRIVKEY=/tangram .private.rsa" >> /etc/abuild.conf
135+ echo "PACKAGER_PUBKEY=/alpine .public.rsa" >> /etc/abuild.conf
136+ echo "PACKAGER_PRIVKEY=/alpine .private.rsa" >> /etc/abuild.conf
140137 abuild -F checksum
141- abuild -F -P $PWD
138+ abuild -f - F -P $PWD
142139 rm -rf src pkg
143140 "# ;
144141 cmd ! (
@@ -156,13 +153,13 @@ fn alpine(
156153 format!(
157154 "{}:{}" ,
158155 alpine_public_key_path. canonicalize( ) . unwrap( ) . display( ) ,
159- "/tangram .public.rsa"
156+ "/alpine .public.rsa"
160157 ) ,
161158 "-v" ,
162159 format!(
163160 "{}:{}" ,
164161 alpine_private_key_path. canonicalize( ) . unwrap( ) . display( ) ,
165- "/tangram .private.rsa"
162+ "/alpine .private.rsa"
166163 ) ,
167164 "-w" ,
168165 "/tangram" ,
0 commit comments