Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 228103 - app-text/htmlrecode: update 1.3.0 and compilation on amd64
Summary: app-text/htmlrecode: update 1.3.0 and compilation on amd64
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: High minor (vote)
Assignee: Gentoo SGML project
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-06-18 14:58 UTC by Pavel Vondricka
Modified: 2008-07-23 15:55 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Pavel Vondricka 2008-06-18 14:58:04 UTC
Htmlrecode doesn't compile on amd64, however it works for me just by adding -m32 to the Makefiles. I don't know if this is the preferred way to solve the problem, but I really need this tool and this was the easiest solution for me. Here follow the changes I've made. Could this be somehow added to the ebuild? Or a better solution?
(And BTW: I use the latest bugfix release 1.3.0 while the latest ebuild in portage is still 1.2.0)


Reproducible: Always




diff -Naur old/argh/Makefile new/argh/Makefile
--- old/argh/Makefile	2004-02-22 00:21:22.000000000 +0000
+++ new/argh/Makefile	2008-06-18 15:25:20.000000000 +0100
@@ -6,7 +6,8 @@
 
 include Makefile.sets
 
-CPPFLAGS+=-DNEED_ARGH_H
+LDFLAGS=-m32
+CPPFLAGS+=-DNEED_ARGH_H -m32
 INSTALL=install
 INSTALLLIBS=libargh.so
 LIBDIR=/usr/local/lib
@@ -16,9 +17,9 @@
 all: libargh.so libargh.a
 
 libargh.so: argh.lo
-	$(CXX) -g -shared -Wl,-soname=$@ -o $@ $^
+	$(CXX) $(LDFLAGS) -g -shared -Wl,-soname=$@ -o $@ $^
 argh.lo: argh.cc
-	$(CXX) $(CXXFLAGS) $(CPPFLAGS) -fpic -o $@ -c $<
+	$(CXX) $(CXXFLAGS) $(CPPFLAGS) $(LDFLAGS) -fpic -o $@ -c $<
 
 libargh.a: argh.o
 	ar -rc $@ $^
diff -Naur old/Makefile new/Makefile
--- old/Makefile	2004-09-18 23:26:05.000000000 +0100
+++ new/Makefile	2008-06-18 15:12:18.000000000 +0100
@@ -1,12 +1,13 @@
 VERSION=1.3.0
 include Makefile.sets
 #LDFLAGS=-liconv - not needed apparently
+LDFLAGS=-m32
 
 # Note: If you get linkage errors from basic_string this and that,
 #       try this kind of command to force using an older g++ version.
 #CXX=/usr/gcc3/bin/i586-pc-linux-gnu-g++
 
-CPPFLAGS := $(CPPFLAGS) -Iargh
+CPPFLAGS := $(CPPFLAGS) -m32 -Iargh
 
 ARCHDIR=archives/
 ARCHNAME=htmlrecode-$(VERSION)
Comment 1 Santiago M. Mola (RETIRED) gentoo-dev 2008-07-23 15:55:19 UTC
1.3.0 is now in the tree, with a patch for amd64 compatibility and fixes for gcc-4.3. Thanks for reporting.