Changeset 445

Show
Ignore:
Timestamp:
03/04/2008 00:56:10 (6 months ago)
Author:
why
Message:
  • platform/nix/shoes.launch: added symlink check to satisfy ticket #85.
  • shoes/app.c: proper loading of the gtk icon, wherever shoes might run.
Location:
trunk
Files:
2 added
3 modified

Legend:

Unmodified
Added
Removed
  • trunk/Makefile

    r418 r445  
    6060 
    6161dist/shoes.launch: dist/shoes-bin 
    62         @echo 'APPPATH="$${0%/*}"' > dist/shoes.launch 
    63         @echo 'LD_LIBRARY_PATH="$$APPPATH/../lib/shoes" $$APPPATH/../lib/shoes/shoes-bin $$@' >> dist/shoes.launch 
     62        @cp platform/nix/shoes.launch dist/ 
    6463        @chmod 755 dist/shoes.launch 
    6564 
  • trunk/Rakefile

    r437 r445  
    5858    File.open(before) do |b| 
    5959      b.each do |line| 
    60         a << line.gsub(reg) { reg2.gsub(%r!\\1!, Object.const_get($1)) } 
     60        a << line.gsub(reg) do 
     61          reg2.gsub(%r!\\1!, Object.const_get($1)) if reg2.include? '\1' 
     62          reg2 
     63        end 
    6164      end 
    6265    end 
     
    334337    sh "#{CC} -Ldist -o #{bin} bin/main.o #{LINUX_LIBS} -lshoes #{Config::CONFIG['LDFLAGS']}" 
    335338    if PLATFORM !~ /darwin/ 
    336       sh %{echo 'APPPATH="${0%/*}"' > #{t.name}} 
    337       sh %{echo 'LD_LIBRARY_PATH=$APPPATH $APPPATH/#{File.basename(bin)} $@' >> #{t.name}} 
     339      rewrite "platform/nix/shoes.launch", t.name, %r!/shoes-bin!, "/#{NAME}-bin" 
    338340      chmod 0755, t.name 
    339341    end 
  • trunk/shoes/app.c

    r444 r445  
    14721472 
    14731473#ifdef SHOES_GTK 
     1474  char icon_path[SHOES_BUFSIZE]; 
    14741475  shoes_app_gtk *gk = &app->os; 
    14751476  shoes_slot_gtk *gs = &app->slot; 
    14761477 
    1477   gtk_window_set_default_icon_from_file("static/shoes-icon.png", NULL); 
     1478  sprintf(icon_path, "%s/static/shoes-icon.png", shoes_world->path); 
     1479  gtk_window_set_default_icon_from_file(icon_path, NULL); 
    14781480  gk->window = gtk_window_new (GTK_WINDOW_TOPLEVEL); 
    14791481  if (!app->resizable)