Bug 253835 - mkbundle needs libmono.a (not shipped)
Summary: mkbundle needs libmono.a (not shipped)
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Fedora
Classification: Fedora
Component: mono
Version: 8
Hardware: All
OS: Linux
low
low
Target Milestone: ---
Assignee: Alexander Larsson
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2007-08-22 09:52 UTC by Doncho Gunchev
Modified: 2007-11-30 22:12 UTC (History)
0 users

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2007-11-21 12:35:43 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Doncho Gunchev 2007-08-22 09:52:17 UTC
Description of problem:
mkbundle and mkbundle2 have --static option to "Statically link to mono libs", 
which clearly needs libmono.a

Version-Release number of selected component (if applicable):
mono-1.2.3-3.fc7 and mono-1.2.4-2.fc8 (rebuilt on FC7).

How reproducible:
Always

Steps to Reproduce:
1. rpm -ql mono-devel | grep libmono\\\.
  
Actual results:
/usr/lib/libmono.so

Expected results:
/usr/lib/libmono.so
/usr/lib/libmono.a

Comment 1 Doncho Gunchev 2007-11-10 15:59:23 UTC
same with mono-core-1.2.5.1-2.fc8.
Test case:

$ cat hi.cs
public class MainClass {
        public static void Main(string[] args) {
                System.Console.WriteLine("hi!");
        }
}
$ gmcs hi.cs
$ mono hi.exe
hi!
$ mkbundle2 --deps --static hi.exe -o hi
OS is: Linux
Note that statically linking the LGPL Mono runtime has more licensing 
restrictions than dynamically linking.
See http://www.mono-project.com/Licensing for details on licensing.
Sources: 1 Auto-dependencies: True
   embedding: /home/mr700/hi.exe
   embedding: /usr/lib/mono/2.0/mscorlib.dll
Compiling:
as -o temp.o temp.s
cc -o hi -Wall `pkg-config --cflags mono` temp.c  `pkg-config --libs-only-L 
mono` -Wl,-Bstatic -lmono -Wl,-Bdynamic `pkg-config --libs-only-l mono | 
sed -e "s/\-lmono //"` temp.o
/usr/bin/ld: cannot find -lmono
collect2: ld returned 1 exit status
[Fail]

recompiling mono-core to include libmono.a solves the problem.

Comment 2 Matthias Clasen 2007-11-11 20:58:55 UTC
This is a bit like saying that because the linker supports static linking, we
must include static libraries in all package.

Shipping static libraries is strongly discourages within Fedora, see
http://fedoraproject.org/wiki/Packaging/Guidelines#head-2302ec1e1f44202c9cc4bcce24cb711266557ad7

Comment 3 Doncho Gunchev 2007-11-11 21:28:54 UTC
True, I did not think of it so much. I need this at work at least for now (not 
my decision), but I can rebuild the package myself. Feel free to close it if a 
separate mono-*-static package is not appropriate here. Thanks for the 
clarification.

Comment 4 Paul F. Johnson 2007-11-21 12:35:43 UTC
Closed


Note You need to log in before you can comment on or make changes to this bug.