Browse Source

Remove debug prints from release build

tags/v2.1^0 v2.1
Manos Pitsidianakis 9 months ago
parent
commit
443a73605c
Signed by: epilys GPG Key ID: 73627C2F690DF710
  1. 3
      Cargo.toml
  2. 2
      Makefile
  3. 22
      pkg/meli.js
  4. BIN
      pkg/meli_bg.wasm

3
Cargo.toml

@ -105,7 +105,7 @@ members = ["melib", "tools", ]
[features]
#default = ["sqlite3", "notmuch", "regexp", "smtp", "dbus-notifications"]
default = ["wasm", "debug-tracing"]
default = ["wasm"]
notmuch = ["melib/notmuch_backend", ]
jmap = ["melib/jmap_backend",]
sqlite3 = ["melib/sqlite3"]
@ -131,5 +131,6 @@ wasm-bindgen-test = "0.3.13"
[profile.release]
# Tell `rustc` to optimize for small code size.
debug = false
opt-level = "s"
lto = "fat"

2
Makefile

@ -48,7 +48,7 @@ GREEN ?= `[ -z $${NO_COLOR+x} ] && ([ -z $${TERM} ] && echo "" || tput setaf 2)
.SUFFIXES:
meli: check-deps
#@${CARGO_BIN} build ${CARGO_COLOR}--target-dir="${CARGO_TARGET_DIR}" ${FEATURES} --release
wasm-pack build --no-typescript -t web #--dev
wasm-pack build --no-typescript -t web --release #--dev
help:

22
pkg/meli.js

@ -221,12 +221,6 @@ export function greet() {
}
/**
*/
export function run() {
wasm.run();
}
/**
* Entry point invoked by `worker.js`, a bit of a hack but see the "TODO" above
* about `worker.js` in general.
* @param {number} ptr
@ -235,6 +229,12 @@ export function child_entry_point(ptr) {
wasm.child_entry_point(ptr);
}
/**
*/
export function run() {
wasm.run();
}
function handleError(f) {
return function () {
try {
@ -327,9 +327,6 @@ async function init(input) {
imports.wbg.__wbindgen_object_drop_ref = function(arg0) {
takeObject(arg0);
};
imports.wbg.__wbg_log_be7baab5cb258473 = function(arg0, arg1) {
console.log(getStringFromWasm0(arg0, arg1));
};
imports.wbg.__wbindgen_cb_drop = function(arg0) {
const obj = takeObject(arg0).original;
if (obj.cnt-- == 1) {
@ -339,6 +336,9 @@ async function init(input) {
var ret = false;
return ret;
};
imports.wbg.__wbg_log_be7baab5cb258473 = function(arg0, arg1) {
console.log(getStringFromWasm0(arg0, arg1));
};
imports.wbg.__wbindgen_number_new = function(arg0) {
var ret = arg0;
return addHeapObject(ret);
@ -561,8 +561,8 @@ async function init(input) {
imports.wbg.__wbindgen_rethrow = function(arg0) {
throw takeObject(arg0);
};
imports.wbg.__wbindgen_closure_wrapper3460 = function(arg0, arg1, arg2) {
var ret = makeMutClosure(arg0, arg1, 850, __wbg_adapter_22);
imports.wbg.__wbindgen_closure_wrapper791 = function(arg0, arg1, arg2) {
var ret = makeMutClosure(arg0, arg1, 15, __wbg_adapter_22);
return addHeapObject(ret);
};

BIN
pkg/meli_bg.wasm

Loading…
Cancel
Save