]> git.ipfire.org Git - people/teissler/ipfire-2.x.git/commitdiff
mpage: New package.
authorMichael Tremer <michael.tremer@ipfire.org>
Thu, 24 Oct 2013 13:12:09 +0000 (15:12 +0200)
committerMichael Tremer <michael.tremer@ipfire.org>
Thu, 24 Oct 2013 13:20:48 +0000 (15:20 +0200)
Required for foomatic 4.x.

config/rootfiles/common/mpage [new file with mode: 0644]
lfs/mpage [new file with mode: 0644]
make.sh
src/patches/mpage25-config.patch [new file with mode: 0644]

diff --git a/config/rootfiles/common/mpage b/config/rootfiles/common/mpage
new file mode 100644 (file)
index 0000000..9df3083
--- /dev/null
@@ -0,0 +1,9 @@
+#usr/bin/mpage
+#usr/man/man1/mpage.1
+#usr/share/mpage
+#usr/share/mpage/CP850.PC
+#usr/share/mpage/ISO+STD+OTH
+#usr/share/mpage/ISO-8859.1
+#usr/share/mpage/ISO-8859.15
+#usr/share/mpage/ISO-Latin.1
+#usr/share/mpage/ISO-Latin.2
diff --git a/lfs/mpage b/lfs/mpage
new file mode 100644 (file)
index 0000000..b93fb06
--- /dev/null
+++ b/lfs/mpage
@@ -0,0 +1,77 @@
+###############################################################################
+#                                                                             #
+# IPFire.org - A linux based firewall                                         #
+# Copyright (C) 2007  Michael Tremer & Christian Schmidt                      #
+#                                                                             #
+# This program is free software: you can redistribute it and/or modify        #
+# it under the terms of the GNU General Public License as published by        #
+# the Free Software Foundation, either version 3 of the License, or           #
+# (at your option) any later version.                                         #
+#                                                                             #
+# This program is distributed in the hope that it will be useful,             #
+# but WITHOUT ANY WARRANTY; without even the implied warranty of              #
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the               #
+# GNU General Public License for more details.                                #
+#                                                                             #
+# You should have received a copy of the GNU General Public License           #
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.       #
+#                                                                             #
+###############################################################################
+
+###############################################################################
+# Definitions
+###############################################################################
+
+include Config
+
+VER        = 2.5.6
+
+THISAPP    = mpage-$(VER)
+DL_FILE    = $(THISAPP).tgz
+DL_FROM    = $(URL_IPFIRE)
+DIR_APP    = $(DIR_SRC)/$(THISAPP)
+TARGET     = $(DIR_INFO)/$(THISAPP)
+
+###############################################################################
+# Top-level Rules
+###############################################################################
+
+objects = $(DL_FILE)
+
+$(DL_FILE) = $(DL_FROM)/$(DL_FILE)
+
+$(DL_FILE)_MD5 = 489663c9246e47915cea931348e5175d
+
+install : $(TARGET)
+
+check : $(patsubst %,$(DIR_CHK)/%,$(objects))
+
+download :$(patsubst %,$(DIR_DL)/%,$(objects))
+
+md5 : $(subst %,%_MD5,$(objects))
+
+###############################################################################
+# Downloading, checking, md5sum
+###############################################################################
+
+$(patsubst %,$(DIR_CHK)/%,$(objects)) :
+       @$(CHECK)
+
+$(patsubst %,$(DIR_DL)/%,$(objects)) :
+       @$(LOAD)
+
+$(subst %,%_MD5,$(objects)) :
+       @$(MD5)
+
+###############################################################################
+# Installation Details
+###############################################################################
+
+$(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
+       @$(PREBUILD)
+       @rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar axf $(DIR_DL)/$(DL_FILE)
+       cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/mpage25-config.patch
+       cd $(DIR_APP) && make $(MAKETUNING) $(EXTRA_MAKE)
+       cd $(DIR_APP) && make $(EXTRA_INSTALL) install
+       @rm -rf $(DIR_APP)
+       @$(POSTBUILD)
diff --git a/make.sh b/make.sh
index ef98d6fa315066bdd9f15fb6f6b34059dd22e400..3f89082368532474e587dc1b7964e84dea75d0b0 100755 (executable)
--- a/make.sh
+++ b/make.sh
@@ -591,6 +591,7 @@ buildipfire() {
   ipfiremake lzo
   ipfiremake openvpn
   ipfiremake pammysql
+  ipfiremake mpage
   ipfiremake cups
   ipfiremake ghostscript
   ipfiremake foomatic
diff --git a/src/patches/mpage25-config.patch b/src/patches/mpage25-config.patch
new file mode 100644 (file)
index 0000000..fefc547
--- /dev/null
@@ -0,0 +1,46 @@
+diff -up mpage-2.5.6/Makefile.config mpage-2.5.6/Makefile
+--- mpage-2.5.6/Makefile.config        2004-05-30 21:38:31.000000000 +0200
++++ mpage-2.5.6/Makefile       2009-03-27 11:11:14.652186064 +0100
+@@ -40,7 +40,7 @@ CC=gcc
+ #  See glob.c for all possibilities
+ #
+ # PAGESIZE=Letter
+-PAGESIZE=A4
++PAGESIZE=Letter
+ #
+ # Define your spooler type
+@@ -50,7 +50,7 @@ PAGESIZE=A4
+ SPOOL_TYPE=BSD_SPOOLER
+ # PREFIX=e:/usr               # OS/2 type
+-PREFIX=/usr/local
++PREFIX=/usr
+ #PREFIX=/usr
+ BINDIR=$(PREFIX)/bin
+ LIBDIR=$(PREFIX)/share
+@@ -73,7 +73,7 @@ SHEETMARGIN=18 
+ #
+ DEFAULT_DUPLEX=0
+-DEFS = -DPAGE_DEF=\"${PAGESIZE}\" -DLIBDIR=\"${LIBDIR}/mpage\" -DDEFAULT_ENCODING=${ENCODING} -DDEFAULT_DUPLEX=${DEFAULT_DUPLEX} -DDEFAULTSMARGIN=${SHEETMARGIN} -DSPOOLER=${SPOOL_TYPE} # -DKANJI
++DEFS = -DPAGE_DEF=\"${PAGESIZE}\" -DLIBDIR=\"${LIBDIR}/mpage\" -DDEFAULT_ENCODING=${ENCODING} -DDEFAULT_DUPLEX=${DEFAULT_DUPLEX} -DDEFAULTSMARGIN=${SHEETMARGIN} -DSPOOLER=${SPOOL_TYPE} -DKANJI
+ ############################################################################
+@@ -107,7 +107,7 @@ O = .o
+ # If you are using gcc, you probably don't need to change anything here.
+ # Linux:
+-CFLAGS = -O2 -s $(DEFS) -Wall
++CFLAGS = $(RPM_OPT_FLAGS) $(DEFS) -Wall
+ # AIX (xlC on aix 4):
+ #CFLAGS = -O2 -s $(DEFS)
+@@ -183,5 +183,4 @@ install:
+       if [ ! -d $(MANDIR) ] ; then mkdir -p $(MANDIR) ; fi
+       cp mpage$(E) $(BINDIR)
+       cp mpage.1 $(MANDIR)
+-      -cp Encodings/* $(LIBDIR)/mpage
+-      -chmod 644 $(LIBDIR)/mpage/*
++      install -p -m 644 Encodings/* $(LIBDIR)/mpage