untrunc icon indicating copy to clipboard operation
untrunc copied to clipboard

Mac OS - bash: ./untrunc: No such file or directory

Open themysciraa opened this issue 6 years ago • 21 comments

I have compiled untrunc as per README doc guide on Mac OS

wget https://github.com/ponchio/untrunc/archive/master.zip
unzip master.zip
cd untrunc-master
wget http://libav.org/releases/libav-0.8.7.tar.xz
tar xvf libav-0.8.7.tar.xz
cd libav-0.8.7
./configure
make
cd ..
g++ -o untrunc file.cpp main.cpp track.cpp atom.cpp mp4.cpp -I./libav-0.8.7 -L./libav-0.8.7/libavformat -lavformat -L./libav-0.8.7/libavcodec -lavcodec -L./libav-0.8.7/libavutil -lavutil -lpthread

but I get this error when I try to use it: -bash: ./untrunc: No such file or directory

I have tried changing my working directory by cd /Users/Home/untrunc-master but I still get the same error.

When I open up untrunc-master folder to check, I see untrunc.pro file, so I tried using that and got -bash: ./untrunc.pro: Permission denied

Please help me

themysciraa avatar Jul 24 '19 19:07 themysciraa

can you do file /path/to/untrunc? I once had this issue because I tried to run a 32bit executable on a 64bit system.

anthwlock avatar Jul 25 '19 06:07 anthwlock

@anthwlock Hi, I've tried your suggestion, typed this into terminal file /path/to/untrunc but got this error msg /path/to/untrunc: cannot open '/path/to/untrunc' (No such file or directory)

themysciraa avatar Jul 25 '19 07:07 themysciraa

Maybe replace '/path/to/untrunc' with the path to untrunc?

anthwlock avatar Jul 25 '19 07:07 anthwlock

@anthwlock The folder where I ran the command unzip master.zip and then cd untrunc-master, is that the path to untrunc?

themysciraa avatar Jul 25 '19 07:07 themysciraa

You are then in the folder containing the untrunc executable. You can do pwd to print the working/current directory.

anthwlock avatar Jul 25 '19 08:07 anthwlock

@anthwlock This is my untrunc-master folder. I can only see one file named untrunc which is the untrunc.pro file. Is that the untrunc executable? Or my untrunc executable is missing? Screen Shot 2019-07-25 at 6 28 02 PM

Also at the https://github.com/ponchio/untrunc page, I see the same untrunc.pro but not untrunc. Screen Shot 2019-07-25 at 6 30 15 PM

themysciraa avatar Jul 25 '19 09:07 themysciraa

untrunc.pro is a project file used by qtcreator.

Maybe your compilation failed? If so, try to compile my fork, the compilation is way easier there.

anthwlock avatar Jul 25 '19 10:07 anthwlock

@anthwlock sorry for the late reply. Mac OS doesn't support apt-get, so I googled for a way around it, the suggestion was to use homebrew. Tried brew install libavformat-dev libavcodec-dev libavutil-dev but it doesn't work.

themysciraa avatar Jul 26 '19 08:07 themysciraa

I think brew install ffmpeg should do.

anthwlock avatar Jul 27 '19 08:07 anthwlock

@anthwlock I've actually had ffmpeg installed long ago. Please guide me along step by step to install and compile untrunc using your fork, taking into consideration my Mac OS already has ffmpeg installed.

themysciraa avatar Jul 27 '19 08:07 themysciraa

The only step needed after you have ffmpeg and its public headers is make. If it fails please post it's output

anthwlock avatar Jul 27 '19 09:07 anthwlock

@anthwlock sorry please bear with me, I'm really lost. I'm not familiar with command line, if it's a step by step guide, I can follow it to a T.

What's public headers? and Do I just type make and enter? Do I need any prefix or suffix to it?

themysciraa avatar Jul 27 '19 10:07 themysciraa

The public headers are what tells the c/c++ compiler what the ffmpeg library has to offer. You don't need these in order to run applications using ffmpeg, but only in order to build them.

I assume that brew install ffmpeg also installs these public headers, and that you used brew to install ffmpeg.

Yes, just typing make should suffice. It won't install anything, it will just create the untrunc executable in the directory where the Makefile is, which should be the current directory.

anthwlock avatar Jul 27 '19 12:07 anthwlock

@anthwlock I think it failed to compile at make, this is the output:

make untrunc: ffmpeg: shared

c++ -MMD -MP -DUNTR_VERSION="" -std=c++11 -g -o .build_shared/src/atom.o -c src/atom.cpp In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:41:12: error: unknown type name 'off64_t'; did you mean 'off_t'? void seek(off64_t p); ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef __darwin_off_t off_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:42:16: error: unknown type name 'off64_t'; did you mean 'off_t'? void seekSafe(off64_t p); ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef __darwin_off_t off_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:43:2: error: unknown type name 'off64_t'; did you mean 'off_t'? off64_t pos(); ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef _darwin_off_t off_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:45:2: error: unknown type name 'off64_t'; did you mean 'off_t'? off64_t length() { return size; } ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef __darwin_off_t off_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:57:24: error: unknown type name 'off64_t'; did you mean 'off_t'? const uchar* getPtrAt(off64_t pos, int size_requested); ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef __darwin_off_t off_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:63:20: error: unknown type name 'off64_t'; did you mean 'off_t'? size_t fillBuffer(off64_t location); ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef _darwin_off_t off_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:65:2: error: unknown type name 'off64_t'; did you mean 'off_t'? off64_t size; ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef _darwin_off_t off_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:67:2: error: unknown type name 'off64_t'; did you mean 'off_t'? off64_t buf_begin = 0; ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef _darwin_off_t off_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:68:2: error: unknown type name 'off64_t'; did you mean 'off_t'? off64_t buf_off = 0; ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef __darwin_off_t off_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:77:2: error: unknown type name 'off64_t'; did you mean 'off_t'? off64_t pos(); ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef __darwin_off_t off_t; ^ In file included from src/atom.cpp:2: src/atom.h:49:9: error: unknown type name 'off64_t'; did you mean 'off_t'? static off64_t findNextAtomOff(FileRead& file, const Atom* start... ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef __darwin_off_t off_t; ^ src/atom.cpp:88:1: error: unknown type name 'off64_t'; did you mean 'off_t'? off64_t Atom::findNextAtomOff(FileRead& file, const Atom* start_atom, bo... ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef darwin_off_t off_t; ^ src/atom.cpp:90:2: error: unknown type name 'off64_t'; did you mean 'off_t'? off64_t next_off = start_atom->start + start_atom->length; ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef _darwin_off_t off_t; ^ src/atom.cpp:101:6: error: unknown type name 'off64_t'; did you mean 'off_t'? for(off64_t off=start_atom->start+8; off < file.length();) { ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef __darwin_off_t off_t; ^ src/atom.cpp:117:2: error: unknown type name 'off64_t'; did you mean 'off_t'? off64_t off = findNextAtomOff(file, &atom); ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef __darwin_off_t off_t; ^ src/atom.cpp:128:4: error: unknown type name 'off64_t'; did you mean 'off_t'? off64_t next_off = off + length; ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef __darwin_off_t off_t; ^ src/atom.cpp:395:2: error: unknown type name 'off64_t'; did you mean 'off_t'? off64_t start = output.pos(); ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef _darwin_off_t off_t; ^ src/atom.cpp:399:2: error: unknown type name 'off64_t'; did you mean 'off_t'? off64_t offset = file_begin; ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef _darwin_off_t off_t; ^ src/atom.cpp:416:2: error: unknown type name 'off64_t'; did you mean 'off_t'? off64_t end = output.pos(); ^~~~~~~ off_t /usr/include/sys/types/off_t.h:31:25: note: 'off_t' declared here typedef darwin_off_t off_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:9: src/common.h:31:2: warning: expression result unused [-Wunused-value] creator{ 0, ( std::cout << (std::forward<Args>(args)), 0) ... }; ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ src/common.h:46:2: note: in instantiation of function template specialization 'logg<char const (&)[10], long long &, char>' requested here logg(std::forward<Args>(x)...); ^ src/atom.cpp:36:2: note: in instantiation of function template specialization 'logg<char const (&)[10], long long &, char>' requested here logg(VV, "start = ", start, '\n'); ^ In file included from src/atom.cpp:2: In file included from src/atom.h:9: src/common.h:31:2: warning: expression result unused [-Wunused-value] creator{ 0, ( std::cout << (std::forward<Args>(args)), 0) ... }; ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ src/common.h:46:2: note: in instantiation of function template specialization 'logg<char const (&)[11], long long &, char>' requested here logg(std::forward<Args>(x)...); ^ src/atom.cpp:37:2: note: in instantiation of function template specialization 'logg<char const (&)[11], long long &, char>' requested here logg(VV, "length = ", length, '\n'); ^ In file included from src/atom.cpp:2: In file included from src/atom.h:9: src/common.h:31:2: warning: expression result unused [-Wunused-value] creator{ 0, ( std::cout << (std::forward<Args>(args)), 0) ... }; ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ src/common.h:46:2: note: in instantiation of function template specialization 'logg<char const (&)[9], std::1::basic_string &, char>' requested here logg(std::forward<Args>(x)...); ^ src/atom.cpp:38:2: note: in instantiation of function template specialization 'logg<char const (&)[9], std::1::basic_string &, char>' requested here logg(VV, "name = ", name, '\n'); ^ In file included from src/atom.cpp:2: In file included from src/atom.h:9: src/common.h:31:2: warning: expression result unused [-Wunused-value] creator{ 0, ( std::cout << (std::forward<Args>(args)), 0) ... }; ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ src/common.h:46:2: note: in instantiation of function template specialization 'logg' requested here logg(std::forward<Args>(x)...); ^ src/atom.cpp:39:2: note: in instantiation of function template specialization 'logg' requested here logg(VV, '\n'); ^ In file included from src/atom.cpp:2: In file included from src/atom.h:9: src/common.h:31:2: warning: expression result unused [-Wunused-value] creator{ 0, ( std::cout << (std::forward<Args>(args)), 0) ... }; ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ src/common.h:46:2: note: in instantiation of function template specialization 'logg<char const (&)[23], long long &, char const (&)[2]>' requested here logg(std::forward<Args>(x)...); ^ src/atom.cpp:42:3: note: in instantiation of function template specialization 'logg<char const (&)[23], long long &, char const (&)[2]>' requested here logg(W, "negative atom length: ", length, "\n"); ^ In file included from src/atom.cpp:2: In file included from src/atom.h:9: src/common.h:53:2: warning: expression result unused [-Wunused-value] creator{ 0, ( ss << (std::forward<Args>(args)), 0) ... }; ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ src/atom.cpp:45:24: note: in instantiation of function template specialization 'ss<char const (&)[13], long long &>' requested here if (start < 0) throw ss("atom start: ", start); // this is i... ^ In file included from src/atom.cpp:2: In file included from src/atom.h:9: src/common.h:53:2: warning: expression result unused [-Wunused-value] creator{ 0, ( ss << (std::forward<Args>(args)), 0) ... }; ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ src/atom.cpp:46:58: note: in instantiation of function template specialization 'ss<char const (&)[21], std::_1::basic_string &, char const (&)[2]>' requested here for (int i=0; i < 4; i++) if (!isalnum(name[i])) throw ss("invalid ato... ^ In file included from src/atom.cpp:2: In file included from src/atom.h:9: src/common.h:53:2: warning: expression result unused [-Wunused-value] creator{ 0, ( ss << (std::forward<Args>(args)), 0) ... }; ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ src/atom.cpp:83:10: note: in instantiation of function template specialization 'ss<char const (&)[30], std::_1::basic_string &>' requested here throw ss("Failed reading atom content: ", name); ^ In file included from src/atom.cpp:2: In file included from src/atom.h:9: src/common.h:31:2: warning: expression result unused [-Wunused-value] creator{ 0, ( std::cout << (std::forward<Args>(args)), 0) ... }; ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ src/common.h:46:2: note: in instantiation of function template specialization 'logg<char const (&)[2], std::__1::basic_string &, char const (&)[38]>' requested here logg(std::forward<Args>(x)...); ^ src/atom.cpp:99:45: note: in instantiation of function template specialization 'logg<char const (&)[2], std::__1::basic_string &, char const (&)[38]>' requested here if (searching_mdat && !--show_mdat_msg_in) logg(I, "'", file.fil... ^ In file included from src/atom.cpp:2: In file included from src/atom.h:9: src/common.h:53:2: warning: expression result unused [-Wunused-value] creator{ 0, ( ss << (std::forward<Args>(args)), 0) ... }; ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ src/atom.cpp:127:12: note: in instantiation of function template specialization 'ss<long long &, char const (&)[3], std::_1::basic_string &, char const (&)[3], unsigned int &, char const (&)[2]>' requested here cout << ss(off, ": ", atom.name, " (", length, ")"); ^ 10 warnings and 19 errors generated. make: *** [.build_shared/src/atom.o] Error 1

themysciraa avatar Jul 27 '19 19:07 themysciraa

Please try this branch. The problem was that g++ defines _LARGEFILE64_SOURCE, but clang++ does not.

anthwlock avatar Jul 28 '19 08:07 anthwlock

@anthwlock sorry I got busy suddenly and couldn't try it out earlier. using the branch you recommended, I still have some errors:

make untrunc: ffmpeg: shared

c++ -MMD -MP -DUNTR_VERSION="" -std=c++11 -Doff64_t=__off64_t -g -o .build_shared/src/atom.o -c src/atom.cpp In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:41:12: error: unknown type name '__off64_t'; did you mean '__int64_t'? void seek(off64_t p); ^~~~~~~ __int64_t :2:17: note: expanded from here #define off64_t __off64_t ^ /usr/include/i386/_types.h:46:20: note: '__int64_t' declared here typedef long long __int64_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:42:16: error: unknown type name '__off64_t'; did you mean '__int64_t'? void seekSafe(off64_t p); ^~~~~~~ __int64_t :2:17: note: expanded from here #define off64_t __off64_t ^ /usr/include/i386/_types.h:46:20: note: '__int64_t' declared here typedef long long __int64_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:43:2: error: unknown type name '__off64_t'; did you mean '__int64_t'? off64_t pos(); ^~~~~~~ __int64_t :2:17: note: expanded from here #define off64_t __off64_t ^ /usr/include/i386/_types.h:46:20: note: '__int64_t' declared here typedef long long __int64_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:45:2: error: unknown type name '__off64_t'; did you mean '_int64_t'? off64_t length() { return size; } ^~~~~~~ __int64_t :2:17: note: expanded from here #define off64_t __off64_t ^ /usr/include/i386/_types.h:46:20: note: '__int64_t' declared here typedef long long __int64_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:57:24: error: unknown type name '__off64_t'; did you mean '__int64_t'? const uchar* getPtrAt(off64_t pos, int size_requested); ^~~~~~~ __int64_t :2:17: note: expanded from here #define off64_t __off64_t ^ /usr/include/i386/_types.h:46:20: note: '__int64_t' declared here typedef long long __int64_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:63:20: error: unknown type name '__off64_t'; did you mean '__int64_t'? size_t fillBuffer(off64_t location); ^~~~~~~ __int64_t :2:17: note: expanded from here #define off64_t __off64_t ^ /usr/include/i386/_types.h:46:20: note: '__int64_t' declared here typedef long long __int64_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:65:2: error: unknown type name '__off64_t'; did you mean '_int64_t'? off64_t size; ^~~~~~~ __int64_t :2:17: note: expanded from here #define off64_t __off64_t ^ /usr/include/i386/_types.h:46:20: note: '__int64_t' declared here typedef long long __int64_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:67:2: error: unknown type name '__off64_t'; did you mean '_int64_t'? off64_t buf_begin = 0; ^~~~~~~ __int64_t :2:17: note: expanded from here #define off64_t __off64_t ^ /usr/include/i386/_types.h:46:20: note: '__int64_t' declared here typedef long long __int64_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:68:2: error: unknown type name '__off64_t'; did you mean '_int64_t'? off64_t buf_off = 0; ^~~~~~~ __int64_t :2:17: note: expanded from here #define off64_t __off64_t ^ /usr/include/i386/_types.h:46:20: note: '__int64_t' declared here typedef long long __int64_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:77:2: error: unknown type name '__off64_t'; did you mean '__int64_t'? off64_t pos(); ^~~~~~~ __int64_t :2:17: note: expanded from here #define off64_t __off64_t ^ /usr/include/i386/_types.h:46:20: note: '__int64_t' declared here typedef long long __int64_t; ^ In file included from src/atom.cpp:2: src/atom.h:49:9: error: unknown type name '__off64_t'; did you mean '__int64_t'? static off64_t findNextAtomOff(FileRead& file, const Atom* start... ^~~~~~~ __int64_t :2:17: note: expanded from here #define off64_t __off64_t ^ /usr/include/i386/_types.h:46:20: note: '__int64_t' declared here typedef long long __int64_t; ^ src/atom.cpp:88:1: error: unknown type name '__off64_t'; did you mean '__int64_t'? off64_t Atom::findNextAtomOff(FileRead& file, const Atom* start_atom, bo... ^~~~~~~ __int64_t :2:17: note: expanded from here #define off64_t __off64_t ^ /usr/include/i386/_types.h:46:20: note: '__int64_t' declared here typedef long long __int64_t; ^ src/atom.cpp:90:2: error: unknown type name '__off64_t'; did you mean 'int64_t'? off64_t next_off = start_atom->start + start_atom->length; ^~~~~~~ __int64_t :2:17: note: expanded from here #define off64_t __off64_t ^ /usr/include/i386/_types.h:46:20: note: '__int64_t' declared here typedef long long __int64_t; ^ src/atom.cpp:101:6: error: unknown type name '__off64_t'; did you mean '_int64_t'? for(off64_t off=start_atom->start+8; off < file.length();) { ^~~~~~~ __int64_t :2:17: note: expanded from here #define off64_t __off64_t ^ /usr/include/i386/_types.h:46:20: note: '__int64_t' declared here typedef long long __int64_t; ^ src/atom.cpp:117:2: error: unknown type name '__off64_t'; did you mean '__int64_t'? off64_t off = findNextAtomOff(file, &atom); ^~~~~~~ __int64_t :2:17: note: expanded from here #define off64_t __off64_t ^ /usr/include/i386/_types.h:46:20: note: '__int64_t' declared here typedef long long __int64_t; ^ src/atom.cpp:128:4: error: unknown type name '__off64_t'; did you mean '__int64_t'? off64_t next_off = off + length; ^~~~~~~ __int64_t :2:17: note: expanded from here #define off64_t __off64_t ^ /usr/include/i386/_types.h:46:20: note: '__int64_t' declared here typedef long long __int64_t; ^ src/atom.cpp:395:2: error: unknown type name '__off64_t'; did you mean '__int64_t'? off64_t start = output.pos(); ^~~~~~~ __int64_t :2:17: note: expanded from here #define off64_t __off64_t ^ /usr/include/i386/_types.h:46:20: note: '__int64_t' declared here typedef long long __int64_t; ^ src/atom.cpp:399:2: error: unknown type name '__off64_t'; did you mean '_int64_t'? off64_t offset = file_begin; ^~~~~~~ __int64_t :2:17: note: expanded from here #define off64_t __off64_t ^ /usr/include/i386/_types.h:46:20: note: '__int64_t' declared here typedef long long __int64_t; ^ src/atom.cpp:416:2: error: unknown type name '__off64_t'; did you mean '__int64_t'? off64_t end = output.pos(); ^~~~~~~ __int64_t :2:17: note: expanded from here #define off64_t __off64_t ^ /usr/include/i386/_types.h:46:20: note: '__int64_t' declared here typedef long long __int64_t; ^ 19 errors generated. make: *** [.build_shared/src/atom.o] Error 1

themysciraa avatar Aug 01 '19 07:08 themysciraa

Ok, does it work now?

anthwlock avatar Aug 01 '19 18:08 anthwlock

@anthwlock sorry it still doesn't work, it looks like a different set of errors

make untrunc: ffmpeg: shared

c++ -MMD -MP -DUNTR_VERSION="" -std=c++11 -D_LARGEFILE64_SOURCE -g -o .build_shared/src/atom.o -c src/atom.cpp In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:41:12: error: unknown type name 'off64_t'; did you mean 'off_t'? void seek(off64_t p); ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef __darwin_off_t off_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:42:16: error: unknown type name 'off64_t'; did you mean 'off_t'? void seekSafe(off64_t p); ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef __darwin_off_t off_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:43:2: error: unknown type name 'off64_t'; did you mean 'off_t'? off64_t pos(); ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef _darwin_off_t off_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:45:2: error: unknown type name 'off64_t'; did you mean 'off_t'? off64_t length() { return size; } ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef __darwin_off_t off_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:57:24: error: unknown type name 'off64_t'; did you mean 'off_t'? const uchar* getPtrAt(off64_t pos, int size_requested); ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef __darwin_off_t off_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:63:20: error: unknown type name 'off64_t'; did you mean 'off_t'? size_t fillBuffer(off64_t location); ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef _darwin_off_t off_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:65:2: error: unknown type name 'off64_t'; did you mean 'off_t'? off64_t size; ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef _darwin_off_t off_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:67:2: error: unknown type name 'off64_t'; did you mean 'off_t'? off64_t buf_begin = 0; ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef _darwin_off_t off_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:68:2: error: unknown type name 'off64_t'; did you mean 'off_t'? off64_t buf_off = 0; ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef __darwin_off_t off_t; ^ In file included from src/atom.cpp:2: In file included from src/atom.h:10: src/file.h:77:2: error: unknown type name 'off64_t'; did you mean 'off_t'? off64_t pos(); ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef __darwin_off_t off_t; ^ In file included from src/atom.cpp:2: src/atom.h:49:9: error: unknown type name 'off64_t'; did you mean 'off_t'? static off64_t findNextAtomOff(FileRead& file, const Atom* start... ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef __darwin_off_t off_t; ^ src/atom.cpp:88:1: error: unknown type name 'off64_t'; did you mean 'off_t'? off64_t Atom::findNextAtomOff(FileRead& file, const Atom* start_atom, bo... ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef darwin_off_t off_t; ^ src/atom.cpp:90:2: error: unknown type name 'off64_t'; did you mean 'off_t'? off64_t next_off = start_atom->start + start_atom->length; ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef _darwin_off_t off_t; ^ src/atom.cpp:101:6: error: unknown type name 'off64_t'; did you mean 'off_t'? for(off64_t off=start_atom->start+8; off < file.length();) { ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef __darwin_off_t off_t; ^ src/atom.cpp:117:2: error: unknown type name 'off64_t'; did you mean 'off_t'? off64_t off = findNextAtomOff(file, &atom); ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef __darwin_off_t off_t; ^ src/atom.cpp:128:4: error: unknown type name 'off64_t'; did you mean 'off_t'? off64_t next_off = off + length; ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef __darwin_off_t off_t; ^ src/atom.cpp:395:2: error: unknown type name 'off64_t'; did you mean 'off_t'? off64_t start = output.pos(); ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef _darwin_off_t off_t; ^ src/atom.cpp:399:2: error: unknown type name 'off64_t'; did you mean 'off_t'? off64_t offset = file_begin; ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef __darwin_off_t off_t; ^ src/atom.cpp:416:2: error: unknown type name 'off64_t'; did you mean 'off_t'? off64_t end = output.pos(); ^~~~~~~ off_t /usr/include/sys/_types/_off_t.h:31:25: note: 'off_t' declared here typedef __darwin_off_t off_t; ^ 19 errors generated. make: *** [.build_shared/src/atom.o] Error 1

themysciraa avatar Aug 01 '19 19:08 themysciraa

Replaced all off64_t with off_t and instead used -D_FILE_OFFSET_BITS=64. Now it should work!

anthwlock avatar Aug 02 '19 07:08 anthwlock

Yes, it worked now! THANK YOU SO MUCH! You have no idea how you have saved my life. That damaged video meant a lot to me, and now it's finally repaired. Thank you again for your patience to help me with all the technical issues that I have no clue about. You are a saint @anthwlock !

themysciraa avatar Aug 02 '19 10:08 themysciraa

no problem :)

anthwlock avatar Aug 05 '19 16:08 anthwlock