parity-ethereum: rename crate 🌵
This commit is contained in:
		
							parent
							
								
									f2a23fcb22
								
							
						
					
					
						commit
						8a698d6fb0
					
				
							
								
								
									
										114
									
								
								Cargo.lock
									
									
									
										generated
									
									
									
								
							
							
						
						
									
										114
									
								
								Cargo.lock
									
									
									
										generated
									
									
									
								
							| @ -2052,7 +2052,63 @@ dependencies = [ | |||||||
| ] | ] | ||||||
| 
 | 
 | ||||||
| [[package]] | [[package]] | ||||||
| name = "parity" | name = "parity-clib" | ||||||
|  | version = "1.12.0" | ||||||
|  | dependencies = [ | ||||||
|  |  "parity-ethereum 2.0.0", | ||||||
|  | ] | ||||||
|  | 
 | ||||||
|  | [[package]] | ||||||
|  | name = "parity-dapps" | ||||||
|  | version = "1.12.0" | ||||||
|  | dependencies = [ | ||||||
|  |  "base32 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
|  |  "env_logger 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
|  |  "ethcore-bytes 0.1.0", | ||||||
|  |  "ethcore-devtools 1.12.0", | ||||||
|  |  "ethereum-types 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
|  |  "fetch 0.1.0", | ||||||
|  |  "futures 0.1.21 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
|  |  "futures-cpupool 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
|  |  "itertools 0.5.10 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
|  |  "jsonrpc-core 8.0.1 (git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.11)", | ||||||
|  |  "jsonrpc-http-server 8.0.0 (git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.11)", | ||||||
|  |  "keccak-hash 0.1.2", | ||||||
|  |  "linked-hash-map 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
|  |  "log 0.3.9 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
|  |  "mime_guess 2.0.0-alpha.2 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
|  |  "node-health 0.1.0", | ||||||
|  |  "parity-dapps-glue 1.9.1", | ||||||
|  |  "parity-hash-fetch 1.12.0", | ||||||
|  |  "parity-reactor 0.1.0", | ||||||
|  |  "parity-version 2.0.0", | ||||||
|  |  "parking_lot 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
|  |  "rand 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
|  |  "registrar 0.0.1", | ||||||
|  |  "rustc-hex 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
|  |  "serde 1.0.37 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
|  |  "serde_derive 1.0.37 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
|  |  "serde_json 1.0.9 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
|  |  "unicase 1.4.2 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
|  |  "zip 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
|  | ] | ||||||
|  | 
 | ||||||
|  | [[package]] | ||||||
|  | name = "parity-dapps-glue" | ||||||
|  | version = "1.9.1" | ||||||
|  | dependencies = [ | ||||||
|  |  "aster 0.41.0 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
|  |  "glob 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
|  |  "mime_guess 2.0.0-alpha.2 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
|  |  "quasi 0.32.0 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
|  |  "quasi_codegen 0.32.0 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
|  |  "quasi_macros 0.32.0 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
|  |  "syntex 0.58.1 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
|  |  "syntex_syntax 0.58.1 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
|  | ] | ||||||
|  | 
 | ||||||
|  | [[package]] | ||||||
|  | name = "parity-ethereum" | ||||||
| version = "2.0.0" | version = "2.0.0" | ||||||
| dependencies = [ | dependencies = [ | ||||||
|  "ansi_term 0.10.2 (registry+https://github.com/rust-lang/crates.io-index)", |  "ansi_term 0.10.2 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
| @ -2127,62 +2183,6 @@ dependencies = [ | |||||||
|  "winapi 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)", |  "winapi 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)", | ||||||
| ] | ] | ||||||
| 
 | 
 | ||||||
| [[package]] |  | ||||||
| name = "parity-clib" |  | ||||||
| version = "1.12.0" |  | ||||||
| dependencies = [ |  | ||||||
|  "parity 2.0.0", |  | ||||||
| ] |  | ||||||
| 
 |  | ||||||
| [[package]] |  | ||||||
| name = "parity-dapps" |  | ||||||
| version = "1.12.0" |  | ||||||
| dependencies = [ |  | ||||||
|  "base32 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", |  | ||||||
|  "env_logger 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)", |  | ||||||
|  "ethcore-bytes 0.1.0", |  | ||||||
|  "ethcore-devtools 1.12.0", |  | ||||||
|  "ethereum-types 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)", |  | ||||||
|  "fetch 0.1.0", |  | ||||||
|  "futures 0.1.21 (registry+https://github.com/rust-lang/crates.io-index)", |  | ||||||
|  "futures-cpupool 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", |  | ||||||
|  "itertools 0.5.10 (registry+https://github.com/rust-lang/crates.io-index)", |  | ||||||
|  "jsonrpc-core 8.0.1 (git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.11)", |  | ||||||
|  "jsonrpc-http-server 8.0.0 (git+https://github.com/paritytech/jsonrpc.git?branch=parity-1.11)", |  | ||||||
|  "keccak-hash 0.1.2", |  | ||||||
|  "linked-hash-map 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)", |  | ||||||
|  "log 0.3.9 (registry+https://github.com/rust-lang/crates.io-index)", |  | ||||||
|  "mime_guess 2.0.0-alpha.2 (registry+https://github.com/rust-lang/crates.io-index)", |  | ||||||
|  "node-health 0.1.0", |  | ||||||
|  "parity-dapps-glue 1.9.1", |  | ||||||
|  "parity-hash-fetch 1.12.0", |  | ||||||
|  "parity-reactor 0.1.0", |  | ||||||
|  "parity-version 2.0.0", |  | ||||||
|  "parking_lot 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)", |  | ||||||
|  "rand 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)", |  | ||||||
|  "registrar 0.0.1", |  | ||||||
|  "rustc-hex 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)", |  | ||||||
|  "serde 1.0.37 (registry+https://github.com/rust-lang/crates.io-index)", |  | ||||||
|  "serde_derive 1.0.37 (registry+https://github.com/rust-lang/crates.io-index)", |  | ||||||
|  "serde_json 1.0.9 (registry+https://github.com/rust-lang/crates.io-index)", |  | ||||||
|  "unicase 1.4.2 (registry+https://github.com/rust-lang/crates.io-index)", |  | ||||||
|  "zip 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", |  | ||||||
| ] |  | ||||||
| 
 |  | ||||||
| [[package]] |  | ||||||
| name = "parity-dapps-glue" |  | ||||||
| version = "1.9.1" |  | ||||||
| dependencies = [ |  | ||||||
|  "aster 0.41.0 (registry+https://github.com/rust-lang/crates.io-index)", |  | ||||||
|  "glob 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)", |  | ||||||
|  "mime_guess 2.0.0-alpha.2 (registry+https://github.com/rust-lang/crates.io-index)", |  | ||||||
|  "quasi 0.32.0 (registry+https://github.com/rust-lang/crates.io-index)", |  | ||||||
|  "quasi_codegen 0.32.0 (registry+https://github.com/rust-lang/crates.io-index)", |  | ||||||
|  "quasi_macros 0.32.0 (registry+https://github.com/rust-lang/crates.io-index)", |  | ||||||
|  "syntex 0.58.1 (registry+https://github.com/rust-lang/crates.io-index)", |  | ||||||
|  "syntex_syntax 0.58.1 (registry+https://github.com/rust-lang/crates.io-index)", |  | ||||||
| ] |  | ||||||
| 
 |  | ||||||
| [[package]] | [[package]] | ||||||
| name = "parity-hash-fetch" | name = "parity-hash-fetch" | ||||||
| version = "1.12.0" | version = "1.12.0" | ||||||
|  | |||||||
| @ -1,6 +1,6 @@ | |||||||
| [package] | [package] | ||||||
| description = "Parity Ethereum client" | description = "Parity Ethereum client" | ||||||
| name = "parity" | name = "parity-ethereum" | ||||||
| # NOTE Make sure to update util/version/Cargo.toml as well | # NOTE Make sure to update util/version/Cargo.toml as well | ||||||
| version = "2.0.0" | version = "2.0.0" | ||||||
| license = "GPL-3.0" | license = "GPL-3.0" | ||||||
|  | |||||||
| @ -10,8 +10,8 @@ name = "parity" | |||||||
| crate-type = ["cdylib", "staticlib"] | crate-type = ["cdylib", "staticlib"] | ||||||
| 
 | 
 | ||||||
| [dependencies] | [dependencies] | ||||||
| parity = { path = "../", default-features = false } | parity-ethereum = { path = "../", default-features = false } | ||||||
| 
 | 
 | ||||||
| [features] | [features] | ||||||
| default = [] | default = [] | ||||||
| final = ["parity/final"] | final = ["parity-ethereum/final"] | ||||||
|  | |||||||
| @ -17,7 +17,7 @@ | |||||||
| //! Note that all the structs and functions here are documented in `parity.h`, to avoid
 | //! Note that all the structs and functions here are documented in `parity.h`, to avoid
 | ||||||
| //! duplicating documentation.
 | //! duplicating documentation.
 | ||||||
| 
 | 
 | ||||||
| extern crate parity; | extern crate parity_ethereum; | ||||||
| 
 | 
 | ||||||
| use std::os::raw::{c_char, c_void, c_int}; | use std::os::raw::{c_char, c_void, c_int}; | ||||||
| use std::panic; | use std::panic; | ||||||
| @ -56,7 +56,7 @@ pub extern fn parity_config_from_cli(args: *const *const c_char, args_lens: *con | |||||||
| 				args | 				args | ||||||
| 			}; | 			}; | ||||||
| 
 | 
 | ||||||
| 			match parity::Configuration::parse_cli(&args) { | 			match parity_ethereum::Configuration::parse_cli(&args) { | ||||||
| 				Ok(mut cfg) => { | 				Ok(mut cfg) => { | ||||||
| 					// Always disable the auto-updater when used as a library.
 | 					// Always disable the auto-updater when used as a library.
 | ||||||
| 					cfg.args.arg_auto_update = "none".to_owned(); | 					cfg.args.arg_auto_update = "none".to_owned(); | ||||||
| @ -77,7 +77,7 @@ pub extern fn parity_config_from_cli(args: *const *const c_char, args_lens: *con | |||||||
| pub extern fn parity_config_destroy(cfg: *mut c_void) { | pub extern fn parity_config_destroy(cfg: *mut c_void) { | ||||||
| 	unsafe { | 	unsafe { | ||||||
| 		let _ = panic::catch_unwind(|| { | 		let _ = panic::catch_unwind(|| { | ||||||
| 			let _cfg = Box::from_raw(cfg as *mut parity::Configuration); | 			let _cfg = Box::from_raw(cfg as *mut parity_ethereum::Configuration); | ||||||
| 		}); | 		}); | ||||||
| 	} | 	} | ||||||
| } | } | ||||||
| @ -89,7 +89,7 @@ pub extern fn parity_start(cfg: *const ParityParams, output: *mut *mut c_void) - | |||||||
| 			*output = ptr::null_mut(); | 			*output = ptr::null_mut(); | ||||||
| 			let cfg: &ParityParams = &*cfg; | 			let cfg: &ParityParams = &*cfg; | ||||||
| 
 | 
 | ||||||
| 			let config = Box::from_raw(cfg.configuration as *mut parity::Configuration); | 			let config = Box::from_raw(cfg.configuration as *mut parity_ethereum::Configuration); | ||||||
| 
 | 
 | ||||||
| 			let on_client_restart_cb = { | 			let on_client_restart_cb = { | ||||||
| 				struct Cb(Option<extern "C" fn(*mut c_void, *const c_char, usize)>, *mut c_void); | 				struct Cb(Option<extern "C" fn(*mut c_void, *const c_char, usize)>, *mut c_void); | ||||||
| @ -106,16 +106,16 @@ pub extern fn parity_start(cfg: *const ParityParams, output: *mut *mut c_void) - | |||||||
| 				move |new_chain: String| { cb.call(new_chain); } | 				move |new_chain: String| { cb.call(new_chain); } | ||||||
| 			}; | 			}; | ||||||
| 
 | 
 | ||||||
| 			let action = match parity::start(*config, on_client_restart_cb, || {}) { | 			let action = match parity_ethereum::start(*config, on_client_restart_cb, || {}) { | ||||||
| 				Ok(action) => action, | 				Ok(action) => action, | ||||||
| 				Err(_) => return 1, | 				Err(_) => return 1, | ||||||
| 			}; | 			}; | ||||||
| 
 | 
 | ||||||
| 			match action { | 			match action { | ||||||
| 				parity::ExecutionAction::Instant(Some(s)) => { println!("{}", s); 0 }, | 				parity_ethereum::ExecutionAction::Instant(Some(s)) => { println!("{}", s); 0 }, | ||||||
| 				parity::ExecutionAction::Instant(None) => 0, | 				parity_ethereum::ExecutionAction::Instant(None) => 0, | ||||||
| 				parity::ExecutionAction::Running(client) => { | 				parity_ethereum::ExecutionAction::Running(client) => { | ||||||
| 					*output = Box::into_raw(Box::<parity::RunningClient>::new(client)) as *mut c_void; | 					*output = Box::into_raw(Box::<parity_ethereum::RunningClient>::new(client)) as *mut c_void; | ||||||
| 					0 | 					0 | ||||||
| 				} | 				} | ||||||
| 			} | 			} | ||||||
| @ -127,7 +127,7 @@ pub extern fn parity_start(cfg: *const ParityParams, output: *mut *mut c_void) - | |||||||
| pub extern fn parity_destroy(client: *mut c_void) { | pub extern fn parity_destroy(client: *mut c_void) { | ||||||
| 	unsafe { | 	unsafe { | ||||||
| 		let _ = panic::catch_unwind(|| { | 		let _ = panic::catch_unwind(|| { | ||||||
| 			let client = Box::from_raw(client as *mut parity::RunningClient); | 			let client = Box::from_raw(client as *mut parity_ethereum::RunningClient); | ||||||
| 			client.shutdown(); | 			client.shutdown(); | ||||||
| 		}); | 		}); | ||||||
| 	} | 	} | ||||||
| @ -137,7 +137,7 @@ pub extern fn parity_destroy(client: *mut c_void) { | |||||||
| pub extern fn parity_rpc(client: *mut c_void, query: *const char, len: usize, out_str: *mut c_char, out_len: *mut usize) -> c_int { | pub extern fn parity_rpc(client: *mut c_void, query: *const char, len: usize, out_str: *mut c_char, out_len: *mut usize) -> c_int { | ||||||
| 	unsafe { | 	unsafe { | ||||||
| 		panic::catch_unwind(|| { | 		panic::catch_unwind(|| { | ||||||
| 			let client: &mut parity::RunningClient = &mut *(client as *mut parity::RunningClient); | 			let client: &mut parity_ethereum::RunningClient = &mut *(client as *mut parity_ethereum::RunningClient); | ||||||
| 
 | 
 | ||||||
| 			let query_str = { | 			let query_str = { | ||||||
| 				let string = slice::from_raw_parts(query as *const u8, len); | 				let string = slice::from_raw_parts(query as *const u8, len); | ||||||
|  | |||||||
| @ -103,7 +103,7 @@ impl Configuration { | |||||||
| 	/// # Example
 | 	/// # Example
 | ||||||
| 	///
 | 	///
 | ||||||
| 	/// ```
 | 	/// ```
 | ||||||
| 	/// let _cfg = parity::Configuration::parse_cli(&["--light", "--chain", "koven"]).unwrap();
 | 	/// let _cfg = parity_ethereum::Configuration::parse_cli(&["--light", "--chain", "koven"]).unwrap();
 | ||||||
| 	/// ```
 | 	/// ```
 | ||||||
| 	pub fn parse_cli<S: AsRef<str>>(command: &[S]) -> Result<Self, ArgsError> { | 	pub fn parse_cli<S: AsRef<str>>(command: &[S]) -> Result<Self, ArgsError> { | ||||||
| 		let config = Configuration { | 		let config = Configuration { | ||||||
|  | |||||||
| @ -18,7 +18,7 @@ | |||||||
| 
 | 
 | ||||||
| #![warn(missing_docs)] | #![warn(missing_docs)] | ||||||
| 
 | 
 | ||||||
| extern crate parity; | extern crate parity_ethereum; | ||||||
| 
 | 
 | ||||||
| extern crate ctrlc; | extern crate ctrlc; | ||||||
| extern crate dir; | extern crate dir; | ||||||
| @ -39,7 +39,7 @@ use std::sync::Arc; | |||||||
| use ctrlc::CtrlC; | use ctrlc::CtrlC; | ||||||
| use dir::default_hypervisor_path; | use dir::default_hypervisor_path; | ||||||
| use fdlimit::raise_fd_limit; | use fdlimit::raise_fd_limit; | ||||||
| use parity::{start, ExecutionAction}; | use parity_ethereum::{start, ExecutionAction}; | ||||||
| use parking_lot::{Condvar, Mutex}; | use parking_lot::{Condvar, Mutex}; | ||||||
| 
 | 
 | ||||||
| fn updates_path(name: &str) -> PathBuf { | fn updates_path(name: &str) -> PathBuf { | ||||||
| @ -133,7 +133,7 @@ fn main_direct(force_can_restart: bool) -> i32 { | |||||||
| 
 | 
 | ||||||
| 	let mut conf = { | 	let mut conf = { | ||||||
| 		let args = std::env::args().collect::<Vec<_>>(); | 		let args = std::env::args().collect::<Vec<_>>(); | ||||||
| 		parity::Configuration::parse_cli(&args).unwrap_or_else(|e| e.exit()) | 		parity_ethereum::Configuration::parse_cli(&args).unwrap_or_else(|e| e.exit()) | ||||||
| 	}; | 	}; | ||||||
| 
 | 
 | ||||||
| 	if let Some(spec_override) = take_spec_name_override() { | 	if let Some(spec_override) = take_spec_name_override() { | ||||||
|  | |||||||
| @ -54,7 +54,7 @@ pub fn version() -> String { | |||||||
| 	let sha3_dash = if sha3.is_empty() { "" } else { "-" }; | 	let sha3_dash = if sha3.is_empty() { "" } else { "-" }; | ||||||
| 	let commit_date = vergen::commit_date().replace("-", ""); | 	let commit_date = vergen::commit_date().replace("-", ""); | ||||||
| 	let date_dash = if commit_date.is_empty() { "" } else { "-" }; | 	let date_dash = if commit_date.is_empty() { "" } else { "-" }; | ||||||
| 	format!("Parity/v{}-{}{}{}{}{}/{}/rustc{}", env!("CARGO_PKG_VERSION"), THIS_TRACK, sha3_dash, sha3, date_dash, commit_date, platform(), generated::rustc_version()) | 	format!("Parity-Ethereum/v{}-{}{}{}{}{}/{}/rustc{}", env!("CARGO_PKG_VERSION"), THIS_TRACK, sha3_dash, sha3, date_dash, commit_date, platform(), generated::rustc_version()) | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| /// Get the standard version data for this software.
 | /// Get the standard version data for this software.
 | ||||||
| @ -65,7 +65,7 @@ pub fn version_data() -> Bytes { | |||||||
| 		(env!("CARGO_PKG_VERSION_MINOR").parse::<u32>().expect("Environment variables are known to be valid; qed") << 8) + | 		(env!("CARGO_PKG_VERSION_MINOR").parse::<u32>().expect("Environment variables are known to be valid; qed") << 8) + | ||||||
| 		env!("CARGO_PKG_VERSION_PATCH").parse::<u32>().expect("Environment variables are known to be valid; qed"); | 		env!("CARGO_PKG_VERSION_PATCH").parse::<u32>().expect("Environment variables are known to be valid; qed"); | ||||||
| 	s.append(&v); | 	s.append(&v); | ||||||
| 	s.append(&"Parity"); | 	s.append(&"Parity-Ethereum"); | ||||||
| 	s.append(&generated::rustc_version()); | 	s.append(&generated::rustc_version()); | ||||||
| 	s.append(&&Target::os()[0..2]); | 	s.append(&&Target::os()[0..2]); | ||||||
| 	s.out() | 	s.out() | ||||||
|  | |||||||
		Loading…
	
		Reference in New Issue
	
	Block a user