<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://www.sharpfin.org/index.php?action=history&amp;feed=atom&amp;title=Building_Under_Cygwin</id>
	<title>Building Under Cygwin - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://www.sharpfin.org/index.php?action=history&amp;feed=atom&amp;title=Building_Under_Cygwin"/>
	<link rel="alternate" type="text/html" href="https://www.sharpfin.org/index.php?title=Building_Under_Cygwin&amp;action=history"/>
	<updated>2026-04-23T14:52:05Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.43.4</generator>
	<entry>
		<id>https://www.sharpfin.org/index.php?title=Building_Under_Cygwin&amp;diff=31&amp;oldid=prev</id>
		<title>Philipp: Created page with &quot;I wanted to try building under Cygwin for convenience as opposed to using my Linux box. Here are the problems I encountered using an virgin checkout of the source tree from Git. I had already installed the cross compiler for Cygwin with no problems so I&#039;ll preume you have too.   &#039;&#039;&#039;[1] &quot;Can&#039;t execute binary file&quot; error message during build&#039;&#039;&#039;  I think this first happened trying to run fixdep.exe from [root]srcipksharpfin-base-ipkusyboxscriptsasic This file should be buil...&quot;</title>
		<link rel="alternate" type="text/html" href="https://www.sharpfin.org/index.php?title=Building_Under_Cygwin&amp;diff=31&amp;oldid=prev"/>
		<updated>2025-06-08T09:31:26Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;I wanted to try building under Cygwin for convenience as opposed to using my Linux box. Here are the problems I encountered using an virgin checkout of the source tree from Git. I had already installed the cross compiler for Cygwin with no problems so I&amp;#039;ll preume you have too.   &amp;#039;&amp;#039;&amp;#039;[1] &amp;quot;Can&amp;#039;t execute binary file&amp;quot; error message during build&amp;#039;&amp;#039;&amp;#039;  I think this first happened trying to run fixdep.exe from [root]srcipksharpfin-base-ipkusyboxscriptsasic This file should be buil...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;I wanted to try building under Cygwin for convenience as opposed to using my Linux box. Here are the problems I encountered using an virgin checkout of the source tree from Git. I had already installed the cross compiler for Cygwin with no problems so I&amp;#039;ll preume you have too.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;[1] &amp;quot;Can&amp;#039;t execute binary file&amp;quot; error message during build&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
I think this first happened trying to run fixdep.exe from [root]srcipksharpfin-base-ipkusyboxscriptsasic&lt;br /&gt;
This file should be build to run on the host system, but I had and old ELF32 there when I downloaded the source tree from git. Whenever you get&lt;br /&gt;
this message, go to the relevant folder and delete any intermediate and target files (.o .exe ELF32) to force a tidy rebuild. This should take care of it.&lt;br /&gt;
&lt;br /&gt;
    &lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;[2] _libintl_gettext library not being found&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
This library doesn&amp;#039;t seem to be included in the Cygwin build. There are a few Makefiles you will need to edit here. As an example, here is the&lt;br /&gt;
patch for my [root]srcipksharpfin-base-ipkusyboxscriptskconfigMakefile&lt;br /&gt;
I found this patch on the web somewhere but unfortunately didn&amp;#039;t note the URL to give the originator proper credit. My bad.&lt;br /&gt;
&lt;br /&gt;
The lines to add begin with &amp;gt;&amp;gt;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    HOSTLOADLIBES_gconf = `pkg-config --libs gtk+-2.0 gmodule-2.0 libglade-2.0`&lt;br /&gt;
    HOSTCFLAGS_gconf.o  = `pkg-config --cflags gtk+-2.0 gmodule-2.0 libglade-2.0` \&lt;br /&gt;
                              -D LKC_DIRECT_LINK&lt;br /&gt;
    &lt;br /&gt;
    &amp;gt;&amp;gt;&amp;gt; HOST_OS := $(shell uname -o)&lt;br /&gt;
    &amp;gt;&amp;gt;&amp;gt; ifeq ($(HOST_OS),Cygwin)&lt;br /&gt;
    &amp;gt;&amp;gt;&amp;gt; HOSTLOADLIBES_mconf = -lintl&lt;br /&gt;
    &amp;gt;&amp;gt;&amp;gt; HOSTLOADLIBES_conf = -lintl&lt;br /&gt;
    &amp;gt;&amp;gt;&amp;gt; endif&lt;br /&gt;
    &lt;br /&gt;
    $(obj)/qconf.o: $(obj)/.tmp_qtcheck&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;[4] &amp;quot;Invalid owner&amp;quot; message&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Somewhere in the build output you have an error message like this:&lt;br /&gt;
&lt;br /&gt;
    chmod -R 755 files&lt;br /&gt;
    ../../../devtools/bin/ipkg-build -o root -g root files&lt;br /&gt;
    tar: root: Invalid owner&lt;br /&gt;
    tar: Error is not recoverable: exiting now&lt;br /&gt;
    tar: root: Invalid owner&lt;br /&gt;
    tar: Error is not recoverable: exiting now&lt;br /&gt;
    ar: ./data.tar.gz: No such file or directory&lt;br /&gt;
&lt;br /&gt;
This is because there is no root user in Cygwin. I&amp;#039;m not sure if the way I solved this is the correct way to do it. I think it may leave files with the wrong owner or group in the output image, so which may me a problem if you flash the image into the radio - I&amp;#039;m not planning to do this and only needed the toolchain to build. Anyway, this owner is set in the following five makefiles and you will need to change it in each one. It&amp;#039;s the argument to the -o option.&lt;br /&gt;
&lt;br /&gt;
    sharpfin-base-ipk&lt;br /&gt;
    sharpfin-ftpd-ipk&lt;br /&gt;
    sharpfin-httpd-ipk&lt;br /&gt;
    sharpfin-telnetd-ipk&lt;br /&gt;
    sharpfin-www-ipk&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;[5] zip command not found&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Make sure you have a zip installed in the PATH for Cygwin. I didn&amp;#039;t have one in mine and this will cause the build to fall. I got mine from here: http://mirror.calvin.edu/cygwin/release/zip/&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
That&amp;#039;s it. I hope this helps.&lt;/div&gt;</summary>
		<author><name>Philipp</name></author>
	</entry>
</feed>