Drop Makefile.PL, simpler without.

This commit is contained in:
barnold 2022-10-15 14:35:53 +01:00
parent d15be010ad
commit fe1ae0a240
3 changed files with 18 additions and 20 deletions

22
INSTALL
View File

@ -63,26 +63,24 @@ as postgres, run
use any of the targets in Makefile.orig to create and load the catalog
database.
$ make -f Makefile.orig PGC_DANGEROUS=1 rebuild-db
$ make -f Makefile.orig load-catalog
$ make PGC_DANGEROUS=1 rebuild-db
$ make load-catalog
At this point, "irulan" should be able to run the tests successfully
with e.g.
$ prove -l
3. To install the perl modules, run (for example)
3. To install the perl modules, run
perl Makefile.PL INSTALL_BASE=~/.local
make test
make install
sudo make install-modules
4. To use these modules from your program, assuming the INSTALL_BASE
suggested above,
which installs under /usr/local/lib/site_perl. Alternatively do e.g.
declare -x PERL5LIB="$HOME/.local/lib/perl5"
make PGC_PERL5LIB=~/.local/lib/perl5 install-modules
and run your program (e.g. pgc-www,
<https://tildegit.org/barnold/pgc-www>).
though you'll probably need to set PER5LIB in this case before using
the modules in your perl code.
Comments and questions welcome at <barnold@tilde.club>.
<barnold@tilde.club>

View File

@ -1,4 +1,4 @@
.PHONY: dangerous drop-db rebuild-db
.PHONY: dangerous drop-db rebuild-db load-catalog install-modules
dangerous:
ifndef PGC_DANGEROUS
@ -18,6 +18,12 @@ rebuild-db: drop-db
--command="COMMIT;"
load-catalog:
psql --username="pgc_owner" pg_book_catalog \
psql --username="pgc_owner" pg_book_catalog \
--command="TRUNCATE TABLE book, author;"
bin/load-gutenberg.pl pg_catalog.csv
PGC_PERL5LIB ?= "/usr/local/lib/site_perl"
install-modules:
install --directory $(PGC_PERL5LIB)
cp --recursive lib/Book $(PGC_PERL5LIB)

View File

@ -1,6 +0,0 @@
use ExtUtils::MakeMaker;
WriteMakefile(
NAME => 'Book',
VERSION_FROM => 'lib/Book/Schema.pm'
);