Compilation fixes for x86_64.

Added quite a few missing components to image:

alert arp bc CortexAddOnHost

CDPlayer CharacterMap DeskCalc
Devices DiskUsage Expander LaunchBox MediaConverter NetworkStatus
PoorMan Pulse Screenshot ShowImage SoundRecorder TV Workspaces

DataTranslations Media Printers ScreenSaver

BSnow Cortex FontDemo OverlayImage Pairs

cddb_daemon midi_server power_daemon print_server print_addon_server

Canon LIPS3 Compatible Canon LIPS4 Compatible Gutenprint
PCL5 Compatible PCL6 Compatible PDF Writer PS Compatible

libgame.so libmedia.so

Signed-off-by: Alex Smith <[email protected]>
This commit is contained in:
Sergei Reznikov
2013-01-04 18:45:22 +00:00
committed by Alex Smith
parent f5d95ad616
commit 7f4d1af49d
36 changed files with 119 additions and 100 deletions
+40 -25
View File
@@ -6,36 +6,39 @@
# easily add things to the image as I port them. # easily add things to the image as I port them.
SYSTEM_BIN = "[" addattr base64 basename bash beep cal cat catattr checkfs SYSTEM_BIN = "[" addattr alert arp base64 basename bash bc beep cal cat catattr
chgrp chmod chown chroot cksum clear clockconfig cmp collectcatkeys comm checkfs chgrp chmod chown chroot cksum clear clockconfig cmp
compress copyattr cp csplit cut date dd diff diff3 dircolors dirname df du collectcatkeys comm compress copyattr CortexAddOnHost cp csplit cut date
dumpcatalog echo eject env error expand expr factor false find finddir dd diff diff3 dircolors dirname df du dumpcatalog echo eject env error
fmt fold fortune ftp gawk gdb gzip gzexe getlimits groups head hostname expand expr factor false find finddir fmt fold fortune ftp gawk gdb gzip
id ifconfig <bin>install isvolume join kernel_debugger kill less lessecho gzexe getlimits groups head hostname id ifconfig <bin>install isvolume
lesskey link linkcatkeys listdev ln locale locate logger logname ls join kernel_debugger kill less lessecho lesskey link linkcatkeys listdev
makebootable md5sum mimeset mkdir mkfifo mkfs mktemp mount mountvolume ln locale locate logger logname ls makebootable md5sum mimeset mkdir
mv nl nohup notify nproc od open paste patch pathchk ping pr printenv printf mkfifo mkfs mktemp mount mountvolume mv nl nohup notify nproc od open
ps ptx pwd query rc readlink ReadOnlyBootPrompt rm rmattr rmdir safemode paste patch pathchk ping pr printenv printf ps ptx pwd query rc readlink
sdiff seq sha1sum shred shuf shutdown sleep sort split stat strace stty su sum sync ReadOnlyBootPrompt rm rmattr rmdir safemode sdiff seq sha1sum shred shuf
sysinfo tac tail tee test timeout touch tr true truncate tsort tty unexpand shutdown sleep sort split stat strace stty su sum sync sysinfo tac tail
uname uniq unlink unmount unzip <bin>updatedb waitfor wc wget whoami xargs tee test timeout touch tr true truncate tsort tty unexpand uname uniq
xres yes zdiff zforce zgrep zip zipcloak <bin>zipgrep zipnote zipsplit unlink unmount unzip <bin>updatedb waitfor wc wget whoami xargs xres yes
zmore znew zdiff zforce zgrep zip zipcloak <bin>zipgrep zipnote zipsplit zmore znew
; ;
SYSTEM_APPS = AboutSystem ActivityMonitor Debugger DriveSetup Installer SYSTEM_APPS = AboutSystem ActivityMonitor CDPlayer CharacterMap Debugger DeskCalc
NetworkStatus ProcessController StyledEdit Terminal Devices DiskUsage DriveSetup Expander Installer LaunchBox MediaConverter
NetworkStatus PoorMan Pulse ProcessController Screenshot ShowImage
SoundRecorder StyledEdit Terminal TV Workspaces
; ;
SYSTEM_PREFERENCES = Appearance Backgrounds <preference>Deskbar FileTypes SYSTEM_PREFERENCES = Appearance Backgrounds DataTranslations <preference>Deskbar
Keyboard Keymap Locale Mouse Network Notifications Screen Time Touchpad FileTypes Keyboard Keymap Locale Media Mouse Network Notifications
<preference>Tracker VirtualMemory Printers Screen ScreenSaver Time Touchpad <preference>Tracker
VirtualMemory
; ;
SYSTEM_DEMOS = Sudoku ; SYSTEM_DEMOS = BSnow Cortex FontDemo OverlayImage Pairs Sudoku ;
SYSTEM_LIBS = libbe.so libbsd.so libbnetapi.so libdebug.so libmedia.so SYSTEM_LIBS = libbe.so libbsd.so libbnetapi.so libgame.so libdebug.so libmedia.so
libnetwork.so <revisioned>libroot.so libroot-addon-icu.so libmidi2.so libnetwork.so <revisioned>libroot.so libroot-addon-icu.so
libtextencoding.so libtiff.so libtracker.so libtranslation.so libtextencoding.so libtiff.so libtracker.so libtranslation.so
$(HAIKU_SHARED_LIBSTDC++) $(HAIKU_SHARED_LIBSUPC++) $(HAIKU_SHARED_LIBSTDC++) $(HAIKU_SHARED_LIBSUPC++)
; ;
@@ -48,8 +51,9 @@ PRIVATE_SYSTEM_LIBS =
libilmimf.so libilmimf.so
; ;
SYSTEM_SERVERS = app_server debug_server input_server mount_server SYSTEM_SERVERS = app_server cddb_daemon debug_server input_server midi_server
net_server notification_server registrar syslog_daemon mount_server net_server notification_server power_daemon print_server
print_addon_server registrar syslog_daemon
; ;
SYSTEM_NETWORK_DEVICES = ethernet loopback ; SYSTEM_NETWORK_DEVICES = ethernet loopback ;
@@ -65,6 +69,17 @@ SYSTEM_ADD_ONS_TRANSLATORS = BMPTranslator EXRTranslator GIFTranslator
TIFFTranslator WebPTranslator WonderBrushTranslator TIFFTranslator WebPTranslator WonderBrushTranslator
; ;
SYSTEM_ADD_ONS_PRINT =
Canon\ LIPS3\ Compatible
Canon\ LIPS4\ Compatible
Gutenprint
PCL5\ Compatible
PCL6\ Compatible
PDF\ Writer
PS\ Compatible
;
SYSTEM_ADD_ONS_DRIVERS_GRAPHICS = vesa ; SYSTEM_ADD_ONS_DRIVERS_GRAPHICS = vesa ;
SYSTEM_ADD_ONS_DRIVERS_NET = 3com atheros813x ar81xx attansic_l1 attansic_l2 SYSTEM_ADD_ONS_DRIVERS_NET = 3com atheros813x ar81xx attansic_l1 attansic_l2
broadcom440x broadcom570x dec21xxx etherpci ipro100 ipro1000 jmicron2x0 broadcom440x broadcom570x dec21xxx etherpci ipro100 ipro1000 jmicron2x0
@@ -425,7 +425,7 @@ void
DocInfoWindow::_EmptyKeyList() DocInfoWindow::_EmptyKeyList()
{ {
while (fKeyList->CountItems() > 0L) while (fKeyList->CountItems() > 0L)
delete fKeyList->RemoveItem(0L); delete fKeyList->RemoveItem((int32)0);
} }
@@ -201,7 +201,7 @@ PrinterDriver::PrintPage(int32 pageNumber, int32 pageCount)
{ {
char text[128]; char text[128];
sprintf(text, "Faking print of page %ld/%ld...", pageNumber, pageCount); sprintf(text, "Faking print of page %" B_PRId32 "/%" B_PRId32 "...", pageNumber, pageCount);
BAlert *alert = new BAlert("PrinterDriver::PrintPage()", text, "Hmm?"); BAlert *alert = new BAlert("PrinterDriver::PrintPage()", text, "Hmm?");
alert->SetFlags(alert->Flags() | B_CLOSE_ON_ESCAPE); alert->SetFlags(alert->Flags() | B_CLOSE_ON_ESCAPE);
alert->Go(); alert->Go();
+2 -2
View File
@@ -169,7 +169,7 @@ void SnowView::AttachedToWindow()
fFallenReg = new BRegion; fFallenReg = new BRegion;
fInvalidator = spawn_thread(SnowMakerThread, INVALIDATOR_THREAD_NAME, B_LOW_PRIORITY, (void *)this); fInvalidator = spawn_thread(SnowMakerThread, INVALIDATOR_THREAD_NAME, B_LOW_PRIORITY, (void *)this);
resume_thread(fInvalidator); resume_thread(fInvalidator);
printf("BSnow: OK: ws = %ld x %ld\n", fCachedWsWidth, fCachedWsHeight); printf("BSnow: OK: ws = %" B_PRId32 " x %" B_PRId32 "\n", fCachedWsWidth, fCachedWsHeight);
#ifdef DEBUG #ifdef DEBUG
Window()->AddCommonFilter(new BMessageFilter(B_ANY_DELIVERY, B_ANY_SOURCE, msgfilter)); Window()->AddCommonFilter(new BMessageFilter(B_ANY_DELIVERY, B_ANY_SOURCE, msgfilter));
#endif #endif
@@ -326,7 +326,7 @@ void SnowView::Calc()
if (fCachedWsWidth != pFrame.Width() || fCachedWsHeight != pFrame.Height()) { if (fCachedWsWidth != pFrame.Width() || fCachedWsHeight != pFrame.Height()) {
fCachedWsWidth = pFrame.IntegerWidth(); fCachedWsWidth = pFrame.IntegerWidth();
fCachedWsHeight = pFrame.IntegerHeight(); fCachedWsHeight = pFrame.IntegerHeight();
printf("BSnow: Parent resized to %ld %ld\n", fCachedWsWidth, fCachedWsHeight); printf("BSnow: Parent resized to %" B_PRId32 " %" B_PRId32 "\n", fCachedWsWidth, fCachedWsHeight);
fFallenReg->MakeEmpty(); /* remove all the fallen snow */ fFallenReg->MakeEmpty(); /* remove all the fallen snow */
ResizeTo(pFrame.IntegerWidth(), pFrame.IntegerHeight()); ResizeTo(pFrame.IntegerWidth(), pFrame.IntegerHeight());
fDragger->MoveTo(pFrame.IntegerWidth()-7, pFrame.IntegerHeight()-7); fDragger->MoveTo(pFrame.IntegerWidth()-7, pFrame.IntegerHeight()-7);
+11 -7
View File
@@ -245,7 +245,7 @@ CDDBData::Load(const entry_ref &ref)
time->SetMinutes(0); time->SetMinutes(0);
time->SetSeconds(0); time->SetSeconds(0);
STRACE(("CDDBData::Load: Adding Track %s (%ld:%ld)\n", newTrack->String(), STRACE(("CDDBData::Load: Adding Track %s (%" B_PRId32 ":%" B_PRId32 ")\n", newTrack->String(),
time->minutes, time->seconds)); time->minutes, time->seconds));
fTrackList.AddItem(newTrack); fTrackList.AddItem(newTrack);
@@ -332,7 +332,8 @@ CDDBData::Save(const char *filename)
BString entry; BString entry;
char timestring[10]; char timestring[10];
sprintf(timestring,"%.2ld:%.2ld", fDiscTime.GetMinutes(), fDiscTime.GetSeconds()); sprintf(timestring,"%.2" B_PRId32 ":%.2" B_PRId32 "", fDiscTime.GetMinutes(),
fDiscTime.GetSeconds());
entry << fArtist << " - " << fAlbum << "\t" << timestring << "\n"; entry << fArtist << " - " << fAlbum << "\t" << timestring << "\n";
file.Write(entry.String(), entry.Length()); file.Write(entry.String(), entry.Length());
@@ -351,7 +352,8 @@ CDDBData::Save(const char *filename)
entry = *trackstr; entry = *trackstr;
sprintf(timestring,"%.2ld:%.2ld", time->GetMinutes(), time->GetSeconds()); sprintf(timestring,"%.2" B_PRId32 ":%.2" B_PRId32 "", time->GetMinutes(),
time->GetSeconds());
entry << "\t" << timestring << "\n"; entry << "\t" << timestring << "\n";
file.Write(entry.String(), entry.Length()); file.Write(entry.String(), entry.Length());
@@ -361,7 +363,8 @@ CDDBData::Save(const char *filename)
} }
file.WriteAttr("CD:key", B_INT32_TYPE, 0, &fDiscID, sizeof(int32)); file.WriteAttr("CD:key", B_INT32_TYPE, 0, &fDiscID, sizeof(int32));
STRACE(("CDDBData::Save: Wrote CD identifier: %ld(%lx)\n", fDiscID, fDiscID)); STRACE(("CDDBData::Save: Wrote CD identifier: %" B_PRId32 "(%" B_PRIx32 ")\n",
fDiscID, fDiscID));
file.WriteAttr("CD:tracks", B_STRING_TYPE, 0, tracksattr.String(), tracksattr.Length() + 1); file.WriteAttr("CD:tracks", B_STRING_TYPE, 0, tracksattr.String(), tracksattr.Length() + 1);
if (fGenre.CountChars() > 0) if (fGenre.CountChars() > 0)
@@ -391,7 +394,7 @@ CDDBData::RenameTrack(const int32 &index, const char *newName)
BString *name = (BString*)fTrackList.ItemAt(index); BString *name = (BString*)fTrackList.ItemAt(index);
if (name) { if (name) {
STRACE(("CDDBData::RenameTrack(%ld,%s)\n", index, newName)); STRACE(("CDDBData::RenameTrack(%" B_PRId32 ",%s)\n", index, newName));
name->SetTo(newName); name->SetTo(newName);
return true; return true;
} }
@@ -409,7 +412,8 @@ CDDBData::AddTrack(const char *track, const CDAudioTime &time,
STRACE(("CDDBData::AddTrack failed - NULL name\n")); STRACE(("CDDBData::AddTrack failed - NULL name\n"));
return; return;
} }
STRACE(("CDDBData::AddTrack(%s, %ld:%.2ld,%d)\n", track, time.minutes, time.seconds, index)); STRACE(("CDDBData::AddTrack(%s, %" B_PRId32 ":%.2" B_PRId32 ",%d)\n", track,
time.minutes, time.seconds, index));
fTrackList.AddItem(new BString(track)); fTrackList.AddItem(new BString(track));
fTimeList.AddItem(new CDAudioTime(time)); fTimeList.AddItem(new CDAudioTime(time));
@@ -691,7 +695,7 @@ CDDBQuery::_ReadFromServer(BString &data)
// Query for the existence of the disc in the database // Query for the existence of the disc in the database
char idString[10]; char idString[10];
sprintf(idString, "%08lx", fCDData.DiscID()); sprintf(idString, "%08" B_PRIx32, fCDData.DiscID());
BString query; BString query;
int32 trackCount = GetTrackCount(&fSCSIData); int32 trackCount = GetTrackCount(&fSCSIData);
+2 -2
View File
@@ -60,7 +60,7 @@ public:
protected: protected:
const char* UpdateText() const const char* UpdateText() const
{ {
snprintf(fText, sizeof(fText), "%ldpt", Value()); snprintf(fText, sizeof(fText), "%" B_PRId32 "pt", Value());
return fText; return fText;
} }
@@ -310,7 +310,7 @@ CharacterWindow::MessageReceived(BMessage* message)
sizeof(utf8Hex)); sizeof(utf8Hex));
char text[128]; char text[128];
snprintf(text, sizeof(text), " %s: %#lx (%ld), UTF-8: %s", snprintf(text, sizeof(text), " %s: %#" B_PRIx32 " (%" B_PRId32 "), UTF-8: %s",
B_TRANSLATE("Code"), character, character, utf8Hex); B_TRANSLATE("Code"), character, character, utf8Hex);
char glyph[20]; char glyph[20];
@@ -528,7 +528,7 @@ void TransportView::_selectGroup(
err = m_manager->findGroup(groupID, &m_group); err = m_manager->findGroup(groupID, &m_group);
if(err < B_OK) { if(err < B_OK) {
PRINT(( PRINT((
"* TransportView::_selectGroup(%ld): findGroup() failed:\n" "* TransportView::_selectGroup(%" B_PRId32 "): findGroup() failed:\n"
" %s\n", " %s\n",
groupID, groupID,
strerror(err))); strerror(err)));
@@ -784,7 +784,7 @@ void TransportView::_populateTimeSourceMenu(
B_RAW_TYPE, B_RAW_TYPE,
&r->node(), &r->node(),
sizeof(media_node)); sizeof(media_node));
sprintf(nameBuffer, "%s: %ld", sprintf(nameBuffer, "%s: %" B_PRId32,
r->name(), r->name(),
r->id()); r->id());
i = new BMenuItem( i = new BMenuItem(
@@ -1088,12 +1088,12 @@ void TransportView::_timeSourceCreated(
if(err < B_OK) if(err < B_OK)
return; return;
// PRINT(("### _timeSourceCreated(): %ld\n", id)); // PRINT(("### _timeSourceCreated(): %" B_PRId32 "\n", id));
NodeRef* ref; NodeRef* ref;
err = m_manager->getNodeRef(id, &ref); err = m_manager->getNodeRef(id, &ref);
if(err < B_OK) { if(err < B_OK) {
PRINT(( PRINT((
"!!! TransportView::_timeSourceCreated(): node %ld doesn't exist\n", "!!! TransportView::_timeSourceCreated(): node %" B_PRId32 " doesn't exist\n",
id)); id));
return; return;
} }
@@ -1105,7 +1105,7 @@ void TransportView::_timeSourceCreated(
B_RAW_TYPE, B_RAW_TYPE,
&ref->node(), &ref->node(),
sizeof(media_node)); sizeof(media_node));
sprintf(nameBuffer, "%s: %ld", sprintf(nameBuffer, "%s: %" B_PRId32,
ref->name(), ref->name(),
ref->id()); ref->id());
BMenuItem* i = new BMenuItem( BMenuItem* i = new BMenuItem(
@@ -1126,7 +1126,7 @@ void TransportView::_timeSourceDeleted(
if(err < B_OK) if(err < B_OK)
return; return;
// PRINT(("### _timeSourceDeleted(): %ld\n", id)); // PRINT(("### _timeSourceDeleted(): %" B_PRId32 "\n", id));
BMenu* menu = m_timeSourceView->Menu(); BMenu* menu = m_timeSourceView->Menu();
ASSERT(menu); ASSERT(menu);
+1 -1
View File
@@ -38,7 +38,7 @@ main(int argc, char* argv[])
BString result = parser.Evaluate(expression.String()); BString result = parser.Evaluate(expression.String());
printf("%s\n", result.String()); printf("%s\n", result.String());
} catch (ParseException e) { } catch (ParseException e) {
printf("%s at %ld\n", e.message.String(), e.position + 1); printf("%s at %" B_PRId32 "\n", e.message.String(), e.position + 1);
return 1; return 1;
} }
} }
+1 -1
View File
@@ -373,7 +373,7 @@ ExpressionTextView::AddExpressionToHistory(const char* expression)
return; return;
} }
while (fPreviousExpressions.CountItems() > kMaxPreviousExpressions) while (fPreviousExpressions.CountItems() > kMaxPreviousExpressions)
delete (BString*)fPreviousExpressions.RemoveItem(0L); delete (BString*)fPreviousExpressions.RemoveItem((int32)0);
fHistoryPos = fPreviousExpressions.CountItems(); fHistoryPos = fPreviousExpressions.CountItems();
} }
+1 -1
View File
@@ -380,7 +380,7 @@ ControlView::MessageReceived(BMessage* msg)
printf("Failed to add style or family to the message\n"); printf("Failed to add style or family to the message\n");
return; return;
} }
printf("InstalledStyles(%ld), Font(%s), Style(%s)\n", printf("InstalledStyles(%" B_PRId32 "), Font(%s), Style(%s)\n",
installedStyles, newFontFamilyItem->Label(), installedStyles, newFontFamilyItem->Label(),
newstyleitem->Label()); newstyleitem->Label());
_UpdateAndSendStyle(msg); _UpdateAndSendStyle(msg);
@@ -525,10 +525,10 @@ MediaConverterApp::_ConvertFile(BMediaFile* inFile, BMediaFile* outFile,
for (int64 i = start; (i <= end) && !fCancel; i += framesRead) { for (int64 i = start; (i <= end) && !fCancel; i += framesRead) {
if ((ret = inVidTrack->ReadFrames(videoBuffer, &framesRead, if ((ret = inVidTrack->ReadFrames(videoBuffer, &framesRead,
&mh)) != B_OK) { &mh)) != B_OK) {
fprintf(stderr, "Error reading video frame %Ld: %s\n", i, fprintf(stderr, "Error reading video frame %" B_PRId64 ": %s\n", i,
strerror(ret)); strerror(ret));
snprintf(status.LockBuffer(128), 128, snprintf(status.LockBuffer(128), 128,
B_TRANSLATE("Error read video frame %Ld"), i); B_TRANSLATE("Error read video frame %" B_PRId64), i);
status.UnlockBuffer(); status.UnlockBuffer();
SetStatusMessage(status.String()); SetStatusMessage(status.String());
@@ -537,10 +537,10 @@ MediaConverterApp::_ConvertFile(BMediaFile* inFile, BMediaFile* outFile,
if ((ret = outVidTrack->WriteFrames(videoBuffer, framesRead, if ((ret = outVidTrack->WriteFrames(videoBuffer, framesRead,
mh.u.encoded_video.field_flags)) != B_OK) { mh.u.encoded_video.field_flags)) != B_OK) {
fprintf(stderr, "Error writing video frame %Ld: %s\n", i, fprintf(stderr, "Error writing video frame %" B_PRId64 ": %s\n", i,
strerror(ret)); strerror(ret));
snprintf(status.LockBuffer(128), 128, snprintf(status.LockBuffer(128), 128,
B_TRANSLATE("Error writing video frame %Ld"), i); B_TRANSLATE("Error writing video frame %" B_PRId64), i);
status.UnlockBuffer(); status.UnlockBuffer();
SetStatusMessage(status.String()); SetStatusMessage(status.String());
@@ -551,7 +551,7 @@ MediaConverterApp::_ConvertFile(BMediaFile* inFile, BMediaFile* outFile,
if (currPercent > lastPercent) { if (currPercent > lastPercent) {
lastPercent = currPercent; lastPercent = currPercent;
snprintf(status.LockBuffer(128), 128, snprintf(status.LockBuffer(128), 128,
B_TRANSLATE("Writing video track: %ld%% complete"), B_TRANSLATE("Writing video track: %" B_PRId32 "%% complete"),
currPercent); currPercent);
status.UnlockBuffer(); status.UnlockBuffer();
SetStatusMessage(status.String()); SetStatusMessage(status.String());
@@ -587,7 +587,7 @@ MediaConverterApp::_ConvertFile(BMediaFile* inFile, BMediaFile* outFile,
&mh)) != B_OK) { &mh)) != B_OK) {
fprintf(stderr, "Error reading audio frames: %s\n", strerror(ret)); fprintf(stderr, "Error reading audio frames: %s\n", strerror(ret));
snprintf(status.LockBuffer(128), 128, snprintf(status.LockBuffer(128), 128,
B_TRANSLATE("Error read audio frame %Ld"), i); B_TRANSLATE("Error read audio frame %" B_PRId64), i);
status.UnlockBuffer(); status.UnlockBuffer();
SetStatusMessage(status.String()); SetStatusMessage(status.String());
@@ -598,7 +598,7 @@ MediaConverterApp::_ConvertFile(BMediaFile* inFile, BMediaFile* outFile,
framesRead)) != B_OK) { framesRead)) != B_OK) {
fprintf(stderr, "Error writing audio frames: %s\n", strerror(ret)); fprintf(stderr, "Error writing audio frames: %s\n", strerror(ret));
snprintf(status.LockBuffer(128), 128, snprintf(status.LockBuffer(128), 128,
B_TRANSLATE("Error writing audio frame %Ld"), i); B_TRANSLATE("Error writing audio frame %" B_PRId64), i);
status.UnlockBuffer(); status.UnlockBuffer();
SetStatusMessage(status.String()); SetStatusMessage(status.String());
@@ -609,7 +609,7 @@ MediaConverterApp::_ConvertFile(BMediaFile* inFile, BMediaFile* outFile,
if (currPercent > lastPercent) { if (currPercent > lastPercent) {
lastPercent = currPercent; lastPercent = currPercent;
snprintf(status.LockBuffer(128), 128, snprintf(status.LockBuffer(128), 128,
B_TRANSLATE("Writing audio track: %ld%% complete"), B_TRANSLATE("Writing audio track: %" B_PRId32 "%% complete"),
currPercent); currPercent);
status.UnlockBuffer(); status.UnlockBuffer();
SetStatusMessage(status.String()); SetStatusMessage(status.String());
@@ -501,7 +501,7 @@ MediaConverterWindow::BuildAudioVideoMenus()
BMenu* menu = fAudioMenu->Menu(); BMenu* menu = fAudioMenu->Menu();
BMenuItem* item; BMenuItem* item;
// clear out old audio codec menu items // clear out old audio codec menu items
while ((item = menu->RemoveItem(0L)) != NULL) while ((item = menu->RemoveItem((int32)0)) != NULL)
delete item; delete item;
bool separator = true; bool separator = true;
@@ -558,7 +558,7 @@ MediaConverterWindow::BuildAudioVideoMenus()
// clear out old video codec menu items // clear out old video codec menu items
menu = fVideoMenu->Menu(); menu = fVideoMenu->Menu();
while ((item = menu->RemoveItem(0L)) != NULL) while ((item = menu->RemoveItem((int32)0)) != NULL)
delete item; delete item;
separator = true; separator = true;
+1 -1
View File
@@ -183,7 +183,7 @@ PairsView::_ReadRandomIcons()
} }
// delete the remaining bitmaps from the list // delete the remaining bitmaps from the list
while (BBitmap* bitmap = (BBitmap*)bitmaps.RemoveItem(0L)) while (BBitmap* bitmap = (BBitmap*)bitmaps.RemoveItem((int32)0))
delete bitmap; delete bitmap;
} }
+1 -1
View File
@@ -23,7 +23,7 @@ StatusSlider::StatusSlider(const char* name, const char* label,
const char* const char*
StatusSlider::UpdateText() const StatusSlider::UpdateText() const
{ {
sprintf(fTemp, "%ld %s", Value(), fStatusPrefix); sprintf(fTemp, "%" B_PRId32 " %s", Value(), fStatusPrefix);
return fTemp; return fTemp;
} }
+1 -1
View File
@@ -2921,7 +2921,7 @@ ls( httpd_conn* hc )
/* And print. */ /* And print. */
(void) fprintf( fp, (void) fprintf( fp,
"%10lld %s <A HREF=\"/%.500s%s\">%.80s</A>%s%s%s\n", "%10" B_PRId64 " %s <A HREF=\"/%.500s%s\">%.80s</A>%s%s%s\n",
(int64_t) lsb.st_size, (int64_t) lsb.st_size,
timestr, encrname, S_ISDIR(sb.st_mode) ? "/" : "", timestr, encrname, S_ISDIR(sb.st_mode) ? "/" : "",
nameptrs[i], linkprefix, link, fileclass ); nameptrs[i], linkprefix, link, fileclass );
+1 -1
View File
@@ -711,7 +711,7 @@ ShowImageWindow::MessageReceived(BMessage* message)
while (fGoToPageMenu->CountItems() > 0) { while (fGoToPageMenu->CountItems() > 0) {
// Remove all page numbers // Remove all page numbers
delete fGoToPageMenu->RemoveItem(0L); delete fGoToPageMenu->RemoveItem((int32)0);
} }
for (int32 i = 1; i <= pages; i++) { for (int32 i = 1; i <= pages; i++) {
+1 -1
View File
@@ -27,7 +27,7 @@ CopyFileData(BFile& dst, BFile& src)
struct stat src_stat; struct stat src_stat;
status_t err = src.GetStat(&src_stat); status_t err = src.GetStat(&src_stat);
if (err != B_OK) { if (err != B_OK) {
printf("couldn't get stat: %#010lx\n", err); printf("couldn't get stat: %#010" B_PRIx32 "\n", err);
return err; return err;
} }
+2 -2
View File
@@ -457,7 +457,7 @@ RecorderWindow::InitWindow()
error = fRoster->GetDormantNodes(dni, &real_count, 0, &output_format, error = fRoster->GetDormantNodes(dni, &real_count, 0, &output_format,
0, B_BUFFER_PRODUCER | B_PHYSICAL_INPUT); 0, B_BUFFER_PRODUCER | B_PHYSICAL_INPUT);
if (real_count > maxInputCount) { if (real_count > maxInputCount) {
WINDOW((stderr, "dropped %ld inputs\n", real_count - maxInputCount)); WINDOW((stderr, "dropped %" B_PRId32 " inputs\n", real_count - maxInputCount));
real_count = maxInputCount; real_count = maxInputCount;
} }
char selected_name[B_MEDIA_NAME_LENGTH] = "Default input"; char selected_name[B_MEDIA_NAME_LENGTH] = "Default input";
@@ -1172,7 +1172,7 @@ RecorderWindow::ErrorAlert(const char * action, status_t err)
{ {
char msg[300]; char msg[300];
if (err != B_OK) if (err != B_OK)
sprintf(msg, "%s: %s. [%lx]", action, strerror(err), (int32) err); sprintf(msg, "%s: %s. [%" B_PRIx32 "]", action, strerror(err), (int32) err);
else else
sprintf(msg, "%s.", action); sprintf(msg, "%s.", action);
BAlert* alert = new BAlert("", msg, B_TRANSLATE("Stop")); BAlert* alert = new BAlert("", msg, B_TRANSLATE("Stop"));
+2 -2
View File
@@ -408,8 +408,8 @@ TrackSlider::_TimeToString(bigtime_t timestamp, char *string)
uint32 seconds = timestamp / 1000000LL; uint32 seconds = timestamp / 1000000LL;
timestamp -= seconds * 1000000LL; timestamp -= seconds * 1000000LL;
uint32 centiseconds = timestamp / 10000LL; uint32 centiseconds = timestamp / 10000LL;
sprintf(string, "%02ld:%02ld:%02ld:%02ld", hours, minutes, seconds, sprintf(string, "%02" B_PRId32 ":%02" B_PRId32 ":%02" B_PRId32 ":%02"
centiseconds); B_PRId32, hours, minutes, seconds, centiseconds);
} }
+1 -1
View File
@@ -147,7 +147,7 @@ Controller::ConnectInterface(int i)
printf(" name '%s'\n", parameter->Name()); printf(" name '%s'\n", parameter->Name());
printf(" kind '%s'\n", parameter->Kind()); printf(" kind '%s'\n", parameter->Kind());
printf(" unit '%s'\n", parameter->Unit()); printf(" unit '%s'\n", parameter->Unit());
printf(" flags 0x%08lx\n", parameter->Flags()); printf(" flags 0x%08" B_PRIx32 "\n", parameter->Flags());
// XXX TODO: matching on Name is weak // XXX TODO: matching on Name is weak
if (strcmp(parameter->Name(), "Channel") == 0 || strcmp(parameter->Kind(), B_TUNER_CHANNEL) == 0) { if (strcmp(parameter->Name(), "Channel") == 0 || strcmp(parameter->Kind(), B_TUNER_CHANNEL) == 0) {
+1 -1
View File
@@ -41,7 +41,7 @@ DeviceRoster::DeviceRoster()
err = MediaRoster()->GetLiveNodes(info, &info_count, NULL, NULL, "DVB*", err = MediaRoster()->GetLiveNodes(info, &info_count, NULL, NULL, "DVB*",
B_BUFFER_PRODUCER | B_PHYSICAL_INPUT); B_BUFFER_PRODUCER | B_PHYSICAL_INPUT);
if (err != B_OK || info_count < 1) { if (err != B_OK || info_count < 1) {
printf("Can't find live DVB node. Found %ld nodes, error %08lx (%s)\n", printf("Can't find live DVB node. Found %" B_PRId32 " nodes, error %08" B_PRIx32 " (%s)\n",
info_count, err, strerror(err)); info_count, err, strerror(err));
fDeviceCount = 0; fDeviceCount = 0;
} else { } else {
+1 -1
View File
@@ -974,7 +974,7 @@ MainWin::KeyDown(BMessage *msg)
uint32 raw_char = msg->FindInt32("raw_char"); uint32 raw_char = msg->FindInt32("raw_char");
uint32 modifiers = msg->FindInt32("modifiers"); uint32 modifiers = msg->FindInt32("modifiers");
printf("key 0x%lx, raw_char 0x%lx, modifiers 0x%lx\n", key, raw_char, printf("key 0x%" B_PRIx32 ", raw_char 0x%" B_PRIx32 ", modifiers 0x%" B_PRIx32 "\n", key, raw_char,
modifiers); modifiers);
switch (raw_char) { switch (raw_char) {
+1 -1
View File
@@ -446,7 +446,7 @@ VideoNode::CreateBuffers(BRect frame, color_space cspace, bool overlay)
printf("VideoNode::CreateBuffers failed\n"); printf("VideoNode::CreateBuffers failed\n");
return B_ERROR; return B_ERROR;
} }
printf("overlay bitmap: got: bytes per row: %ld\n", printf("overlay bitmap: got: bytes per row: %" B_PRId32 "\n",
fBitmap->BytesPerRow()); fBitmap->BytesPerRow());
fOverlayActive = overlay; fOverlayActive = overlay;
UnlockBitmap(); UnlockBitmap();
+7 -7
View File
@@ -270,7 +270,7 @@ set_entries_from_file(const char *filename)
char *rest = line; char *rest = line;
const char *argument = next_argument(&rest); const char *argument = next_argument(&rest);
if (argument == NULL) { if (argument == NULL) {
fprintf(stderr, "%s: Line %ld is invalid (missing hostname).\n", fprintf(stderr, "%s: Line %" B_PRId32 " is invalid (missing hostname).\n",
kProgramName, counter); kProgramName, counter);
continue; continue;
} }
@@ -280,12 +280,12 @@ set_entries_from_file(const char *filename)
// get host by name // get host by name
struct hostent *host = gethostbyname(argument); struct hostent *host = gethostbyname(argument);
if (host == NULL) { if (host == NULL) {
fprintf(stderr, "%s: Line %ld, host \"%s\" is not known in the IPv4 domain: %s\n", fprintf(stderr, "%s: Line %" B_PRId32 ", host \"%s\" is not known in the IPv4 domain: %s\n",
kProgramName, counter, argument, strerror(errno)); kProgramName, counter, argument, strerror(errno));
continue; continue;
} }
if (host->h_addrtype != AF_INET) { if (host->h_addrtype != AF_INET) {
fprintf(stderr, "%s: Line %ld, host \"%s\" is not known in the IPv4 domain.\n", fprintf(stderr, "%s: Line " B_PRId32 ", host \"%s\" is not known in the IPv4 domain.\n",
kProgramName, counter, argument); kProgramName, counter, argument);
continue; continue;
} }
@@ -299,14 +299,14 @@ set_entries_from_file(const char *filename)
argument = next_argument(&rest); argument = next_argument(&rest);
if (argument == NULL) { if (argument == NULL) {
fprintf(stderr, "%s: Line %ld is invalid (missing ethernet address).\n", fprintf(stderr, "%s: Line %" B_PRId32 " is invalid (missing ethernet address).\n",
kProgramName, counter); kProgramName, counter);
continue; continue;
} }
uint8 ethernetAddress[6]; uint8 ethernetAddress[6];
if (!parse_ethernet_address(argument, ethernetAddress)) { if (!parse_ethernet_address(argument, ethernetAddress)) {
fprintf(stderr, "%s: Line %ld, \"%s\" is not a valid ethernet address.\n", fprintf(stderr, "%s: Line %" B_PRId32 ", \"%s\" is not a valid ethernet address.\n",
kProgramName, counter, argument); kProgramName, counter, argument);
continue; continue;
} }
@@ -316,14 +316,14 @@ set_entries_from_file(const char *filename)
uint32 flags = ARP_FLAG_PERMANENT; uint32 flags = ARP_FLAG_PERMANENT;
while ((argument = next_argument(&rest)) != NULL) { while ((argument = next_argument(&rest)) != NULL) {
if (!set_flags(flags, argument)) { if (!set_flags(flags, argument)) {
fprintf(stderr, "%s: Line %ld, ignoring invalid flag \"%s\".\n", fprintf(stderr, "%s: Line %" B_PRId32 ", ignoring invalid flag \"%s\".\n",
kProgramName, counter, argument); kProgramName, counter, argument);
} }
} }
status_t status = set_entry(&address, ethernetAddress, flags); status_t status = set_entry(&address, ethernetAddress, flags);
if (status != B_OK) { if (status != B_OK) {
fprintf(stderr, "%s: Line %ld, ARP entry could not been set: %s\n", fprintf(stderr, "%s: Line %" B_PRId32 ", ARP entry could not been set: %s\n",
kProgramName, counter, strerror(status)); kProgramName, counter, strerror(status));
} }
} }
+1 -1
View File
@@ -536,7 +536,7 @@ BWindowScreen::Suspend(char* label)
CALLED(); CALLED();
if (fDebugState) { if (fDebugState) {
fprintf(stderr, "## Debugger(\"%s\").", label); fprintf(stderr, "## Debugger(\"%s\").", label);
fprintf(stderr, " Press Alt-F%ld or Cmd-F%ld to resume.\n", fprintf(stderr, " Press Alt-F%" B_PRId32 " or Cmd-F%" B_PRId32 " to resume.\n",
fWorkspaceIndex + 1, fWorkspaceIndex + 1); fWorkspaceIndex + 1, fWorkspaceIndex + 1);
if (IsLocked()) if (IsLocked())
+2 -2
View File
@@ -47,8 +47,8 @@ BMidiRosterLooper::~BMidiRosterLooper()
BMidiEndpoint* endp = EndpointAt(t); BMidiEndpoint* endp = EndpointAt(t);
if (endp->fRefCount > 0) { if (endp->fRefCount > 0) {
fprintf( fprintf(
stderr, "[midi] WARNING: Endpoint %ld (%p) has " stderr, "[midi] WARNING: Endpoint %" B_PRId32 " (%p) has "
"not been Release()d properly (refcount = %ld)\n", "not been Release()d properly (refcount = %" B_PRId32 ")\n",
endp->ID(), endp, endp->fRefCount); endp->ID(), endp, endp->fRefCount);
} else { } else {
delete endp; delete endp;
+2 -2
View File
@@ -399,7 +399,7 @@ void PicturePrinter::SetFontFlags(int32 flags) {
if (flags == 0) Print("none set"); if (flags == 0) Print("none set");
PRINT_FLAG(B_DISABLE_ANTIALIASING); PRINT_FLAG(B_DISABLE_ANTIALIASING);
PRINT_FLAG(B_FORCE_ANTIALIASING); PRINT_FLAG(B_FORCE_ANTIALIASING);
if (flags != f) printf("Unknown Additional Flags %ld", flags & ~f); if (flags != f) printf("Unknown Additional Flags %" B_PRId32 "", flags & ~f);
Cr(); Cr();
} }
@@ -420,7 +420,7 @@ void PicturePrinter::SetFontFace(int32 flags) {
PRINT_FLAG(B_OUTLINED_FACE); PRINT_FLAG(B_OUTLINED_FACE);
PRINT_FLAG(B_UNDERSCORE_FACE); PRINT_FLAG(B_UNDERSCORE_FACE);
PRINT_FLAG(B_STRIKEOUT_FACE); PRINT_FLAG(B_STRIKEOUT_FACE);
if (flags != f) printf("Unknown Additional Flags %ld", flags & ~f); if (flags != f) printf("Unknown Additional Flags %" B_PRId32 "", flags & ~f);
Cr(); Cr();
} }
+2 -2
View File
@@ -143,8 +143,8 @@ PrinterDriverAddOn::TakeJob(const char* spoolFile, BDirectory* spoolFolder)
// This seems to be required for legacy? // This seems to be required for legacy?
// HP PCL3 add-on crashes without it! // HP PCL3 add-on crashes without it!
BMessage parameters(B_REFS_RECEIVED); BMessage parameters(B_REFS_RECEIVED);
parameters.AddInt32("file", (int32)&file); parameters.AddInt32("file", (addr_t)&file);
parameters.AddInt32("printer", (int32)spoolFolder); parameters.AddInt32("printer", (addr_t)spoolFolder);
BMessage* message = (*func)(&file, spoolFolder, &parameters); BMessage* message = (*func)(&file, spoolFolder, &parameters);
if (message == NULL || message->what != 'okok') if (message == NULL || message->what != 'okok')
+3 -3
View File
@@ -182,7 +182,7 @@ MessageImporter::_ImportShapes(const BMessage* archive, PathContainer* paths,
int32 styleIndex; int32 styleIndex;
if (shapeArchive.FindInt32("style ref", &styleIndex) < B_OK) { if (shapeArchive.FindInt32("style ref", &styleIndex) < B_OK) {
printf("MessageImporter::_ImportShapes() - " printf("MessageImporter::_ImportShapes() - "
"Shape %ld doesn't reference a Style!", i); "Shape %" B_PRId32 " doesn't reference a Style!", i);
continue; continue;
} }
#ifdef ICON_O_MATIC #ifdef ICON_O_MATIC
@@ -192,7 +192,7 @@ MessageImporter::_ImportShapes(const BMessage* archive, PathContainer* paths,
#endif #endif
if (!style) { if (!style) {
printf("MessageImporter::_ImportShapes() - " printf("MessageImporter::_ImportShapes() - "
"Shape %ld wants Style %ld, which does not exist\n", "Shape %" B_PRId32 " wants Style %" B_PRId32 ", which does not exist\n",
i, styleIndex); i, styleIndex);
continue; continue;
} }
@@ -218,7 +218,7 @@ MessageImporter::_ImportShapes(const BMessage* archive, PathContainer* paths,
#endif #endif
if (!path) { if (!path) {
printf("MessageImporter::_ImportShapes() - " printf("MessageImporter::_ImportShapes() - "
"Shape %ld referenced path %ld, " "Shape %" B_PRId32 " referenced path %" B_PRId32 ", "
"which does not exist\n", i, pathIndex); "which does not exist\n", i, pathIndex);
continue; continue;
} }
+2 -2
View File
@@ -976,7 +976,7 @@ void
VectorPath::PrintToStream() const VectorPath::PrintToStream() const
{ {
for (int32 i = 0; i < fPointCount; i++) { for (int32 i = 0; i < fPointCount; i++) {
printf("point %ld: (%f, %f) -> (%f, %f) -> (%f, %f) (%d)\n", i, printf("point %" B_PRId32 ": (%f, %f) -> (%f, %f) -> (%f, %f) (%d)\n", i,
fPath[i].point_in.x, fPath[i].point_in.y, fPath[i].point_in.x, fPath[i].point_in.y,
fPath[i].point.x, fPath[i].point.y, fPath[i].point.x, fPath[i].point.y,
fPath[i].point_out.x, fPath[i].point_out.y, fPath[i].connected); fPath[i].point_out.x, fPath[i].point_out.y, fPath[i].connected);
@@ -1085,7 +1085,7 @@ VectorPath::_SetPointCount(int32 count)
// reallocation might have failed // reallocation might have failed
fPointCount = 0; fPointCount = 0;
fAllocCount = 0; fAllocCount = 0;
fprintf(stderr, "VectorPath::_SetPointCount(%ld) - allocation failed!\n", fprintf(stderr, "VectorPath::_SetPointCount(%" B_PRId32 ") - allocation failed!\n",
count); count);
} }
@@ -591,7 +591,7 @@ Gradient::PrintToStream() const
string_for_interpolation(fInterpolation), string_for_interpolation(fInterpolation),
fInheritTransformation); fInheritTransformation);
for (int32 i = 0; BGradient::ColorStop* step = ColorAt(i); i++) { for (int32 i = 0; BGradient::ColorStop* step = ColorAt(i); i++) {
printf(" %ld: offset: %.1f -> color(%d, %d, %d, %d)\n", printf(" %" B_PRId32 ": offset: %.1f -> color(%d, %d, %d, %d)\n",
i, step->offset, i, step->offset,
step->color.red, step->color.red,
step->color.green, step->color.green,
+2 -2
View File
@@ -42,7 +42,7 @@ JobListView::JobListView(BRect frame)
JobListView::~JobListView() JobListView::~JobListView()
{ {
while (!IsEmpty()) while (!IsEmpty())
delete RemoveItem(0L); delete RemoveItem((int32)0);
} }
@@ -61,7 +61,7 @@ JobListView::SetSpoolFolder(SpoolFolder* folder)
{ {
// clear list // clear list
while (!IsEmpty()) while (!IsEmpty())
delete RemoveItem(0L); delete RemoveItem((int32)0);
if (folder == NULL) if (folder == NULL)
return; return;
+2 -2
View File
@@ -45,7 +45,7 @@ PrinterListView::PrinterListView(BRect frame)
PrinterListView::~PrinterListView() PrinterListView::~PrinterListView()
{ {
while (!IsEmpty()) while (!IsEmpty())
delete RemoveItem(0L); delete RemoveItem((int32)0);
} }
@@ -54,7 +54,7 @@ PrinterListView::BuildPrinterList()
{ {
// clear list // clear list
while (!IsEmpty()) while (!IsEmpty())
delete RemoveItem(0L); delete RemoveItem((int32)0);
// Find directory containing printer definition nodes // Find directory containing printer definition nodes
BPath path; BPath path;
+4 -4
View File
@@ -84,11 +84,11 @@ CDDBDaemon::_Lookup(const dev_t device)
uint32 cddbId; uint32 cddbId;
if (!_CanLookup(device, &cddbId, toc)) { if (!_CanLookup(device, &cddbId, toc)) {
free(toc); free(toc);
printf("Skipping device with id %ld.\n", device); printf("Skipping device with id %" B_PRId32 ".\n", device);
return B_BAD_TYPE; return B_BAD_TYPE;
} }
printf("Looking up CD with CDDB Id %08lx.\n", cddbId); printf("Looking up CD with CDDB Id %08" B_PRIx32 ".\n", cddbId);
CDDBServer cddb_server("freedb.freedb.org:80"); CDDBServer cddb_server("freedb.freedb.org:80");
@@ -123,7 +123,7 @@ CDDBDaemon::_Lookup(const dev_t device)
// Delete itens in the query response BList; // Delete itens in the query response BList;
int32 count = queryResponse.CountItems(); int32 count = queryResponse.CountItems();
for (int32 i = 0; i < count; ++i) { for (int32 i = 0; i < count; ++i) {
delete (QueryResponseData*)queryResponse.RemoveItem(0L); delete (QueryResponseData*)queryResponse.RemoveItem((int32)0);
} }
queryResponse.MakeEmpty(); queryResponse.MakeEmpty();
@@ -131,7 +131,7 @@ CDDBDaemon::_Lookup(const dev_t device)
// Delete itens in the track data BList in the read response data; // Delete itens in the track data BList in the read response data;
count = readResponse.tracks.CountItems(); count = readResponse.tracks.CountItems();
for (int32 i = 0; i < count; ++i) { for (int32 i = 0; i < count; ++i) {
delete (TrackData*)readResponse.tracks.RemoveItem(0L); delete (TrackData*)readResponse.tracks.RemoveItem((int32)0);
} }
readResponse.tracks.MakeEmpty(); readResponse.tracks.MakeEmpty();
+1 -1
View File
@@ -56,7 +56,7 @@ CDDBServer::Query(uint32 cddbId, const scsi_toc_toc* toc, BList* queryResponse)
// Convert CDDB id to hexadecimal format. // Convert CDDB id to hexadecimal format.
char hexCddbId[9]; char hexCddbId[9];
sprintf(hexCddbId, "%08lx", cddbId); sprintf(hexCddbId, "%08" B_PRIx32 "", cddbId);
// Assemble the Query command. // Assemble the Query command.
int32 numTracks = toc->last_track + 1 - toc->first_track; int32 numTracks = toc->last_track + 1 - toc->first_track;
+1 -1
View File
@@ -414,7 +414,7 @@ ConfigWindow::SetupPrintersMenu(BMenu* menu)
{ {
// clear menu // clear menu
while (menu->CountItems() != 0) while (menu->CountItems() != 0)
delete menu->RemoveItem(0L); delete menu->RemoveItem((int32)0);
// fill menu with printer names // fill menu with printer names
BAutolock lock(gLock); BAutolock lock(gLock);