Skip to content
This repository has been archived by the owner on Oct 6, 2024. It is now read-only.

Commit

Permalink
Remove cgo deps
Browse files Browse the repository at this point in the history
tag 0.3.2 release
  • Loading branch information
ch3ck committed Dec 27, 2021
1 parent 12d4a4c commit 4157f08
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 11 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -57,3 +57,5 @@ dist/
.envrc

dist/

dist/
18 changes: 7 additions & 11 deletions main.go
Original file line number Diff line number Diff line change
@@ -1,9 +1,5 @@
package main

// #cgo LDFLAGS: ./pkg/libydl.a -ldl
// #include "./pkg/download.h"
import "C"

import (
"errors"
"fmt"
Expand Down Expand Up @@ -129,11 +125,11 @@ func downloadVideo(url string, path string) error {
return nil
}

// rsDownloadVideo downloads video using rust library
func rsDownloadVideo(url string, path string) error {
cUrl := C.CString(url)
cPath := C.CString(path)
C.download(cUrl, cPath)
// // rsDownloadVideo downloads video using rust library
// func rsDownloadVideo(url string, path string) error {
// cUrl := C.CString(url)
// cPath := C.CString(path)
// C.download(cUrl, cPath)

return nil
}
// return nil
// }

0 comments on commit 4157f08

Please sign in to comment.