Bug 53629 - Error building APR-iconv for x64
Summary: Error building APR-iconv for x64
Status: NEEDINFO
Alias: None
Product: APR
Classification: Unclassified
Component: APR-iconv (show other bugs)
Version: HEAD
Hardware: PC All
: P2 normal (vote)
Target Milestone: ---
Assignee: Apache Portable Runtime bugs mailinglist
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-07-31 13:33 UTC by vali
Modified: 2012-10-08 18:37 UTC (History)
1 user (show)



Attachments
Patch to modules.mk.win (16.76 KB, application/octet-stream)
2012-07-31 13:33 UTC, vali
Details
Patch of just the needed fixes (706 bytes, patch)
2012-10-08 18:37 UTC, Gregg L. Smith
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description vali 2012-07-31 13:33:20 UTC
Created attachment 29143 [details]
Patch to modules.mk.win

There is a bug in modules.mk.win causing broken build for x64 using Visual C++. Patch attached.
Comment 1 Gregg L. Smith 2012-10-08 01:54:44 UTC
After going through the hoops of picking out just what is changing in your patch, here is what I found:

--- modules.mk.mak	2012-10-07 17:25:50.904000000 -0700
+++ modules.mk.mak	2012-10-07 17:22:12.453000000 -0700
@@ -167,10 +167,10 @@
 
 !IF "$(BIND_MODE)" == "shared"
 API_LIBS = $(APR_SOURCE)\x64\Debug\libapr-1.lib \
-	   $(API_SOURCE)\x64\Debug\libapriconv-1.lib
+	   $(API_SOURCE)\Debug\libapriconv-1.lib
 CFG_CFLAGS  = /MDd /Zi /Od /EHsc /D "_DEBUG"
 CFG_LDFLAGS = /debug /incremental:no /machine:X64
-CFG_OUTPUT  = x64\Debug\iconv
+CFG_OUTPUT  = Debug\iconv
 
 !ELSEIF "$(BIND_MODE)" == "static"
 APR_LIB = $(APR_SOURCE)\x64\LibD\apr-1.lib \

Without any more info than it breaks the VC++ compile I could not get behind this change. I build x64 often and do not have a problem with this. 

If this is breaking your build, how come APR is not since it is output to \x64\Debug also?
Comment 2 vali 2012-10-08 09:10:32 UTC
Hi Gregg,

it looks like you applied the patch in the opposite direction. And it looks like you had the correct makefile?

If I download the recommended release from a mirror, e.g. http://apache.miloslavbrada.cz/apr/apr-iconv-1.2.1-win32-src-r2.zip, then in the section "x64 Debug" there are the two incorrect lines I wanted to patch:

ln 170:
	   $(API_SOURCE)\Debug\libapriconv-1.lib

ln 173:
CFG_OUTPUT  = Debug\iconv

They should be:

ln 170:
	   $(API_SOURCE)\x64\Debug\libapriconv-1.lib

ln 173:
CFG_OUTPUT  = x64\Debug\iconv

And the same is in head revision in the SVN repository.

I hope everything is clear now.

Cheers,
- Vali
Comment 3 Gregg L. Smith 2012-10-08 18:37:30 UTC
Created attachment 29461 [details]
Patch of just the needed fixes

Ok, I see the problem now and you are correct. Thanks.