OILSJAVA_DIR = java
endif
-bin_SCRIPTS = $(core_scripts) $(reporter_scripts) $(installautojs) @srcdir@/extras/eg_config @srcdir@/extras/fast-extract @srcdir@/extras/import/marc2are.pl @srcdir@/extras/import/marc2bre.pl @srcdir@/extras/import/marc2sre.pl @srcdir@/extras/import/parallel_pg_loader.pl $(supportscr)/marc_export
+gen_scripts = \
+ @srcdir@/extras/fast-extract \
+ @srcdir@/extras/import/marc2are.pl \
+ @srcdir@/extras/import/marc2bre.pl \
+ @srcdir@/extras/import/marc2sre.pl \
+ @srcdir@/extras/import/parallel_pg_loader.pl \
+ $(supportscr)/authority_control_fields.pl \
+ $(supportscr)/marc_export
+
+bin_SCRIPTS = $(core_scripts) $(gen_scripts) $(reporter_scripts) $(installautojs)
+
+CLEANFILES = $(gen_scripts)
+
data_DATA = $(core_data) $(reporter_data)
# Take care of which subdirectories to build, and which extra files to include in a distribution.
SUBDIRS = $(OILSCORE_DIRS) $(OILSWEB_DIR) $(OILSPYTHON_DIR) $(OILSJAVA_DIR)
-EXTRA_DIST = @srcdir@/perlmods @srcdir@/templates @top_srcdir@/Open-ILS/xsl @srcdir@/cgi-bin
+EXTRA_DIST = @srcdir@/perlmods \
+ @srcdir@/templates \
+ @top_srcdir@/Open-ILS/xsl \
+ @srcdir@/cgi-bin \
+ $(gen_scripts) \
+ @srcdir@/extras/eg_config
+
+do_subst = $(SED) \
+ -e 's,[@]bindir[@],$(bindir),g' \
+ -e 's,[@]datarootdir[@],$(datarootdir),g' \
+ -e 's,[@]docdir[@],$(docdir),g' \
+ -e 's,[@]exec_prefix[@],$(exec_prefix),g' \
+ -e 's,[@]includedir[@],$(includedir),g' \
+ -e 's,[@]libdir[@],$(libdir),g' \
+ -e 's,[@]prefix[@],$(prefix),g' \
+ -e 's,[@]sysconfdir[@],$(sysconfdir),g'
# Install header files
rm -R $(XSLDIR)
rm -R $(CGIDIR)
+@srcdir@/extras/fast-extract: @srcdir@/extras/fast-extract.in
+ $(do_subst) "$<" > "$@"
+ chmod 755 "$@"
+
+@srcdir@/extras/import/marc2are.pl: @srcdir@/extras/import/marc2are.pl.in
+ $(do_subst) "$<" > "$@"
+ chmod 755 "$@"
+
+@srcdir@/extras/import/marc2bre.pl: @srcdir@/extras/import/marc2bre.pl.in
+ $(do_subst) "$<" > "$@"
+ chmod 755 "$@"
+
+@srcdir@/extras/import/marc2sre.pl: @srcdir@/extras/import/marc2sre.pl.in
+ $(do_subst) "$<" > "$@"
+ chmod 755 "$@"
+
+@srcdir@/extras/import/parallel_pg_loader.pl: @srcdir@/extras/import/parallel_pg_loader.pl.in
+ $(do_subst) "$<" > "$@"
+ chmod 755 "$@"
+
+$(supportscr)/authority_control_fields.pl: $(supportscr)/authority_control_fields.pl.in
+ $(do_subst) "$<" > "$@"
+ chmod 755 "$@"
+
+$(supportscr)/marc_export: $(supportscr)/marc_export.in
+ $(do_subst) "$<" > "$@"
+ chmod 755 "$@"
#perl-install and string-templates-install
ilscore-install:
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
-CLEANFILES = Build
+bin_SCRIPTS = Build lib/OpenILS/Utils/Cronscript.pm
+
+CLEANFILES = $(bin_SCRIPTS)
+
DISTCLEANFILES = Makefile.in Makefile
+do_subst = $(SED) -e 's,[@]sysconfdir@,$(sysconfdir),g'
+
all: build-perl
./Build || make -s build-perl-fail
install: build-perl
./Build install
-build-perl:
+build-perl: lib/OpenILS/Utils/Cronscript.pm
perl Build.PL --destdir $(DESTDIR) || make -s build-perl-fail
+lib/OpenILS/Utils/Cronscript.pm: lib/OpenILS/Utils/Cronscript.pm.in
+ $(do_subst) "$<" > "$@"
+
build-perl-fail:
echo
echo ">>> Build/test of Perl modules has failed. The most likely"
AC_CONFIG_FILES([Makefile
Open-ILS/src/Makefile
+ Open-ILS/src/perlmods/Makefile
Open-ILS/web/Makefile
Open-ILS/updates/Makefile
Open-ILS/xul/staff_client/Makefile
Open-ILS/src/extras/eg_config
- Open-ILS/src/extras/fast-extract
- Open-ILS/src/extras/import/marc2are.pl
- Open-ILS/src/extras/import/marc2bre.pl
- Open-ILS/src/extras/import/marc2sre.pl
- Open-ILS/src/extras/import/parallel_pg_loader.pl
- Open-ILS/src/support-scripts/authority_control_fields.pl
- Open-ILS/src/support-scripts/marc_export
- Open-ILS/src/perlmods/Makefile
- Open-ILS/src/perlmods/lib/OpenILS/Utils/Cronscript.pm],
+ ],
[
if test -e "./Open-ILS/src/extras/eg_config"; then chmod 755 Open-ILS/src/extras/eg_config; fi;
- if test -e "./Open-ILS/src/extras/fast-extract"; then chmod 755 Open-ILS/src/extras/fast-extract; fi;
- if test -e "./Open-ILS/src/extras/import/marc2are.pl"; then chmod 755 Open-ILS/src/extras/import/marc2are.pl; fi;
- if test -e "./Open-ILS/src/extras/import/marc2bre.pl"; then chmod 755 Open-ILS/src/extras/import/marc2bre.pl; fi;
- if test -e "./Open-ILS/src/extras/import/marc2sre.pl"; then chmod 755 Open-ILS/src/extras/import/marc2sre.pl; fi;
- if test -e "./Open-ILS/src/extras/import/parallel_pg_loader.pl"; then chmod 755 Open-ILS/src/extras/import/parallel_pg_loader.pl; fi;
- if test -e "./Open-ILS/src/support-scripts/authority_control_fields.pl"; then chmod 755 Open-ILS/src/support-scripts/authority_control_fields.pl; fi;
- if test -e "./Open-ILS/src/support-scripts/marc_export"; then chmod 755 Open-ILS/src/support-scripts/marc_export; fi;
])
AC_OUTPUT