Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
shasper
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Analyze
Contributor analytics
CI/CD analytics
Repository analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
parity
shasper
Commits
a3a260d4
Commit
a3a260d4
authored
6 years ago
by
Wei Tang
Browse files
Options
Downloads
Patches
Plain Diff
Checkin build mod
parent
ef192d30
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
build.rs
+31
-0
31 additions, 0 deletions
build.rs
with
31 additions
and
0 deletions
build.rs
0 → 100644
+
31
−
0
View file @
a3a260d4
// Copyright 2015-2018 Parity Technologies (UK) Ltd.
// This file is part of Substrate.
// Substrate is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
// Substrate is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
// You should have received a copy of the GNU General Public License
// along with Substrate. If not, see <http://www.gnu.org/licenses/>.
extern
crate
vergen
;
use
vergen
::{
ConstantsFlags
,
Vergen
};
const
ERROR_MSG
:
&
'static
str
=
"Failed to generate metadata files"
;
fn
main
()
{
let
vergen
=
Vergen
::
new
(
ConstantsFlags
::
all
())
.expect
(
ERROR_MSG
);
for
(
k
,
v
)
in
vergen
.build_info
()
{
println!
(
"cargo:rustc-env={}={}"
,
k
.name
(),
v
);
}
println!
(
"cargo:rerun-if-changed=.git/HEAD"
);
}
This diff is collapsed.
Click to expand it.
Preview
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment