Crystal03 / google-docs-fs

Automatically exported from code.google.com/p/google-docs-fs
GNU General Public License v2.0
0 stars 0 forks source link

Getting it working on Mac OS X 10.5.7 #11

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Run an OS the developer doesn't have. :-)
2. Stubbornly refuse to use fink or macports.
3. Using system version of python; 2.5.1
4. google-docs-fs 1.0beta3

Actual problems in this software:
1. See Auditing.

Detailed installation instructions follow.

======Prerequisites======
*****MacFUSE 2.0.3 installed from .dmg

*****pkg-config-0.23: got this from http://pkg-config.freedesktop.org/wiki/
./configure
make && make check && sudo make install
Runs fine.

*****fuse-python: 
* Somehow setup.py thinks we're running FreeBSD and is trying to include a 
non-existent header 
osreldate.h...
* osreldate.h is included from pyport.h, becuase __FreeBSD__ is defined.
* That's defined because of pkg-config --cflags fuse.
/usr/local/lib/pkgconfig $ sudo cp fuse.pc fuse.bak
/usr/local/lib/pkgconfig $ sudo vim fuse.pc
/usr/local/lib/pkgconfig $ diff fuse.pc fuse.bak
10c10
< Cflags: -I${includedir}/fuse -D_FILE_OFFSET_BITS=64

---
> Cflags: -I${includedir}/fuse -D__FreeBSD__=10 -D_FILE_OFFSET_BITS=64

python setup.py build && python setup.py test && sudo python setup.py install

And you'll probably want to restore fuse.pc:
sudo mv fuse.pc fuse.fix && sudo mv fuse.bak fuse.pc

*****gdata-2.0.0:
python setup.py build && sudo python setup.py install && 
./tests/run_data_tests.py

=====Auditing INSTALL.py=====

        install_path = "/usr/lib/python%s/site-packages/google-docs-fs" % (python_version, )
Apple soft links /usr/lib/python2.5 to the right place, *but* only the system 
libraries are there.

Recommend:

# insert these lines after the other imports
from distutils.sysconfig import get_python_lib
import os.path

# I just stuck this after all the code to determine the install_path, so it 
simply overrides it.
# I'm not trying to make it perfect, just get it working.
    else:
        install_path = "/usr/lib/python%s/site-packages/google-docs-fs" % (python_version, )
install_path = os.path.join(get_python_lib(), "google-docs-fs")

./INSTALL.py works fine now

=====Test Run=====
gmount gdocs/ my.name@gmail.com

Hurrah!

Original issue reported on code.google.com by ben.sam...@gmail.com on 11 Jul 2009 at 4:50

GoogleCodeExporter commented 9 years ago
Well, I spoke too soon. All the directories show up, but none of the files are 
actually accessible. Sigh.

Original comment by ben.sam...@gmail.com on 11 Jul 2009 at 4:58

GoogleCodeExporter commented 9 years ago
This is excellent news. Thanks! I'll get the manual updated when I get back 
from my camping trip. May I 
ask exactly what is happening with regard to files not being accessible? Are 
they showing up but can't be 
read or are they simply not showing up at all?
I'll use your advice to improve the install script. I'll make sure to credit 
you too.
Thanks again.
Scott W

Original comment by d38dm8nw81k1ng@gmail.com on 11 Jul 2009 at 7:31

GoogleCodeExporter commented 9 years ago
Well:

~ $ mount
/dev/disk0s2 on / (hfs, local, journaled)
devfs on /dev (devfs, local)
fdesc on /dev (fdesc, union)
map -hosts on /net (autofs, automounted)
map auto_home on /home (autofs, automounted)
Python@fuse0 on /Users/ben/gdocs (fusefs, nodev, nosuid, synchronous, mounted 
by ben)

~/gdocs $ stat -x Organizing
  File: "Organizing"
  Size: 4096         FileType: Directory
  Mode: (0744/drwxr--r--)         Uid: (  501/     ben)  Gid: (   20/   staff)
Device: 46,4   Inode: 4    Links: 2
Access: Wed Jan  3 00:00:00 2001
Modify: Sun Feb 15 19:29:07 2009
Change: Sat Jul 11 13:27:48 2009

~/gdocs $ cd Organizing/

~/gdocs/Organizing $ stat -x Daily\ Review.xls 
  File: "Daily Review.xls"
  Size: 28           FileType: Regular File
  Mode: (0744/-rwxr--r--)         Uid: (  501/     ben)  Gid: (   20/   staff)
Device: 46,4   Inode: 8    Links: 2
Access: Mon Feb 23 01:06:08 2009
Modify: Tue Feb 24 18:04:27 2009
Change: Sat Jul 11 13:28:09 2009

~/gdocs/Organizing $ cat Daily\ Review.xls 
cat: Daily Review.xls: Invalid argument

Original comment by ben.sam...@gmail.com on 11 Jul 2009 at 5:32

GoogleCodeExporter commented 9 years ago
BTW, thanks for writing it, it's a great idea.

Original comment by ben.sam...@gmail.com on 11 Jul 2009 at 5:35

GoogleCodeExporter commented 9 years ago
Cheers for the info. Could you download the latest SVN (r87) and run that with 
the -d
flag for me please?
If you don't use SVN, you can get the same behaviour by running (from the 
untarred
directory):
./gFile.py email@gmail.com directory

You can then run any commands from a separate terminal. Run those commands 
again and
also run:
ls -la /Users/ben/gdocs
if that is the mounted directory.
Then, could you copy and paste the output into a text file and attach that to 
your
next comment? Doing this would greatly assist my understanding of the problem 
and
make it much easier to diagnose the issue.
Thanks
Scott Walton

Original comment by d38dm8nw81k1ng@gmail.com on 12 Jul 2009 at 6:08

GoogleCodeExporter commented 9 years ago
Okay, ran from subversion. This time it came up empty.

~ $ gmount /Users/ben/gdocs ben.samuel@gmail.com -d 2> debug.out
Password: 

In another terminal:
~ $ stat -x gdocs
  File: "gdocs"
  Size: 4096         FileType: Directory
  Mode: (0744/drwxr--r--)         Uid: (  501/     ben)  Gid: (   20/   staff)
Device: 46,8   Inode: 1    Links: 2
Access: Sun Jul 12 14:39:31 2009
Modify: Sun Jul 12 14:39:31 2009
Change: Sun Jul 12 14:39:31 2009

~ $ mount | grep gdocs
Python@fuse0 on /Users/ben/gdocs (fusefs, nodev, nosuid, synchronous, mounted 
by ben)
~ $ umount gdocs

And the debug run is attached.

Original comment by ben.sam...@gmail.com on 12 Jul 2009 at 6:42

Attachments:

GoogleCodeExporter commented 9 years ago
Cheers. It seems the problem is related to something I put in to make OSX
functionality work. Shows what I know. Anyway, I've added a new revision (r89) 
to SVN
if you want to have a go at that. I've also updated the INSTALL.py file if you 
want
to give it a going over and see if I've got it right.
Thanks
Scott W

Original comment by d38dm8nw81k1ng@gmail.com on 12 Jul 2009 at 7:45

GoogleCodeExporter commented 9 years ago
Oh and if it doesn't work straight away, give it a few minutes and try again, 
just to
see if that helps (don't unmount it). I've just been having problems which I 
think
are GNOME interfering with my tests and OSX might do similar things.

Original comment by d38dm8nw81k1ng@gmail.com on 12 Jul 2009 at 7:47

GoogleCodeExporter commented 9 years ago
That seems to fix things.

Original comment by mjbauer95 on 28 Jul 2009 at 7:44

GoogleCodeExporter commented 9 years ago
Trying to get this working on OS X 10.5.8.  I followed the instructions to 
install all of 
the dependencies and then installed google-docs-fs.  Everything seemed to 
install 
fine.  However, when I issue the gmount command with the directory and my 
username, I get the following error:

Traceback (most recent call last):
  File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-
packages/google-docs-fs/gFile.py", line 28, in <module>
    import fuse
  File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-
packages/fuse.py", line 26, in <module>
    from fuseparts._fuse import main, FuseGetContext, FuseInvalidate
ImportError: 
dlopen(/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-
packages/fuseparts/_fusemodule.so, 2): Symbol not found: _iconv
  Referenced from: /opt/local/lib/libfuse.0.dylib
  Expected in: flat namespace

Any help?

Original comment by sethwll...@gmail.com on 13 Jan 2010 at 12:53

GoogleCodeExporter commented 9 years ago
okay, after trying all sorts of ridiculous things, i solved my issue with the 
simplest 
approach possible: 
sudo easy_install --upgrade fuse-python

i have no idea why this solved the issues that fuse-python was having, but it 
worked for 
me.  i'm now able to mount my gdocs file space and axess all the files from OS 
X 10.5.8 
using Python 2.6.

Original comment by sethwll...@gmail.com on 13 Jan 2010 at 7:33

GoogleCodeExporter commented 9 years ago
Cheers for the input. I'll make a note in the manual. It's possible that you 
had an
older version of fuse-python installed. From what I've been told, the bindings 
are
quite sensitive to version changes.

Original comment by d38dm8nw81k1ng@gmail.com on 6 Mar 2010 at 11:28

GoogleCodeExporter commented 9 years ago
I am getting the missing _iconv Symbol too, but the upgrade didn't not help me. 

where should the iconv library be located ? I am on OS X 10.6.4 and Python 2.6

Original comment by DennisSc...@gmail.com on 20 Jun 2010 at 9:56