-
-
Notifications
You must be signed in to change notification settings - Fork 116
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
9 changed files
with
91 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
MAKE = make | ||
RUBY = ruby | ||
PERL = /usr/bin/perl | ||
DESTDIR = | ||
PREFIX = /usr/local | ||
PERL_OPTIMIZE = -O2 -g -Wall | ||
|
||
all: configure build test | ||
configure: configure-ruby configure-perl | ||
build: build-java build-perl build-ruby | ||
test: test-java test-perl test-ruby | ||
install: install-ruby install-perl | ||
clean: distclean | ||
|
||
configure-perl: | ||
cd perl && perl Makefile.PL INSTALLDIRS=vendor | ||
|
||
configure-ruby: | ||
$(RUBY) -C ruby extconf.rb | ||
|
||
build-java: | ||
$(MAKE) -C java/ jar jar-symlink jni javadoc | ||
|
||
build-perl: | ||
$(MAKE) -C perl OPTIMIZE="$(PERL_OPTIMIZE)" | ||
|
||
build-ruby: | ||
$(MAKE) -C ruby | ||
|
||
test-java: | ||
$(MAKE) -C java test | ||
|
||
test-perl: | ||
$(MAKE) -C perl test | ||
|
||
test-ruby: | ||
$(RUBY) -C ruby test_rhash.rb | ||
|
||
install-ruby: | ||
$(MAKE) -C ruby install DESTDIR=$(DESTDIR) sitedir=$(DESTDIR)/usr/lib/ruby | ||
|
||
install-perl: | ||
$(MAKE) -C perl install DESTDIR=$(DESTDIR) | ||
# $(MAKE) -C perl install DESTDIR=$(DESTDIR) PREFIX=$(PREFIX) SITEPREFIX=$(PREFIX) | ||
|
||
distclean: | ||
$(MAKE) -C java distclean | ||
[ ! -f ruby/Makefile ] || $(MAKE) -C ruby distclean | ||
[ ! -f perl/Makefile ] || $(MAKE) -C perl distclean |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
Makefile.PL | ||
Rhash.pm | ||
Rhash.xs | ||
t/1test_hash_calculation.t | ||
t/2test_static_functions.t | ||
t/3test_all_hash_functions.t | ||
typemap |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,21 @@ | ||
use strict; | ||
use warnings; | ||
|
||
use ExtUtils::MakeMaker; | ||
|
||
my $libs = '-lrhash'; | ||
my $inc = ''; | ||
$inc = $ENV{'LIBRHASH_INC'} if defined($ENV{'LIBRHASH_INC'}); | ||
if(defined($ENV{'LIBRHASH_LD'}) && $ENV{'LIBRHASH_LD'} =~ /^-L/) { | ||
$libs = $ENV{'LIBRHASH_LD'} . ' ' . $libs; | ||
} | ||
|
||
# See lib/ExtUtils/MakeMaker.pm for details of how to influence | ||
# the contents of the Makefile that is written. | ||
WriteMakefile( | ||
NAME => 'Rhash', | ||
AUTHOR => 'Aleksey Kravchenko', | ||
AUTHOR => 'Aleksey Kravchenko', | ||
VERSION_FROM => 'Rhash.pm', # finds $VERSION | ||
LIBS => ['-lrhash'], | ||
DEFINE => '', # e.g., '-DHAVE_SOMETHING' | ||
INC => '', # e.g., '-I/usr/include/other' | ||
LIBS => [ $libs ], | ||
DEFINE => '', # e.g., '-DHAVE_SOMETHING' | ||
INC => $inc, # e.g., '-I/usr/include/other' | ||
); | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters