digest-keccak 0.0.1 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 741d7a0fd94a8c75fbeceba4ada1c54fadb045714f4a0bbc0bf43726d3d296a4
4
- data.tar.gz: c046ffbbfe673a91c2701975f2a612863d20f56f10bf4763c3f759b604da5fcc
3
+ metadata.gz: be41a80355a83e17a0796c072fdcf02132b13e7806be4d65f8d627cdb864334f
4
+ data.tar.gz: 1c10017cb44868e19e114e474d8c0c95f5b8382e40a8f908ed9ff4d9476c5a4f
5
5
  SHA512:
6
- metadata.gz: 71e62b2f189ad0e36e91bf11872f6178b0f9c1dc50d520b96028d163ec6e675187437f6f508e64a88dd1ea4ae48812a6d4934bc4b4a49863bfac378f34972195
7
- data.tar.gz: cd4beef3df2ab346c6f1253e06bc99e534b30109ef13d0356cb77c09e837678b1525a45ed1aba57633dacd698a91c6feae395ee0467225a09c2eb325dc50ea8e
6
+ metadata.gz: 0a62c8ad6465eb29559cedad4e075f0c0b3a615db2504901915f3f86141d1654ebbbe505677ee2a77616cb3622613601676fb87df88a73d3c50cd1b56633550e
7
+ data.tar.gz: 9f88f994b8dce962d43ef4d1d2b6b53a7d0c821eb78b42c82002036bf234faa8c09a84b5156e09658006505f392b1059444b5f728ed9ddacf36bbc4a345657d5
@@ -43,4 +43,7 @@ Gem::Specification.new do |spec|
43
43
  spec.executables = spec.files.grep %r{^exe/}, &File.method(:basename)
44
44
 
45
45
  spec.extensions << 'ext/digest/extconf.rb'
46
+
47
+ spec.add_development_dependency 'bundler', '~> 2.0'
48
+ spec.add_development_dependency 'rake', '~> 10.0'
46
49
  end
@@ -1,9 +1,31 @@
1
+ #!/usr/bin/env ruby
1
2
  # frozen_string_literal: true
2
3
 
3
4
  require 'mkmf'
4
5
 
5
- have_header('ruby/digest.h')
6
- have_func('rb_str_set_len')
6
+ def cflags(*args)
7
+ args.each do |str|
8
+ $CFLAGS += " #{str.shellescape} "
9
+ end
10
+ end
7
11
 
8
- $CFLAGS << " -fvisibility=hidden"
9
- create_makefile('digest/keccak')
12
+ def have_header!(*args)
13
+ exit 1 unless have_header(*args)
14
+ end
15
+
16
+ def have_func!(header, *args)
17
+ exit 1 unless have_func(*args, header)
18
+ end
19
+
20
+ cflags '-std=c11'
21
+ cflags '-Wall'
22
+ cflags '-Wextra'
23
+ cflags '-fvisibility=hidden'
24
+
25
+ have_header! 'ruby/digest.h'
26
+ have_header! 'stdio.h'
27
+ have_header! 'string.h'
28
+
29
+ have_func! 'rb_str_set_len'
30
+
31
+ create_makefile 'digest/keccak' or exit 1
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Digest
4
4
  class Keccak
5
- VERSION = '0.0.1'
5
+ VERSION = '0.0.2'
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: digest-keccak
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Hongli Lai (Phusion)
@@ -9,8 +9,36 @@ authors:
9
9
  autorequire:
10
10
  bindir: exe
11
11
  cert_chain: []
12
- date: 2019-06-08 00:00:00.000000000 Z
13
- dependencies: []
12
+ date: 2019-06-13 00:00:00.000000000 Z
13
+ dependencies:
14
+ - !ruby/object:Gem::Dependency
15
+ name: bundler
16
+ requirement: !ruby/object:Gem::Requirement
17
+ requirements:
18
+ - - "~>"
19
+ - !ruby/object:Gem::Version
20
+ version: '2.0'
21
+ type: :development
22
+ prerelease: false
23
+ version_requirements: !ruby/object:Gem::Requirement
24
+ requirements:
25
+ - - "~>"
26
+ - !ruby/object:Gem::Version
27
+ version: '2.0'
28
+ - !ruby/object:Gem::Dependency
29
+ name: rake
30
+ requirement: !ruby/object:Gem::Requirement
31
+ requirements:
32
+ - - "~>"
33
+ - !ruby/object:Gem::Version
34
+ version: '10.0'
35
+ type: :development
36
+ prerelease: false
37
+ version_requirements: !ruby/object:Gem::Requirement
38
+ requirements:
39
+ - - "~>"
40
+ - !ruby/object:Gem::Version
41
+ version: '10.0'
14
42
  description: The Keccak (draft version of SHA-3) cryptographic hash function.
15
43
  email:
16
44
  - software-signing@phusion.nl