Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7002053
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T20:52:48+00:00 2026-05-27T20:52:48+00:00

I wrote a method to submit an error-report via HTTP POST. I run OSX-Lion

  • 0

I wrote a method to submit an error-report via HTTP POST. I run OSX-Lion and MonoDevelop. The code works when the application is called from MonoDevelop. When I run the .app it throws an exception:

System.TypeInitializationException: An exception was thrown by the type initializer for System.Net.WebRequest ---> System.DllNotFoundException: libc.dylib
  at (wrapper managed-to-native) System.Platform:uname (intptr)
  at System.Platform.get_IsMacOS () [0x00000] in <filename unknown>:0 
  at System.Net.WebRequest..cctor () [0x00000] in <filename unknown>:0 
  --- End of inner exception stack trace ---
  at ch.fangorn.LIF.Access.SubmitCrash.Submit (Int32 projectId) [0x00000] in <filename unknown>:0 

At the moment I call the Submit method directly not via a catch. Since it works when a debugger is attached I’m stranded. What I so far tried:

  1. Build a mono application bundle (Create mac installer)
  2. Build everything with Platform target x86
  3. The beta version of Mono and MonoDevelop

The code that IMO causes the crash.

HttpWebRequest hwr = WebRequest.Create(turi) as HttpWebRequest;
string authInfo = user + ":" + password;
authInfo = Convert.ToBase64String(Encoding.Default.GetBytes(authInfo));
hwr.Headers["Authorization"] = "Basic " + authInfo;

hwr.Method = "POST";
hwr.ContentType = "text/xml";
hwr.ContentLength = encData.Length;

Stream send = hwr.GetRequestStream();
send.Write(encData, 0, encData.Length);
send.Close();
hwr.GetResponse();

MonoDevelop: 2.8.5
Mono: 2.10.8

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T20:52:49+00:00Added an answer on May 27, 2026 at 8:52 pm

    Symptom: System libraries not found (System.DllNotFoundException: libc.dylib)
    when a mono created .app is started outside of MonoDevelop.

    In the wrapper-script created by mono develop: MyApp.app/Contents/MacOS/MyApp
    DYLD_FALLBACK_LIBRARY_PATH is set without including default. Since an empty
    DYLD_FALLBACK_LIBRARY_PATH means the default this will remove default. System
    libraries cannot be found.

    In my opition the line should be:

    export DYLD_FALLBACK_LIBRARY_PATH="$MONO_FRAMEWORK_PATH/lib:$DYLD_FALLBACK_LIBRARY_PATH:$(HOME)/lib:/usr/local/lib:/lib:/usr/lib"
    

    Or a check if DYLD_FALLBACK_LIBRARY_PATH is empty would be even better.

    I filed a bug-report: http://bugzilla.xamarin.com/show_bug.cgi?id=2727

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Using an idea from Bob King idea I wrote the following method. It works
I'm trying out the Runtime.exec() method to run a command line process. I wrote
I wrote this method to check if a page exists or not: protected bool
I wrote a method that extracts fields from an object like this: private static
I have and old(ish) C# method I wrote that takes a number and converts
Hello StackOverflow community, Using Google App Engine, I wrote a keyToSha256() method within a
I wrote a custom ordering LINQ extension method as below but I think it
I wrote a windows service in C# that does some functionality (a public method)
I've spent weeks working on double-submit protection on my forms. Straightup, the session method
Here's my function: def check_form(request): if request.method == 'POST': form = UsersForm(request.POST) if form.is_valid():

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.