aboutsummaryrefslogtreecommitdiff
path: root/graphics/ocrad
diff options
context:
space:
mode:
authorYuri Victorovich <yuri@FreeBSD.org>2018-05-22 04:46:00 +0000
committerYuri Victorovich <yuri@FreeBSD.org>2018-05-22 04:46:00 +0000
commit68ec769804ab433b84a48ef4a510587a0a3178a0 (patch)
tree054e6762b00779e2b7c23991009ae53ebfe962ab /graphics/ocrad
parentb737fbea8806b2aa14acdfb12ac9857013f98eb4 (diff)
downloadports-68ec769804ab433b84a48ef4a510587a0a3178a0.tar.gz
ports-68ec769804ab433b84a48ef4a510587a0a3178a0.zip
graphics/ocrad: Install the header and the library
Port changes: * Take maintainership * Remove do-install because project's makefile installs files fine * Adjust CONFIGURE_ARGS for man/info paths * Add USE_LDCONFIG * Remove MKDIR where it is not needed * Unsilence the install command
Notes
Notes: svn path=/head/; revision=470593
Diffstat (limited to 'graphics/ocrad')
-rw-r--r--graphics/ocrad/Makefile25
-rw-r--r--graphics/ocrad/files/patch-Makefile.in33
-rw-r--r--graphics/ocrad/pkg-descr2
3 files changed, 47 insertions, 13 deletions
diff --git a/graphics/ocrad/Makefile b/graphics/ocrad/Makefile
index d8c141383b3d..ae415e2e553c 100644
--- a/graphics/ocrad/Makefile
+++ b/graphics/ocrad/Makefile
@@ -3,36 +3,37 @@
PORTNAME= ocrad
PORTVERSION= 0.26
+PORTREVISION= 1
CATEGORIES= graphics
MASTER_SITES= GNU
EXTRACT_SUFX= .tar.lz
-MAINTAINER= ports@FreeBSD.org
+MAINTAINER= yuri@FreeBSD.org
COMMENT= OCR program implemented as filter
LICENSE= GPLv3
LICENSE_FILE= ${WRKSRC}/COPYING
HAS_CONFIGURE= yes
-CONFIGURE_ARGS= --prefix=${PREFIX} CXX="${CXX}" CXXFLAGS="${CXXFLAGS}"
+CONFIGURE_ARGS= --prefix=${PREFIX} CXX="${CXX}" CXXFLAGS="${CXXFLAGS} -fPIC" --mandir=${PREFIX}/man --infodir=${PREFIX}/info
+USE_LDCONFIG= yes
-PORTDOCS= AUTHORS ChangeLog NEWS README
-PORTEXAMPLES= *
-PLIST_FILES= bin/${PORTNAME} man/man1/ocrad.1.gz
+PLIST_FILES= bin/${PORTNAME} \
+ include/ocradlib.h \
+ lib/libocrad.so \
+ man/man1/ocrad.1.gz \
+ info/ocrad.info
OPTIONS_DEFINE= DOCS EXAMPLES
-do-install:
- ${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${STAGEDIR}${PREFIX}/bin
- ${INSTALL_MAN} ${WRKSRC}/doc/ocrad.1 ${STAGEDIR}${MAN1PREFIX}/man/man1
+PORTDOCS= AUTHORS ChangeLog NEWS README
+PORTEXAMPLES= *
post-install-DOCS-on:
@${MKDIR} ${STAGEDIR}${DOCSDIR}
- (cd ${WRKSRC} && ${INSTALL_DATA} ${PORTDOCS} \
- ${STAGEDIR}${DOCSDIR})
+ cd ${WRKSRC} && ${INSTALL_DATA} ${PORTDOCS} ${STAGEDIR}${DOCSDIR}
post-install-EXAMPLES-on:
- @${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
- @(cd ${WRKSRC}/testsuite && ${COPYTREE_SHARE} . ${STAGEDIR}${EXAMPLESDIR})
+ cd ${WRKSRC}/testsuite && ${COPYTREE_SHARE} . ${STAGEDIR}${EXAMPLESDIR}
.include <bsd.port.mk>
diff --git a/graphics/ocrad/files/patch-Makefile.in b/graphics/ocrad/files/patch-Makefile.in
new file mode 100644
index 000000000000..23a3ac19c8ba
--- /dev/null
+++ b/graphics/ocrad/files/patch-Makefile.in
@@ -0,0 +1,33 @@
+--- Makefile.in.orig 2018-05-22 03:44:46 UTC
++++ Makefile.in
+@@ -23,16 +23,16 @@ objs = arg_parser.o main.o
+ uninstall uninstall-bin uninstall-info uninstall-man \
+ doc info man check dist clean distclean
+
+-all : $(progname) lib$(libname).a
++all : $(progname) lib$(libname).so
+
+-lib$(libname).a: $(ocr_objs) $(lib_objs)
+- $(AR) -rcs $@ $(ocr_objs) $(lib_objs)
++lib$(libname).so: $(ocr_objs) $(lib_objs)
++ $(CXX) -shared -fPIC -o $@ $(ocr_objs) $(lib_objs)
+
+ $(progname) : $(ocr_objs) $(objs)
+ $(CXX) $(LDFLAGS) $(CXXFLAGS) -o $@ $(ocr_objs) $(objs)
+
+-ocradcheck : ocradcheck.o lib$(libname).a
+- $(CXX) $(LDFLAGS) $(CXXFLAGS) -o $@ ocradcheck.o lib$(libname).a
++ocradcheck : ocradcheck.o lib$(libname).so
++ $(CXX) $(LDFLAGS) $(CXXFLAGS) -o $@ ocradcheck.o lib$(libname).so
+
+ ocradcheck.o : ocradcheck.cc
+ $(CXX) $(CPPFLAGS) $(CXXFLAGS) -DPROGVERSION=\"$(pkgversion)\" -c -o $@ $<
+@@ -101,7 +101,7 @@ install-bin : all
+ if [ ! -d "$(DESTDIR)$(libdir)" ] ; then $(INSTALL_DIR) "$(DESTDIR)$(libdir)" ; fi
+ $(INSTALL_PROGRAM) ./$(progname) "$(DESTDIR)$(bindir)/$(progname)"
+ $(INSTALL_DATA) $(VPATH)/$(libname)lib.h "$(DESTDIR)$(includedir)/$(libname)lib.h"
+- $(INSTALL_DATA) ./lib$(libname).a "$(DESTDIR)$(libdir)/lib$(libname).a"
++ $(INSTALL_DATA) ./lib$(libname).so "$(DESTDIR)$(libdir)/lib$(libname).so"
+
+ install-bin-strip : all
+ $(MAKE) INSTALL_PROGRAM='$(INSTALL_PROGRAM) -s' install-bin
diff --git a/graphics/ocrad/pkg-descr b/graphics/ocrad/pkg-descr
index 844adfc1ce83..62b620816f10 100644
--- a/graphics/ocrad/pkg-descr
+++ b/graphics/ocrad/pkg-descr
@@ -6,4 +6,4 @@ of text normally found on printed pages.
It can be used as a stand-alone console application, or as a backend to
other programs.
-WWW: http://www.gnu.org/software/ocrad/ocrad.html
+WWW: https://www.gnu.org/software/ocrad/ocrad.html