Skip to content

Commit

Permalink
[feat] Use build.rs to compile instead of cmake
Browse files Browse the repository at this point in the history
  • Loading branch information
uttarayan21 committed Nov 20, 2023
1 parent afaca75 commit 02039a6
Show file tree
Hide file tree
Showing 5 changed files with 382 additions and 167 deletions.
3 changes: 3 additions & 0 deletions .cargo/config.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[registries]
ktra = { index = "https://github.com/uttarayan21/crates-io.git" }

3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "vendor"]
path = vendor
url = https://github.com/libjpeg-turbo/libjpeg-turbo
21 changes: 14 additions & 7 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,18 +4,25 @@ description = "Builds and links libjpeg(-turbo)"
version = "0.1.0"
edition = "2021"
license = "MIT"
links = "libjpeg"
links = "jpeg"

[dependencies]
[lib]
name = "jpeg"
crate-type = ["staticlib", "cdylib", "rlib"]
links = "jpeg"

[build-dependencies]
cc = { version = "1.0.73", features = ["parallel"] }
itoa = { version = "1.0.4" }
# sorse = { version = "0.1.0", registry = "ktra" }
sorse = { path = "../sorse/" }

[features]
default = ["build"]

default = ["build", "simd"]
jpeg80_abi = ["jpeg70_abi"]
jpeg70_abi = ["arith_dec", "arith_enc"]
arith_enc = []
arith_dec = []
jpegtran = []
simd = []
clone = []
build = ["clone", "simd"]
no-build = []
build = []
Loading

0 comments on commit 02039a6

Please sign in to comment.